Re: StandardOutput=append

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fr, 30.08.19 17:39, Kenneth Porter (shiva@xxxxxxxxxxxxxxx) wrote:

> I have a backup script that runs periodically via cron. Instead of mailing
> me a large log, I wanted to have it append to a log file that can be rotated
> and compressed by logrotate. So I removed my link from /etc/cron.hourly and
> created service and timer units.
>
> My first cut at writing a log file was to use the append option to
> StandardOutput:
>
> [Service]
> ExecStart=/home/Mirror/rsync-Saruman.sh
> StandardOutput=append:/var/log/rsync-Saruman.log
>
> In /var/log/messages I see:
>
> Failed to parse output specifier, ignoring:
> append:/var/log/rsync-Saruman.log
>
> <https://www.freedesktop.org/software/systemd/man/systemd.exec.html>
>
> Based on some hints at the following link, I think I'll change this to use
> syslog and add an rsyslog config file to redirect to the desired file. But I
> wanted to find out why the append feature doesn't work.

Whcih version of systemd are you running? append: is available since
240. See NEWS.

Lennart

--
Lennart Poettering, Berlin
_______________________________________________
systemd-devel mailing list
systemd-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/systemd-devel




[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux