==================================================================
Please DO NOT REPLY to this mail or send email to the developers
about this bug. Please follow-up to Bugzilla using this link:
http://bugs.contribs.org/show_bug.cgi?id=8120
Have you checked the Frequently Asked Questions (FAQ)?
http://wiki.contribs.org/SME_Server:Documentation:FAQ
Please also take the time to read the following useful guide:
http://www.chiark.greenend.org.uk/~sgtatham/bugs.html
==================================================================
--- Comment #8 from John Crisp <[email protected]> ---
Ahhh.... try this - subsitute your own IPs. I needed the $my_addr for the
source IP
use Net::Ping;
$host = '192.168.10.2';
$my_addr = '192.168.10.1';
@host_array = ('192.168.10.1','192.168.10.2','192.168.10.3');
$p = Net::Ping->new();
print "$host is alive.\n" if $p->ping($host);
$p->close();
$p = Net::Ping->new("icmp");
$p->bind($my_addr); # Specify source interface of pings
foreach $host (@host_array)
{
print "$host is ";
print "NOT " unless $p->ping($host, 2);
print "reachable.\n";
sleep(1);
}
$p->close();
Output :
192.168.10.2 is alive.
192.168.10.1 is reachable.
192.168.10.2 is reachable.
192.168.10.3 is reachable.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Mail for each SME Contribs bug report
To unsubscribe, e-mail [email protected]
Searchable archive at http://lists.contribs.org/mailman/public/contribteam/