Topic: Script to auto repair network connection?
For some reason my chumby hates staying on the internet. It gets into a state where it has network signal (green bars) but it says "Not Connected" in the control panel. In this state, I can use internet radio but my channels won't load. The fix is to either reboot or to go through the network wizard again, reselecting my active connection and letting it do its thing so that the control panel figures out that it actually is connected.
Here's what I want:
* A way to check state of the network the same way the control panel does.
>> I've looked as some of the scripts like network_status but that lies. It will return UP even when the interface is up and as stated in the problem, the interface IS up but the control panel is confused.
* Once I've detected that the chumby is in this state, I want to "fix" the connection. Knowing how the control panel checks will make this easier. Here are some initial thoughts:
>> Simply call reboot and say screw it. It's really slow though and kind of a waste considering that it actually IS connected.
>> Call some script to re-init the control panel. Is there a safe/sane way to do this?
>> Write to some file that the control panel is using to check state. This likely doesn't exist.
>> Call start_network/restart_network. I haven't had good luck with this. The interface doesn't want to come back up but that's probably because I called it from SSH and the session dies when you call it (I tried backgrounding the call but it still didn't work)
Any ideas? Known solutions (chumby only/no "change your router" responses)?
-Kyle