LinuxQuestions.org
Have you heard the LinuxQuestions.org Podcast?
Go Back   LinuxQuestions.org > Forums > Linux > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Thread Tools
Old 11-23-2004, 11:47 AM   #1
eccsamba
LQ Newbie
 
Registered: Nov 2004
Posts: 3
Thanked: 0
snmptrapd FIFO


[Log in to get rid of this advertisement]
Hi,
I am using snmptrapd program in solaris environment. I was able to successfully log the data in a simple file. I am trying to log the same data into a FIFO.
My aim to read the FIFO in real time and filter the data and send alarm to administrators accordingly.
I have configured the snmptrapd to log the data into a FIFO
using the command
snmptrapd -c conf -p logs/pid -Lf logs/current
where current is a FIFO in logs directory created using mknod command. I dont see any data coming through the FIFO.
One perspective my program cannot read the FIFO in real time. but i have tested by cat ing similar data into the FIFO. my program responded very well.
cat data > current

my programs structure is, it reads from the FIFO and sends the data into a filter script which continues with further action.

my question, is snmptrapd capable of logging stuff into the FIFO to be further read.

regards
ecc
eccsamba is offline     Reply With Quote
Old 11-23-2004, 03:39 PM   #2
bignerd
Member
 
Registered: Nov 2004
Distribution: FC1, Gentoo, Mdk 8.1, RH7-8-9, Knoppix, Zuarus rom 3.13
Posts: 98
Thanked: 0
I'm no expert on named pipes so this may not be of any assistance. The one thing I know is that if a named pipe is opened for write only before it has been opened for read then the operation will fail.

Could it be your order of accessing the pipe? Perhaps try accessing the named pipe for read with your monitor program/script before you start the snmptrapd.

I notice you used mknod p. You could have used mkfifo instead. But I don't believe that matters.

-b
bignerd is offline     Reply With Quote
Old 11-24-2004, 09:52 AM   #3
eccsamba
LQ Newbie
 
Registered: Nov 2004
Posts: 3
Thanked: 0

Original Poster
thanks

Thanks for your reply,
The order of operation does matter. Since the data coming through the pipe was at very less frequency, it looked as though the program does not work. I switched to a snmptrap with heavy information flow, now it works fine.

thanks anyways
eccsamba.
eccsamba is offline     Reply With Quote

Reply

Bookmarks


Thread Tools

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
mrtg monitoring and snmptrapd xrado Linux - Networking 0 09-29-2005 05:04 AM
mynetwatchman and snmptrapd deadite66 Linux - Security 0 12-30-2004 07:47 AM
I don't have an snmptrapd.conf jon3k Linux - Software 0 09-10-2004 05:53 PM
FIFO using pointers AquamaN Programming 2 03-21-2004 06:51 PM
snmptrapd log file aherrys Linux - Software 1 03-19-2004 11:45 PM


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

Main Menu
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
RSS2  LQ Podcast
RSS2  LQ Radio
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration