diff --git a/ldap/servers/slapd/abandon.c b/ldap/servers/slapd/abandon.c index 964d28836f..2dd1ee3205 100644 --- a/ldap/servers/slapd/abandon.c +++ b/ldap/servers/slapd/abandon.c @@ -43,7 +43,7 @@ do_abandon(Slapi_PBlock *pb) struct timespec hr_time_end; int nentries; int opid; - } o_copy; + } o_copy; slapi_pblock_get(pb, SLAPI_OPERATION, &pb_op); slapi_pblock_get(pb, SLAPI_CONNECTION, &pb_conn); diff --git a/src/lib389/lib389/__init__.py b/src/lib389/lib389/__init__.py index f9348066b0..1e6f2a901a 100644 --- a/src/lib389/lib389/__init__.py +++ b/src/lib389/lib389/__init__.py @@ -1045,24 +1045,6 @@ def close(self): self.state = DIRSRV_STATE_OFFLINE - def dump_errorlog(self): - ''' - Its logs all errors messages within the error log that occured - after the last startup. - ''' - if os.path.isfile(self.errlog): - lines = [] - with open(self.errlog, 'r') as file: - for line in file: - if "starting up" in line: - lines = [] - for key in ( 'DEBUG', 'INFO', 'NOTICE', 'WARN' ): - if key in line: - lines.append(line) - break - for line in lines: - self.log.error(line) - def start(self, timeout=120, post_open=True): ''' It starts an instance and rebind it. Its final state after rebind @@ -1086,13 +1068,7 @@ def start(self, timeout=120, post_open=True): if self.with_systemd(): self.log.debug("systemd status -> True") # Do systemd things here ... - try: - subprocess.check_output(["systemctl", "start", "dirsrv@%s" % self.serverid], stderr=subprocess.STDOUT) - except subprocess.CalledProcessError as e: - self.dump_errorlog() - self.log.error('Failed to start dirsrv@%s: "%s"' % (self.serverid, e.output.decode())) - self.log.error(e) - raise ValueError('Failed to start DS') + subprocess.check_output(["systemctl", "start", "dirsrv@%s" % self.serverid], stderr=subprocess.STDOUT) else: self.log.debug("systemd status -> False") # Start the process. @@ -1116,7 +1092,6 @@ def start(self, timeout=120, post_open=True): self.log.debug("DEBUG: starting with %s" % cmd) output = subprocess.check_output(*cmd, env=env, stderr=subprocess.STDOUT) except subprocess.CalledProcessError as e: - self.dump_errorlog() self.log.error('Failed to start ns-slapd: "%s"' % e.output.decode()) self.log.error(e) raise ValueError('Failed to start DS')