mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-17 10:04:41 +00:00
syslog: if /var/run/legacy_log is being created while syslog-ng is booting, it sometimes leads to crashes/dumps of the latter. make sure the socket exists before asking syslog-ng to start
This commit is contained in:
parent
5d99be7c0c
commit
cda4e3561f
@ -674,8 +674,12 @@ EOD;
|
||||
}
|
||||
} else {
|
||||
killbypid('/var/run/syslog.pid', 'TERM', true);
|
||||
@unlink("/var/run/legacy_log");
|
||||
mwexecf("/usr/sbin/service syslog-ng stop");
|
||||
mwexecf("/usr/local/sbin/syslogd -s -c -c -P %s {$syslogd_extra}", '/var/run/syslog.pid');
|
||||
while (count(glob("/var/run/legacy_log")) == 0) {
|
||||
sleep(0.1);
|
||||
}
|
||||
mwexecf("/usr/sbin/service syslog-ng start");
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user