Joined: 30 Jan 2015 Posts: 676 Location: Texas, USA
Posted: Fri Jan 19, 2018 16:58 Post subject:
ssh to the router:
nvram erase
nvram commit
reboot _________________ ASUS GT-BE98 PRO Main: Fiber 5gbps up/down
ASUS AXE16000: AI Mesh node
2 X ASUS RT-AX89X: AI Mesh nodes
QNAP QSW-1208-8C 12-Port 10GbE Switch
XS712T ProSafe 12-Port 10GbE Switch
3 X R9000 DD-WRT Mesh
Joined: 26 Jan 2008 Posts: 13049 Location: Behind The Reset Button
Posted: Fri Jan 19, 2018 21:43 Post subject:
labo wrote:
ssh to the router:
nvram erase
nvram commit
reboot
Do NOT issue an nvram commit.
nvram is stored in ram.. When you erase nvram, it clears the flash. Once you do an nvram commit, it writes the nvram that is now in ram (which has not been erased), back to the flash chip.
erase nvram, then reboot.. no commit.
Follow Vaako's instructions.
glad I could help.. _________________ [Moderator Deleted]
nvram is stored in ram.. When you erase nvram, it clears the flash. Once you do an nvram commit, it writes the nvram that is now in ram (which has not been erased), back to the flash chip.
erase nvram, then reboot.. no commit.
Follow Vaako's instructions.
glad I could help..
I second this.
That's completely wrong. The command is
erase nvram && reboot
It will automatically reboot afterwards. _________________ R6400v2 (boardID:30) - Kong 36480 running since 03/09/18 - (AP - DNSMasq - AdBlocking - QoS) R7800 - BS 31924 running since 05/26/17 - (AP - OpenVPN Client - DNSMasq - AdBlocking - QoS) R7000 - BS 30771 running since 12/16/16 - (AP - NAS - FTP - SMB - OpenVPN Server - Transmission - DDNS - DNSMasq - AdBlocking - QoS) R6250 - BS 29193 running since 03/20/16 - (AP - NAS - FTP - SMB - DNSMasq - AdBlocking)
Joined: 26 Jan 2008 Posts: 13049 Location: Behind The Reset Button
Posted: Sun Jan 21, 2018 16:43 Post subject:
Xeon2k8 wrote:
barryware wrote:
ssh to the router:
nvram erase
nvram commit
reboot
Do NOT issue an nvram commit.
nvram is stored in ram.. When you erase nvram, it clears the flash. Once you do an nvram commit, it writes the nvram that is now in ram (which has not been erased), back to the flash chip.
erase nvram, then reboot.. no commit.
Follow Vaako's instructions.
glad I could help..
I re-read my post.. It is not wrong but I can see where it could be misinterpreted.
Nvram is on the flash chip.. It gets read and moved to ram when the router boots.
Just like your PC "shadowing" the bios and cmos. The PC bios is stored on a flash chip but when the PC boots, it is read and moved to ram. Then the PC uses the ram to fetch instructions and settings, not the bios chip.
So.. when you erase nvram in your router, it does just that.. Erases the nvram partition on the flash chip.. However at this point, all your settings are still in ram.
When you "commit", you are writing the settings that are still in ram to the flash chip so except for a few settings that may not be in ram, you are writing everything back to the flash.
Think about the "save" command in the gui, then the "apply" command.
Save writes to the nvram partition, apply reads and initializes the parameter.. Depending on what setting you save, when you hit apply, the router may completely reboot.
You can easily test this..
Traff Data.. If you reboot your router before traff data is written to flash (nvram), todays traff data is gone.
If you do a commit before you reboot, once rebooted todays traff data is present.
Traff Data gets written everyday around midnight so if you reboot lets say at noon without committing, 12 hours of traff data will be missing. _________________ [Moderator Deleted]
Posted: Tue Jan 22, 2019 8:25 Post subject: CLI via putty
Hello, I'm extremely novice at this and am wondering when you say "SSH to router", how do you do this? Specifically, I don't know what the Host Name or IP address should be when I open a session in putty.
That's a different topic. You can find that anywhere on the Internet. _________________ R6400v2 (boardID:30) - Kong 36480 running since 03/09/18 - (AP - DNSMasq - AdBlocking - QoS) R7800 - BS 31924 running since 05/26/17 - (AP - OpenVPN Client - DNSMasq - AdBlocking - QoS) R7000 - BS 30771 running since 12/16/16 - (AP - NAS - FTP - SMB - OpenVPN Server - Transmission - DDNS - DNSMasq - AdBlocking - QoS) R6250 - BS 29193 running since 03/20/16 - (AP - NAS - FTP - SMB - DNSMasq - AdBlocking)
just to give a notice the new command on the recent builds is reverted to
nvram erase
reboot
Ah thanks m8, I lost track of when they were going to do the change _________________ R6400v2 (boardID:30) - Kong 36480 running since 03/09/18 - (AP - DNSMasq - AdBlocking - QoS) R7800 - BS 31924 running since 05/26/17 - (AP - OpenVPN Client - DNSMasq - AdBlocking - QoS) R7000 - BS 30771 running since 12/16/16 - (AP - NAS - FTP - SMB - OpenVPN Server - Transmission - DDNS - DNSMasq - AdBlocking - QoS) R6250 - BS 29193 running since 03/20/16 - (AP - NAS - FTP - SMB - DNSMasq - AdBlocking)
Or you can follow your router's instructions if you have physical access to the unit, e.g. on a Asus RT-AC68U (and I'm sure other Asus models) you can hold down WPS button while powering the router and it will wipe NVRAM. There are other hardware shortcuts like that, e.g. hold Reset button while powering on and then you can connect to it with a browser to a recovery web server which has a Clear NVRAM link and also lets you upload a firmware file.
But yes, from the command line (ssh or telnet) "nvram erase && reboot" sounds right.
well yep if you want to be entirely sure you can fairly issue:
erase nvram && nvram erase && reboot
recently somewhere Kong stated that erase nvram still
erases the memory but not the actual nvram and the new command for it is
nvram erase
Did you at least look at the first link I just posted??
If you did....read it again....that really is not what he said
It may also be seen as foolish to advice someone to issue multiple commands, that you are uncertain of their resaults or what they are doing¯\_(ツ)_/¯ _________________ Location 1
R7800- DD-WRT v3.0-r53562 (10/03/23) Gateway
WNDR3400v1 DD-WRT v3.0-r35531_mega-nv64k (03/26/18 ) Access Point
WRT160Nv3 DD-WRT ?v3?.0-r35531 mini (03/26/18 ) Access Point
WRT54GSv5 DD-WRT v24-r33555_micro_generic (10/20/17) Repeater
Location 2
R7800- DD-WRT v3.0-r51855 (02/25/23) Gateway
R6300v2- DD-WRT v3.0-r50671 (10-26-22) Access Point
WNDR3700v2 DD-WRT v3.0-r35531 std (03/26/18 ) Access Point
E1200 v2 DD-WRT v3.0-r35531 mega-nv64k (03/26/18 ) Gateway(for trivial reasons)
RBWAPG-5HACT2HND-BE RouterOS-v6.46.4 (2/21/20) Outdoor Access Point
2x RBSXTG-5HPACD RouterOS-v6.46.4 (2/21/20) PTP Bridge 866.6Mbps-1GbpsLAN
Location 3
2x R7000- DD-WRT v3.0-r50671 (10/26/22) Access Points
2x RBWAPG-60AD RouterOS-v6.45.9 (04/30/20) PTP Bridge 2.3Gbps-1GbpsLAN
2x RBSXTsqG-5acD RouterOS-v6.49.7 (10/14/22) PTP Bridge 866.6Mbps-1GbpsLAN Thank You BrainSlayer for ALL that you do & have done, also to "most" everyone here that shares their knowledge