def reset_logging(self, delete_pid_file=True):
        """Reset log files and remove pid file if exists."""
        # logging
        if os.path.exists(suricata_logging_outputs_file):
            logger.debug("deleting '%s'" % suricata_logging_outputs_file)
            os.unlink(suricata_logging_outputs_file)
        # touch file since it gets read at Suri startup in daemon mode and
        # there could be a race condition
        Path(suricata_logging_outputs_file).touch()
        self.log_offset = 0
        self.suri_startup_log = ""

        # pid file
        if delete_pid_file:
            if os.path.exists(suricata_sc_pid_file):
                logger.debug("deleting '%s'" % suricata_sc_pid_file)
                os.unlink(suricata_sc_pid_file)
Reset log files and remove pid file if exists.
dalton-agent/dalton-agent.py