when stopping wait for real stopping of the daemon
This commit is contained in:
parent
048de86cdc
commit
a7a316b6a3
|
@ -170,9 +170,18 @@ olcAccess: {{0}}to * by manage'''
|
|||
assert self.process
|
||||
|
||||
process = self.process
|
||||
self.process = None
|
||||
process.kill()
|
||||
|
||||
while True:
|
||||
try:
|
||||
conn = self.get_connection()
|
||||
conn.whoami_s()
|
||||
except ldap.SERVER_DOWN:
|
||||
break
|
||||
else:
|
||||
time.sleep(0.1)
|
||||
self.process = None
|
||||
|
||||
def checkpoint(self):
|
||||
'''Stop slapd and save current data state'''
|
||||
assert not self.process
|
||||
|
|
Loading…
Reference in New Issue