Filter out repeating messages


 
Thread Tools Search this Thread
Operating Systems Solaris Filter out repeating messages
# 1  
Old 01-24-2005
Filter out repeating messages

The unix servers at my site are constantly receiving "community check" messages from a server located on our WAN, in another city. Here is the example:

Jan 23 15:41:08 eagles/usr/lib/snmp/snmpdx: [ID 686298 daemon.error] community_check();bad community from rams.nw.sw.ournetwork.com

How can I filter out these messages so that /var/adm/messages doesn't fill up with them?

Thanks
# 2  
Old 01-28-2005
Check the man pages for:
syslog.conf
syslogd

Also look at /usr/lib/newsyslog - for moving log files before they get too big.

As far as filtering out, you can't - not without losing other errors that may not be showing up now, but you would want to see if they did show up. The syslog isn't configured to cut out one specific item. Use (e)grep -v when viewing the file to 'remove' the error.
# 3  
Old 01-31-2005
The solution for this particular situation was to use egrep -v to filter out the unwanted messages (per your suggestion). I then went through the filtered messages file to check for any other unwanted messages (there were none). I deleted the original messages file, touched a new messages file and I'm done! The size of the new filtered messages file is only 10% of the HUGE original file.

Thanks RTM, you is my guru. Smilie
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Repeating Multiple Fields

I am trying to find a way to repeat fields. I am not really sure how to explain it so let me just post a sample and what I want it to look like. 888123 66232 18 1 19 44422 11 7 23 881133 66231 33 1 34 ... (4 Replies)
Discussion started by: DerangedNick
4 Replies

2. Homework & Coursework Questions

repeating test several times

echo "Enter Number of times u want this to be run" read RUN for i in {1..$RUN} do echo "i am going to market" done now the issue is that when i run this script it ask me "Enter Number of times u want this to be run" and then i put the value ,say i put 10, but when the script runs it gives... (1 Reply)
Discussion started by: bharat8007
1 Replies

3. Shell Programming and Scripting

Repeating loop between dates

Hi , I need to execute set of commands between two parameterized dates. Suppose, If parameter1 is Feb1st-2010 and parameter2 is November15th-2010. I need to execute a set of commands within these dates . can any one help me to build a loop so that it should execute for 28days in February... (4 Replies)
Discussion started by: Raamc
4 Replies

4. Shell Programming and Scripting

Repeating Substitution Command on VI

Hello Folks, how to write a command on vi that allow to repeat last substitution command? Here what I want to do : 1 2 3 1 2 3 1 2 3 :.,+2s/\n/ /And I obtain : 1 2 3 1 2 3 1 (5 Replies)
Discussion started by: gogol_bordello
5 Replies

5. Linux

Filter syslog messages.

Hello, How can we filter messages like : indrh03 sshd: Accepted publickey for score from 192.168.18.47 port 51034 ssh2 indrh03 sshd: pam_unix(sshd:session): session opened for user score by (uid=0) indrh03 sshd: pam_unix(sshd:session): session closed for user score such that they... (3 Replies)
Discussion started by: mahive
3 Replies

6. Shell Programming and Scripting

Value repeating problem in columns

Hi, I have a file like this 0817 0201364 1 866 . . . . . . . 574 . 100.0 100.0 5529737 1 TV 0817 0201364 2 1440 . . . . . . . . . . . 5529737 1 TV 0817 0201364 6 1323 . . . . ... (2 Replies)
Discussion started by: Sandeep_Malik
2 Replies

7. Shell Programming and Scripting

Repeating variables in the code

Hi all, I had written 3 KSH scripts for different functionalities. In all these 3 files there are some 30 variables in common. So I want to reduce the code by placing these variables in a common properties file named (dataload.prop/dataload.parms/dataload.txt) or txt file and access it... (1 Reply)
Discussion started by: mahalakshmi
1 Replies

8. Shell Programming and Scripting

Repeating commands in a script

I have written a script that I want to be repeated. The script that I wrote outputs the date, how many people are on the system, how many people logged in before me, and how many people logged in after me. Than what I want it to do is after it outputs the 4 lines I want it to go back to the... (4 Replies)
Discussion started by: Dave2874
4 Replies

9. UNIX for Dummies Questions & Answers

Omit repeating lines

Can someone help me with the following 2 objectives? 1) The following command is just an example. It gets a list of all print jobs. From there I am trying to extract the printer name. It works with the following command: lpstat -W "completed" -o | awk -F- '{ print $1}' Problem is, I want... (6 Replies)
Discussion started by: TheCrunge
6 Replies

10. UNIX for Advanced & Expert Users

repeating kernel message

Hi, I am getting multiple repeats of the following message in /var/log/messages Jul 26 13:36:04 linuxnol kernel: cdrom: open failed. Jul 26 13:36:11 linuxnol kernel: cdrom: open failed. Jul 26 13:38:18 linuxnol kernel: cdrom: open failed. Jul 26 13:38:26 linuxnol kernel: cdrom: open... (2 Replies)
Discussion started by: progressdll
2 Replies
Login or Register to Ask a Question