[systemd-devel] logger --id=val is ignored by systemd

Olaf Hering olaf at aepfle.de
Wed Oct 21 01:05:38 PDT 2015


How can scripts which use "logger -t id --id=val" get "me[val]" into syslog?
This used to work, with a systemd based system it looks like this:

root at probook:~ # journalctl -f &
root at probook:~ # logger -t "me" --no-act --stderr  --id=$PPID "foo: blah"
<13>Oct 21 09:58:11 me[2606]: foo: blah
root at probook:~ # logger -t "me" --no-act --stderr  --id=$PPID "foo: blah"
<13>Oct 21 09:58:13 me[2606]: foo: blah
root at probook:~ # logger -t "me" --id=$PPID "foo: blah"
root at probook:~ # Oct 21 10:02:33 probook.fritz.box me[2928]: foo: blah
logger -t "me" --id=$PPID "foo: blah"
root at probook:~ # Oct 21 10:02:34 probook.fritz.box me[2929]: foo: blah


I expect "me[2606]" to appear in "journalctl -f" output, but appearently the id
is always replaced by the pid of logger.
How should a script look like to comply with systemd?

Olaf


More information about the systemd-devel mailing list