From owner-freebsd-questions Wed Apr 29 06:12:54 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id GAA24924 for freebsd-questions-outgoing; Wed, 29 Apr 1998 06:12:54 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from mrelay.jrc.it (mrelay.jrc.it [139.191.1.65]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id GAA24911 for ; Wed, 29 Apr 1998 06:12:46 -0700 (PDT) (envelope-from dirk.vangulik@jrc.it) Received: from mda00.jrc.it (mda00.jrc.it [139.191.7.10]) by mrelay.jrc.it (LMC5688) with ESMTP id PAA14089; Wed, 29 Apr 1998 15:12:28 +0200 (MET DST) Received: (from dirkx@localhost) by mda00.jrc.it (8.8.5/8.8.5) id PAA23899; Wed, 29 Apr 1998 15:13:21 +0200 (CEST) Date: Wed, 29 Apr 1998 15:13:21 +0200 (CEST) From: Dirk-Willem van Gulik X-Sender: dirkx@mda00.jrc.it To: =?iso-8859-1?Q?Patrik_=C5str=F6m?= cc: "'freebsd-questions@freebsd.org'" Subject: Re: Monitoring a HTTP service !! In-Reply-To: <43A432602D33D111BA8F00805FA6FE132CC789@STK_FILE> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Content-Transfer-Encoding: 8BIT Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Check out libwww, it has a nice fetcher. you could use the HEAD request; or intentially call a 'fake' page; to avoid logging trouble. Or use the exit code from a crontab' 1 * * * * * /usr/sbin/fetch http://some/where/test.html > /dev/null will send you an email on failure. Dw. On Wed, 29 Apr 1998, [iso-8859-1] Patrik Åström wrote: > Hi! > > I need to monitor a Microsoft IIS server, I have lots of trouble with > this one and can not change to FreeBSD due to some special applications. > I would like to be able to have cron job that calls a program that > checks if this server respond to http requests. I could make bourne > script and use "wget" or some other software to retrieve a .html > document but I don't want to retrieve a document just se if the server > respond to calls on port 80. Is there a perl script that use the > "socket" call or some other neat way to fix this, I would be most > grateful for any hints or suggestions. > > Regards Patrik Astrom, Stockholm > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message