It does not compile on Netware, but it's OK on Windows. For Netware, I
copied from my Windows PC the perl/lib and perl/site directories to Netware
because Sockets::IO was not found. Now, I get:
Missing $ on loop variable at sys:\perl\lib/strict.pm li
BEGIN failed--compilation aborted at sys:\perl\lib/IO/So
BEGIN failed--compilation aborted at pyhbclt.pl line 3.
Can anyone point me in a direction here with this error?
Another problem I had but resolved: I thought the sleep was in
microseconds, not seconds. It would work once then not again. Then I
decided I had to test EVERYTHING. Thanks to all those who helped. For
anyone who wants to use PYTHONS ThreadedHeartBeatServer.py by Nicola Larosa
to monitor a Netware Server, the Perl port is here:
#!/usr/bin/perl
use IO::Socket::INET;
use Time::HiRes qw( time alarm sleep );
do
{
my $MySocket=new IO::Socket::INET->new(Proto=>"udp",
PeerPort=>43278,
PeerAddr=>'localhost'
) or die "Can't make UDP socket: $@";
$msg="PyHB";
$MySocket->send($msg);
sleep (5);
}
while (1==1);
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>