LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-06-2009, 04:18 AM   #1
talat
Member
 
Registered: Jan 2006
Distribution: Centos
Posts: 145

Rep: Reputation: 16
Question Syslog-ng and named logs


Hi Guys,

I have a Centos 4.4 installed on a machine . On this machine i was running my DNS server. I was getting the DNS logs in /var/log/messeges when i was running syslog service on it due to the following line in syslog.conf.


*.info;mail.none;authpriv.none;cron.none /var/log/messages

Now i have installed syslog-ng on this machine and following are the lines in syslog-ng.conf for info messages.

destination d_mesg { file("/var/log/messages"); };
filter f_filter2 { level(info..emerg) and
not (facility(mail)
or facility(authpriv)); };


log { source(s_sys); filter(f_filter2); destination(d_mesg); };


Now in /var/log/messages i am not getting the named logs in /var/log/messages with syslog-ng. Can u let me know what could be wrong.
 
Old 05-07-2009, 01:21 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
I'm not sure what facility / prio bind uses by default - it might be daemon:info -, but either way it's nicer to set your own to know where you stand... http://users.hszk.bme.hu/~bp/bind/logging.html
 
Old 05-14-2009, 10:19 AM   #3
jerrybell
LQ Newbie
 
Registered: May 2009
Posts: 3

Rep: Reputation: 0
You should be able to do something like this (as an alternative to changing the bind config):



destination d_mesg { file("/var/log/messages"); };
filter f_filter2 { program("named") or (level(info..emerg) and
not (facility(mail)or facility(authpriv))); };


log { source(s_sys); filter(f_filter2); destination(d_mesg); };


I haven't verified that it works, but seems like it should.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
syslog not opening named pipe. fluxrad Linux - Software 5 02-10-2009 05:31 AM
syslog not writing to named pipe (fc4) darbo Linux - Software 0 02-17-2006 07:35 PM
why is named burning syslog? eantoranz Linux - Networking 5 07-29-2005 11:47 AM
Syslog & Named Fails At Boot? ACR Fedora 1 03-31-2005 01:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 01:10 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration