From owner-freebsd-questions Mon Jul 5 20:22:31 1999 Delivered-To: freebsd-questions@freebsd.org Received: from mail.actrix.gen.nz (mail2.actrix.gen.nz [203.96.16.37]) by hub.freebsd.org (Postfix) with ESMTP id 49C1214F09 for ; Mon, 5 Jul 1999 20:22:08 -0700 (PDT) (envelope-from dan.langille@dvl-software.com) Received: from actrix.gen.nz (www@lemuria.actrix.gen.nz [203.96.16.20]) by mail.actrix.gen.nz (8.9.1/8.9.1) with SMTP id PAA16538; Tue, 6 Jul 1999 15:21:54 +1200 (NZST) From: "Dan Langille" Reply-To: dan.langille@dvl-software.com To: Burke Gallagher Cc: Anton Berezin , freebsd-questions@FreeBSD.org Date: Tue, 6 Jul 1999 15:21:54 nzst Subject: Re: running frequent cron perl scripts X-Mailer: DMailWeb Web to Mail Gateway 2.1t, http://netwinsite.com/top_mail.htm Message-id: <37817652.94.0@actrix.gen.nz> X-User-Info: 202.37.52.5 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG >Here is the script i just debugged using my apache server (I don't have a >Nokia M10). Thanks. I made the changes to my code as you suggested and it worked! And it *is* much faster. There seems to be quite a bit of overhead in loading perl, but after that it seems quite fast. It's hard to tell at the moment because of telnet lag, but when I get home tonight I'll have a close look at times. Here's the output from the script: $ perl get_ip.sh DYNDNS DYNDNS start DYNDNS 2nd DYNDNS 3rd GET /shell/show+ip+interfaces 1.1 Accept: text/*, text/html Authorization: Basic MadeHardBy:Telecom DYNDNS 4th DYNDNS 5th DYNDNS 6th DYNDNS 7th DYNDNS 8th DYNDNS loop DYNDNS loop DYNDNS loop DYNDNS loop DYNDNS 9th DYNDNS 10th currentIP = , lastIP = 0.55.152.24 change detected ^ | then it ran the yi.org update script. Note it didn't print the currentIP. Ignore the last IP. I manually modified the file contents to force an update. FWIW: Here's the log: Jul 6 15:09:43 ns DYNDNS[57193]: start Jul 6 15:10:07 ns The[57210]: IP Address has changed to Jul 6 15:10:07 ns DYNDNS[57211]: stopped Note that: syslog( "The IP Address has changed to $currentIP" ); does not actually print the IP. I had this problem with my original script and don't know how to fix it. I am impressed. Very impressed. - Dan Langille To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message