Re: [systemd-devel] SyslogIdentifier does not work for messages printed with sd_journal_print

2015-06-09 Thread Lennart Poettering
On Tue, 02.06.15 20:31, Martin Belanger (martin.belan...@cyaninc.com) wrote: I'm using systemd 219 (Ubuntu 15.04). I have three instances of a daemon running. I use SyslogIdentifier to give each of them a unique identifier (e.g. myproc-1, myproc-2, myproc-3). I also redirect stdout/stderr

Re: [systemd-devel] SyslogIdentifier does not work for messages printed with sd_journal_print

2015-06-09 Thread Martin Belanger
Hi Lennart, I found a workaround. When looking at the source code for sd_journal_print(), I saw that SYSLOG_IDENTIFIER defaults to the string pointed to by program_invocation_short_name (defined in errno.h). So I simply create a new string with the text that I want to assign to SYSLOG_IDENTIFIER

Re: [systemd-devel] SyslogIdentifier does not work for messages printed with sd_journal_print

2015-06-09 Thread Lennart Poettering
On Tue, 09.06.15 13:50, Martin Belanger (martin.belan...@cyaninc.com) wrote: Hi Lennart, I found a workaround. When looking at the source code for sd_journal_print(), I saw that SYSLOG_IDENTIFIER defaults to the string pointed to by program_invocation_short_name (defined in errno.h). So I

[systemd-devel] SyslogIdentifier does not work for messages printed with sd_journal_print

2015-06-02 Thread Martin Belanger
I'm using systemd 219 (Ubuntu 15.04). I have three instances of a daemon running. I use SyslogIdentifier to give each of them a unique identifier (e.g. myproc-1, myproc-2, myproc-3). I also redirect stdout/stderr to the journal using StandardOutput=journal and StandardError=journal. I noticed