Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 12-14-2004, 03:45 PM   #1
LQ Newbie
Registered: Nov 2004
Posts: 26

Rep: Reputation: 15
filter /etc/messages for certain IP table entries

I have specific iptables chains that if traffic matches, it will drop the packet and log the event. No problem setting that up.

What I want to do is setup a script (perl/.sh or the sort) to filter through /etc/messages and write a seperate logfile with all the information matching the iptables --log-prefix messages. So could I do something like:

grep $RULE /etc/messages > /var/log/iptables.log

Then setup a cron to do this every 24hrs while rotating the file before the update.

Anyone think this will work? I think it should.....


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
forced reconnect creates multiple ppp0 entries in snmp table vimico Linux - Networking 0 11-07-2005 05:01 AM
/var/log/messages weird entries blizunt7 Linux - Security 5 11-01-2005 05:56 PM
Adding entries to route table in C? kuronai Programming 2 04-04-2005 02:42 PM
How to save routing table entries? drgowans Linux - Networking 6 09-23-2003 02:35 PM
Route table loses entries filth Linux - Networking 3 05-05-2003 05:27 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:10 PM.

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