Reboot Netgear CPE/modem/router from command-line

- Posted in Uncategorized by

Use wget and perl to reboot a Netgear ISP provided CPE/modem/router from comandline. Replace IP-address and 'REALPASSWORD' with your own settings

id=$(wget --quiet -O- --http-user admin --http-password password http://192.168.100.1/RouterStatus.htm | perl -lne '/id=([0-9]+)/ && print $1'); wget --quiet --http-user admin --http-password REALPASSWORD --post-data 'buttonSelect=2' http://192.168.100.1/goform/RouterStatus?id="$id"