Hi, All i have a little Perl script that is, among other things, checking the status of ports on remote machines. with TCP ports it seems to work fine. however, when i try the same thing on UDP ports it seems to always work all the time on all servers, even when the port is down. the code i'm using is as follows:
my $socket = new IO::Socket::INET (PeerAddr => "$host", PeerPort => "$port", Proto => "udp", Type => SOCK_DGRAM, LocalAddr => "localhost"); if ($socket) { $up = $up . " port $port open"; } else { $up = $up . " port $port not open"; } the ($socket) test is always true. shouldn't it be true only if the port is actually up? i wonder if some sharper pair of eyes can see what i may be doing wrong here. TIA Jim Lane Sr. Technical Consultant Network Services Toronto Hydro office: (416)-542-2820 cell: (416)-896-8576 _______________________________________________ Perl-Unix-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs