We run cups servers around the college and I'd like to be able to setup the system to email me if
the printers are out of paper. If I look in /var/log/messages I can see an entry like lp0 out of
paper but what I'm not sure about is how to get the system to mail me if this is the case.
I thought about doing a tail /var/log/message | grep lp0 say every 2 minutes but once the printer
has paper how do you know this and not stop multiple messages until there are a few more entries in
/var/spool/messages or if there is a lot happening on the box the grep command might miss it.
Can you do a time sensitive grep ?
Idea's please
Brian
------------------------------------------------------------------------
The views expressed here are my own and not necessarily
the views of Portsmouth College