Re:My 10 UNIX Command Line Mistakes
by gnosis on Sunday February 27, 2011 @04:32PM
(#2269033)
You could also just save the current firewall config, and then have the script restore the saved config after a minute. No need to reboot.
[ Parent
| on HN ]
The script was: sleep 1 minute, then restore rules, sleep 1 more minute, then reboot.
That first rule restore was so I could conceivably get things back in order before the reboot. I had the final reboot there in case the new firewall rules somehow killed my ssh session. This never happened, and I might have been able to ssh in again at that point, but I wasn't going to count on it.