Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
02-22-2004, 04:18 AM
|
#1
|
LQ Newbie
Registered: Feb 2004
Posts: 13
Rep:
|
Can't get syslog to record messages from my router
Hi there, bit of a newbie question probably so sorry, but here goes.
I've got a Netgear DG834 router, and I want its log messages to be logged by my Fedora box. So at the router end, I've set it to send syslog messages to the IP address of my linux box, nothing too difficult there.
In /etc/init.d, I've made sure that SYSLOGD_OPTIONS is set to '-r -m 0' (I assume this is correct?)
I haven't changed the default /etc/syslog.conf file (Do I need to?)
Don't get any of the messages logged in any of the log files.
Even if I can get this first stage to work, I assume the router logs would get logged in /var/log/messages under the default syslog.conf, I suppose a second question would be how do I get messages from the router to be logged under a separate router.log file?
Many, many thanks in advance for any help!
Spencer
|
|
|
02-22-2004, 05:36 AM
|
#2
|
LQ Veteran
Registered: Sep 2003
Posts: 10,532
|
Sending machine:
Don't know how you send the syslog messages to the receiving machine. If this modem has a syslog facility make sure that the following line is present:
*.* @<host> => where <host> is the name of the receiving machine. All messages (*.*) are send to <host>.
Do not forget to restart syslogd on the sending machine.
Receiving machine:
The SYSLOGD_OPTIONS should be: -r -s <domain>
The -m 0 can be included, this has nothing to do with this problem so I'm not going to mention this option any more.
Restart syslogd on the receiving machine.
For more detailed info take a look at:
man syslogd
man syslog.conf
The messages comming from the sending machine will have it's hostname in front of the message:
Feb 22 12:14:54 exile kernel: Kernel log daemon terminating.
Feb 22 12:14:55 exile exiting on signal 15
Feb 22 12:14:55 exile syslogd 1.4.1: restart (remote reception).
Feb 22 12:15:24 inferno root: testing
The sending machine is inferno.nemesis.nl (<host> would be exile)
Receiving machine is exile.nemesis.nl (<domain> nemesis.nl)
The messages file on exile shows the testmessage from inferno.
Hope this gets you going again.
Last edited by druuna; 02-22-2004 at 05:38 AM.
|
|
|
02-24-2004, 05:07 AM
|
#3
|
LQ Newbie
Registered: Feb 2004
Posts: 13
Original Poster
Rep:
|
Hmm, no this still doesn't work.
I've checked with Ethereal that the packet from the router is definitely arriving at the linux box, so its not at the router end. It's just that syslog is not recording any of the messages....
Any other ideas highly appreciated! Thx in advance
|
|
|
02-24-2004, 12:10 PM
|
#4
|
LQ Veteran
Registered: Sep 2003
Posts: 10,532
|
First thing that comes to mind: Is a 'rule' present in syslog.conf (receiving side) that sends all messages to a logfile?
Something like: *.* -/var/log/allmessages.
Another thing I was wondering about: Is your router actually sending the messages in a format that syslog (receiving side) understands? I.e. Is the router logging facility actually done by syslog, or some other program. Ethereal can help you here.
What does the received packet look like. Is it a UDP packet, source and destination port 514? Any followup error messages. An ICMP destination unreachable is what I get when the receiving side is not accepting foreign syslog messages (no -r -s <domain>).
I can also see the Facility and Level of the syslog message received, are yours correct?
If you wonder which are correct: see man syslog.conf
When all is working, you should only see the test message you are sending. Can you use logger (or a simular log test facility) on your router?
|
|
|
All times are GMT -5. The time now is 03:02 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|