diff options
author | Rob Crittenden <rcritten@redhat.com> | 2009-10-12 13:54:08 -0400 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2009-10-16 14:57:53 -0400 |
commit | 5ad91a0781a91bc097e6e1f1bd5a9de79625fa90 (patch) | |
tree | 241aea0b7e758e46e716906bd16bcec49b1a5c1e /ipaserver/install/ldapupdate.py | |
parent | cc23838db298b763a56ce971916c29ed4ab91611 (diff) | |
download | freeipa-5ad91a0781a91bc097e6e1f1bd5a9de79625fa90.tar.gz freeipa-5ad91a0781a91bc097e6e1f1bd5a9de79625fa90.tar.xz freeipa-5ad91a0781a91bc097e6e1f1bd5a9de79625fa90.zip |
Add a sleep() prior to calling tasks to ensure postop writes are done
We were seeing a rare deadlock of DS when creating the memberOf task because
one thread was adding memberOf in a postop while another was trying to
create an index and this was causing a PRLock deadlock.
Diffstat (limited to 'ipaserver/install/ldapupdate.py')
-rw-r--r-- | ipaserver/install/ldapupdate.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ipaserver/install/ldapupdate.py b/ipaserver/install/ldapupdate.py index 3d97f2222..c90f153db 100644 --- a/ipaserver/install/ldapupdate.py +++ b/ipaserver/install/ldapupdate.py @@ -265,6 +265,9 @@ class LDAPUpdate: def create_index_task(self, attribute): """Create a task to update an index for an attribute""" + # Sleep a bit to ensure previous operations are complete + time.sleep(5) + r = random.SystemRandom() # Refresh the time to make uniqueness more probable. Add on some |