how can i reset my router automatically on net disconnect with php cmd or any other application.....................

zuhiab commented: good +0

Dani AI

Generated

Brief, practical options tied to the replies from this thread: wants the ZTE modem to reboot automatically when the line drops; @rnyamonga pointed toward command-line access; asked for clarification on the device. The correct approach depends entirely on the ZTE model and whether the ISP locks features, so start by identifying the exact model and checking its admin pages and manual for built‑in "auto reconnect", scheduled reboot, TR‑069/TR‑064 or a protected reboot endpoint.

If the modem exposes a local admin HTTP/CGI or a telnet/SSH command to restart, automation is possible from an always‑on machine (a home server, NAS, or Raspberry Pi). The general workflow: detect loss (ping a stable public IP several times), then authenticate to the modem and invoke its reboot action. Example (replace placeholders with values from your device):

curl -s -u 'admin:password' -X POST '' --data 'FORM_NAME=VALUE'

Many web UIs use cookies and CSRF tokens, so you may need a two‑step request (fetch token, then POST). Storing credentials is a security risk — protect the script and limit access.

If the modem has no programmable reboot, use a hardware watchdog: a smart plug, managed PDU, or a Pi with a relay that power‑cycles the modem after a verified outage. Keep safety in mind: allow 60+ seconds for sync after power‑up, add rate limits (do not cycle repeatedly), secure remote management, and contact the ISP if disconnections are frequent — repeated reboots often indicate line or provisioning issues rather than a permanent fix.

Recommended Answers

All 4 Replies

Member Avatar for Member #579261

SSH or Telnet into the router and then say reload in ... minutes !
the cursor should show Router#

Member Avatar for Member #579261

more info

sorry i am not understanding my problem is that i want to reboot my dsl modem automatically on disconnect..............!! i have zte how can i do that

sorry i am not understanding my problem is that i want to reboot my dsl modem automatically on disconnect..............!! i have zte how can i do that

hi, my question to you is, do you have do it now manually now ,are wanting to do this because you lose your connection from time to time and need to manually reset it .
also what is "zte"lol

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.