in reply to Re: storing result in variable
in thread storing result in variable

You may be right about Net::Ping to work better than a system call. But it slightly differs from the ping-program. The default protocol for Net::Ping is tcp where ping uses icmp. The tcp-connection requires a running echo-service on the remote machine whereas the icmp-connection (usually) requires the icmp-packages not to be explicitly dropped.

With Net::Ping you can specify icmp as the connection method but this requires root permissions.

--
trust in bash
but tie your camel