Created
August 12, 2013 09:25
-
-
Save mvaz/6209445 to your computer and use it in GitHub Desktop.
Upload dd-wrt firmware to a router. IP address 192.168.11.1 and the firmware is in dd-wrt.v24_std_generic.bin .
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| echo 'Begin ping' | |
| if ping -oc 10 192.168.11.1 > /dev/null; then | |
| echo 'the Internet is back up' | |
| echo '>> tftp 192.168.11.1 put dd-wrt.v24_std_generic.bin' | |
| echo -n "put dd-wrt.v24_std_generic.bin" | tftp -e 192.168.11.1 | |
| echo 'done' | |
| else | |
| echo 'timeout. Abort' | |
| fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment