[rsyslog-notify] Forum Thread: Re: buffer data when output file is not writeable - (Mode 'reply')
noreply at adiscon.com
noreply at adiscon.com
Wed Jul 6 23:26:45 CEST 2016
User: peterlytx
Forumlink: http://kb.monitorware.com/viewtopic.php?p=26705#p26705
Message:
----------
I ended up using the following (slightly clunky) workaround with symlinks
to meet my requirements.
[list:3sg02bbg]
1. Configure rsyslogd to write the log file to a file on the tmpfs,
/tmp/syslog
2. When the non-volatile filesystem at /var becomes writable
[list:3sg02bbg]
a. Append the contents of the temporary file to the file on the
non-volatile filesystem
[code:3sg02bbg]cat /tmp/syslog >> /var/log/syslog[/code:3sg02bbg]
b. Replace the /tmp/syslog file with a symlink to the file on the
non-volatile filesystem
[code:3sg02bbg]ln -sf /var/log/syslog /tmp/syslog[/code:3sg02bbg]
c. send rsyslogd a sighup
[code:3sg02bbg]kill -hup `pidof rsyslogd`[/code:3sg02bbg]
[/list:u:3sg02bbg]
[/list:u:3sg02bbg]
More information about the rsyslog-notify
mailing list