At 12:24 PM 1/4/2002 +0000, John Edwards wrote:
>How about pinging several hosts that have a pretty good chance of being up.
>www.microsoft.com, www.netscape.com, www.ibm.com, etc, etc. You could also
>ping your local gateway address.
>John
>
>-----Original Message-----
>From: Gary Hawkins [mailto:[EMAIL PROTECTED]]
>
>How can I check whether the system is connected?
>
>Want to pause the script if connection is lost.

Frequently, people ask the wrong question in this situation and make life 
unnecessarily complicated,

Instead of trying to check whether "there is an Internet connection," just 
see whether you can do whatever it is your program is using the Internet 
for.  After all, what good will it do you to reach ibm.com if the route to 
the place you're really connecting to goes down?  Besides, places like 
ibm.com often set up firewalls that keep pings out.

Peter Scott
[EMAIL PROTECTED]
http://www.perldebugged.com


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to