[CentOS] syslog question

James Pifer jep at obrien-pifer.com
Tue Jul 29 20:31:53 UTC 2008


On Tue, 2008-07-29 at 12:52 -0600, Milton Calnek wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> James Pifer wrote:
> | Yeah, that was pretty easy. Any way to get it to save logs from
> | different hosts to specific files?
> 
> You need rsyslog for that.
> I believe that FC9 has an rpm for it. There are other places to find
> one as well. KB may have one in his repo.
> 

Okay, I have rsyslog running and regular syslog stopped. Also
chkconfig'ed them. 

I added this to /etc/rsyslog.conf:
$template DynaFile,"/var/log/system-%HOSTNAME%.log"
*.* -?DynaFile

The log that gets created for my router is called:
system-Tue,.log

So I've been trying to modify it using a different propnames instead of
%HOSTNAME%. So far all I get for a result is:
system-**INVALID PROPERTY NAME**.log

In upper and lower case I've tried:
source
fromhost
fromhost-ip

Any suggestions? It's so close now!

Thanks,
James




More information about the CentOS mailing list