I've started playing with POE::Wheel::FollowTail to monitor many logfiles and create a new logfile of the stuff I was interested in. Optionally, I would backquote execute other scripts when I run across specific things I was interested in. For the most part, all this is working fine.

My list of what files to look at, a list of strings to look for in each log file, and an optional script-name to run, are all contained in a configuration file that gets read when my FollowTail script starts up.

Without stopping my FollowTail script, how could I detect whether my configuration file changed so I could re-read it and update my list of files/strings to monitor?

Another question: I want to allow other applications to grab (read, delete, rename) my consolidated logfile at any time. So I'm opening for append/writing/closing through a file handle each time I add stuff. Is this the most efficient way? It'd be faster if I could just leave my logfile open for append, but then no one can grab the file at any time.

Finally, I have a Unix (maybe Perl) question that's not really related, but kinda is. There is a VxWorks system that I can only telnet into, and once in, that system is continually spewing out stuff that my FollowTail script would monitor if only the stuff was going to a log file. The developers of the other system do not want to write the stuff to a log file and make it accessible to me via NFS mount (it "puts too much of a load on the cpu"). And there's no rsh or ssh allowed into their system. With that, I assume they won't want to do any sockets with me.

I was just wondering, since I can telnet in and see everything dumped to the screen, could I intercept that stream? Sort of a telnet pipe out?

Thanks.


In reply to POE::Wheel questions by shockers

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.