ive got a simple sh script that pings machines on my network segment. very new to perl, could folx on the list give me some hints/pointers to how to make this shell script into a perl one?
!/usr/bin/sh SERVERS="itsux17 its29 itsux24 int-dns1 int-dns2 mrtg defgtway" for S in $SERVERS do PING1=`/etc/ping $S 32 -n 6 | grep trans | awk '{print $7}' | cut -d"%" -f1` if [ $PING1 -gt 25 ]; then if [ $PING1 -gt 99 ]; then mailx -s "CRITICAL: $PING1 % errors on $S Server may be down" [EMAIL PROTECTED] else mailx -s "WARNING: $PING1 % errors on $S" [EMAIL PROTECTED] fi fi done exit Phil -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]