25 Aug
2011
25 Aug
'11
5:18 p.m.
"Aldrich, Jamie S" <JSAldrich@pier1.com> writes:
I am trying to setup syslog-ng to use the DAY and MONTH variable on the source file input. What am I doing wrong?
source s_file { file("/psfs_logs/APPSRV_${MONTH}${DAY}.LOG" flags(no-parse)); };
Those macros are not supported on the source side, because they're based on when a particular message arrived, and that's understandably not known at the time the file should be opened. (At least, to the best of my knowledge.) The easiest way I can think of right now, would be to set the file to /pfs_logs/APPSRV_current.LOG or somesuch, and make it a symlink to the most recent file (and keep it up to date with an external script). -- |8]