Hi, I need little help I wrote these lines which basically pings a server one time and if ping goes fine, nothing is done But if pings fails it sends email What I want is that it should ping three times in a row when the ping fails and then sends email It should not send email if it fails to ping once
Thanks in advance junaid @result=system("tnsping smith"); foreach $line (@result) { if ($line eq 0) { print LOG "Pinging to smith went OK\n"; print LOG "No E-mail is being sent\n"; } else { print LOG "Unable to ping smith\n"; &email ("\nUnable to Ping smith on $t\n"); close LOG; exit; }; }; -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]