systemd-netlogd icon indicating copy to clipboard operation
systemd-netlogd copied to clipboard

Service does not start

Open howff opened this issue 2 years ago • 8 comments

I've installed this in raspbian but it does not start, the service always says exited with code 1.

When trying to start it manually and running via strace I can't see any obvious system calls returning an error that would cause it to exit. It seems to exit after doing various pcap things.

howff avatar Jan 19 '24 09:01 howff

This is probably due to you not having configured a target for it to send it's logs to.

Add something like:

Address=192.0.2.1:514
Protocol=udp

to /etc/systemd/systemd-netlogd.conf

glance- avatar Mar 28 '24 13:03 glance-

It was configured exactly as in the docs, /etc/systemd/systemd-netlogd.conf is

[Network]
Address=192.168.2.38:514
#Protocol=udp

howff avatar Mar 29 '24 14:03 howff

I can't test right now, but I think you must configure which protocol to send the logs as, as there's no default value. As far as I read the source, the default Manager->protocol value will be 0 from new0 in manager_new() , and that's not a valid value, as SYSLOG_TRANSMISSION_PROTOCOL_UDP = 1 and SYSLOG_TRANSMISSION_PROTOCOL_TCP = 2

So remove the comment out of the Protocol line and it will probably work for you.

glance- avatar Mar 29 '24 19:03 glance-

Now I have inited https://github.com/systemd/systemd-netlogd/pull/42/files#diff-cc6f5ea3643f84c059c72cf98a4dca5ded7f5025f46af4780f8a0788f98b1628R494

ssahani avatar Mar 30 '24 03:03 ssahani

Address=127.0.0.1:6000
Protocol=udp
LogFormat=rfc3339

ssahani avatar Mar 30 '24 03:03 ssahani

I think the README.md might be wrong, the filename seems to be /etc/systemd/systemd-netlogd.conf (not /etc/systemd/netlogd.conf) and the Protocol=udp seems to be required (not commented out).

howff avatar Apr 04 '24 21:04 howff

please update to lastest git

ssahani avatar May 01 '24 03:05 ssahani

I think this is resolved

ssahani avatar May 02 '24 11:05 ssahani