[syslog-ng]fix for the -HUP problem
Balazs Scheidler
bazsi@balabit.hu
Fri, 26 Apr 2002 15:04:45 +0200
On Fri, Apr 26, 2002 at 02:29:10PM +0200, Jerome Peducasse wrote:
> Hi,
>
> This patch works fine for me. syslog-ng doesn't segfault anymore. Thanks a lot.
>
> However, when I send SIGHUP, syslog-ng recreate /dev/log socket. So klogd loses its connection:
>
> write(1, "<7>Apr 26 14:24:53 kernel: VFS: "..., 72) = -1 ECONNRESET (Connection reset by peer)
> read(0, "<4>end_request: I/O error, dev 0"..., 4095) = 159
> time([1019823893]) = 1019823893
> write(1, "<4>Apr 26 14:24:53 kernel: end_r"..., 81) = -1 ENOTCONN (Transport endpoint is not connected)
> time([1019823893]) = 1019823893
>
> Do you have a solution ?
I think this is more a klogd problem than syslog-ng. If klogd was using
SOCK_STREAMS sockets (which it did previously), this would be fine.
The syslog-ng related solution would be to implement keep_listener_alive(),
but it's not yet implemented.
--
Bazsi
PGP info: KeyID 9AF8D0A9 Fingerprint CD27 CFB0 802C 0944 9CFD 804E C82C 8EB1