Koozali.org: home of the SME Server

Remote logging to different file

Jon_Reynolds

Remote logging to different file
« on: January 21, 2006, 02:09:19 AM »
Hello,

I'm stuck. I am remote logging to a server but all the logs are going into /var/log/messages and I want to be able to log them to a separate log file, like say /var/log/remotesystem instead of /var/log/messages.

Does anyone have an idea on how to make this happen?

Jon

Offline Franco

  • *
  • 1,171
  • +0/-0
    • http://contribs.org
Remote logging to different file
« Reply #1 on: January 21, 2006, 03:12:37 AM »
Do you want to modify the syslog.conf or do you want to send the messages to a remote system across the net?

Jon_Reynolds

Remote logging to different file
« Reply #2 on: January 21, 2006, 03:18:38 AM »
I already have it remote logging to the sme server but it is logging to the /var/log/messages. I would like it to log to say /var/log/remotebox instead of messages. I kind of understand what I need to do but not sure how to go about it.

Thanks for the help,

Jon

Offline Franco

  • *
  • 1,171
  • +0/-0
    • http://contribs.org
Remote logging to different file
« Reply #3 on: January 21, 2006, 03:57:56 AM »
take a look at /etc/e-smith/templates/etc/syslog.conf/ and every file within, the 00filename dictates where to write and the others are template driven that will obey this 00filename according to what it says.
But I think there will be complications to the web interface since it follows these names when it reads the logs and parse them to the user ($messages)

Offline Franco

  • *
  • 1,171
  • +0/-0
    • http://contribs.org
Remote logging to different file
« Reply #4 on: January 21, 2006, 03:00:33 PM »
Thinking in the lines of using somenthing like logwatch instead of modifying templates, which eventually will be a problem with updates and such, I came across this post which may be exactly what you're looking for:
http://forums.contribs.org/index.php?topic=19945.0

And if logwatch will do what you need, then you're with luck, a new version just came out:
http://www2.logwatch.org:8080/tabs/download/