Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: packet types & ports

by Kanji (Parson)
on Sep 23, 2002 at 17:48 UTC ( #200182=note: print w/ replies, xml ) Need Help??


in reply to packet types & ports
in thread Module Net-Ping

It's seems weird to be advocating another non-Perl solution in so short a timespan, but this is something done obscenely easy with a shell script if your ping binary has appropriate permissions (they usually do)...

#!/bin/sh PING='/bin/ping -c 5' # FreeBSD/Linux #PING='/usr/sbin/ping' # Solaris FETCHMAIL='/usr/local/bin/fetchmail -s -t 60' $PING $hostname 1>/dev/null 2>&1 \ && $FETCHMAIL

If you absolutely must write something in Perl, then I second blm's suggestion of Net::Ping::External (alt.).

    --k.



Comment on Re: packet types & ports
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://200182]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (13)
As of 2014-10-01 19:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    What is your favourite meta-syntactic variable name?














    Results (37 votes), past polls