From owner-freebsd-hackers Tue Feb 4 00:25:34 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id AAA29860 for hackers-outgoing; Tue, 4 Feb 1997 00:25:34 -0800 (PST) Received: from korin.warman.org.pl (korin.warman.org.pl [148.81.160.10]) by freefall.freebsd.org (8.8.5/8.8.5) with ESMTP id AAA29843 for ; Tue, 4 Feb 1997 00:25:23 -0800 (PST) Received: from localhost (abial@localhost) by korin.warman.org.pl (8.8.3/8.7.3) with SMTP id JAA11265; Tue, 4 Feb 1997 09:23:42 +0100 (MET) Date: Tue, 4 Feb 1997 09:23:41 +0100 (MET) From: Andrzej Bialecki To: Chris Coleman cc: "Daniel O'Callaghan" , Troy Curtiss , freebsd-hackers@freebsd.org Subject: Re: Two-way pipe possible without C/perl? In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk On Mon, 3 Feb 1997, Chris Coleman wrote: > I like this, alot. But how are you monitoring these system so FreeBSD > knows when to send you a message? > > I have a pager and am very interested in this. > Hello! I currently use the following setup - maybe it's a little simplistic, but it works. (Assuming that your paging company allows you to send messages via modem.) * I wrote several scripts on the machines I want to monitor. They check all the parameters I'm interested in, and come out with a one-line summary. They give the total status there as well (i.e "ok" || "FIRE!!!"). I run it in crontab as often as needed. * Then there is the main script on my managing machine, which collects output from the scripts (I use `ssh -l name machine 'do_the_job.sh'`, just to be sure that sensitive data go to me only). It is also run in crontab, let's say every half an hour (some people say here: your mileage may vary :-). If it detects something unusual, it sends me a message. * How? I'm using "expect". It took me one day to grasp the basics, and another one to cut&paste one of the example scripts to do what I want. Basically, I telnet to my Xylogics Annex and use one of its modems to dial out & connect to the paging company. Then I send a message and voila! It's Sunday 3:00am and your whole family is listening to wonderfully excruciating "beep, beep, beep"... Hope this helps a bit. Andy +-------------------------------------------------------------------------+ Andrzej Bialecki _) _) _)_) _)_)_) _) _) --------------------------------------- _)_) _) _) _) _)_) _)_) Research and Academic Network in Poland _) _)_) _)_)_)_) _) _) _) Bartycka 18, 00-716 Warsaw, Poland _) _) _) _) _)_)_) _) _) +-------------------------------------------------------------------------+