I've had frustrating issues with a computer whose network drops at apparently random times and as a work-around I made a simple cron job to restart it every hour. But this seems silly if the network is already up -- why restart it, right?
So is there a simple script I could create that will first check (ping? ifconfig?) to see if the network is working and then only restart if that returns false? Or a flag on network-manager that will check itself?
My cron is just this:
15 * * * * /sbin/service network-manager restart
Thanks in advance to anyone with ideas on how best to "network-manage" this! (pun intended!) :-)