Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Re: Ping and Linux firewall

by trippledubs (Deacon)
on Sep 02, 2015 at 16:24 UTC ( #1140813=note: print w/replies, xml ) Need Help??

in reply to Ping and Linux firewall

By default Net::Ping does a tcp ping. Normal OS pings are usually ICMP. You could try allowing inbound port number 7 to make the TCP Net::Ping work or
$p = Net::Ping->new("icmp");
to make your Net::Ping use ICMP protocol.

Replies are listed 'Best First'.
Re^2: Ping and Linux firewall
by chrestomanci (Priest) on Sep 07, 2015 at 10:36 UTC

    Agreed, You will probably have more luck with an ICMP ping.

    One caveat, is that on Linux at least, your perl process will need root to send ICMP packets. (you will find that the ping binary is setuid root on Linux). This might not be an issue on windows as the security tends to be more lax, and you are probably logged in with admin privileges, but it is something to keep in mind.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (3)
As of 2020-10-22 01:02 GMT
Find Nodes?
    Voting Booth?
    My favourite web site is:

    Results (225 votes). Check out past polls.