I’m trying to move the cvmfs2 output from /var/log/messages into another file. I’ve tried the following on an AlmaLinux 9 host with cvmfs version 2.11.2.
- Add the following to autofs.service
StandardOutput=file:/var/log/cvmfs.log
StandardError=file:/var/log/cvmfs.log
- Adding the following to autofs.service and then creating a /etc/rsyslog.d/autofs.conf file
StandardOutput=syslog
SandardError=syslog
SyslogIdentifier="cvmfs"
# cat /etc/rsyslog.d/autofs.conf
if $programname == 'w' then /var/log/cvmfs.log
& stop
Neither seem to work. I didn’t find any logging options in the cvmfs docs that would do what I’m looking for. And I’m not sure if I’ve configured something incorrectly, it’s understood this wouldn’t work and I require something else to move the cvmfs2 output from /var/log/messages.
I don’t want to get rid of the logs. I want to move them to another file so /var/log/messages is easier to parse without sifting through cvmfs output and cvmfs output is easier to sift through without syslog output.