#!/usr/bin/perl #first we start out with an infinite loop while( 1 ) { #next we have it check every 20 seconds sleep 20; #next, we will have our firewall stop, our dialing (of ppp3) #our updated dyndns.org entry, and then our firewall restarted #*ALL* based on if the netstat does *NOT* show ppp0 #*NOTE* you will need to keep this all on ONE LINE! system( "pmfirewall stop;killall ping;killall pingfdt;/sbin/ifup ppp0;pmfirewall start;ddup --host kdavis.dyndns.org;pingfdt" ) if `netstat -i` !~ /ppp0/; }