Firmware upgrade via command line
Upgrading the router's firmware via command line can be beneficial when:
- Updating from versions older than RUT2XX_R_00.00.348 or RUT9XX_R_00.04.75 to newer versions in order to keep settings
- You've lost access to the router via HTTP or HTTPS
- Upgrading firmware remotely
- You will need a firmware file. You can download firmwares from our wiki, from one of the following links:
- You will need access to the router via some form of command line. Access to command line interfaces (CLIs) supported by RUTxxx routers are described in this article:
Uploading the firmware file to the router
Before you can initiate the upgrade, you must first upload the firmware file into the router's RAM memory, because the flash memory is too small to store it. Files uploaded to the /tmp/ directory are stored in the RAM memory, so that's where you'll need to upload the file. There are three ways to accomplish this:
Via the router's WebUI
If you have access to the router's WebUI, simply login, navigate to System → Firmware, select "Upgrade from file" and click the "Upgrade" button. This will upload the firmware file to the /tmp/ directory and change its name to firmware.img.
Using WinSCP (Windows)
If you are using a Windows computer, you can use WinSCP to upload files to the router. Download WinSCP from here, launch it, select SCP as the File protocol and login to the router (the login process is basically the same as when using PuTTY). Then locate the tmp directory and drag the firmware file inside it (just like you copy/move any other file using Windows).
Using scp (Linux)
Use the scp command to copy the firmware file via SSH. Open up a Terminal in the directory where the file is located (right-click any blank space in the directory and select "Open in Terminal"). Then enter the following command:
scp RUT9XX_R_00.05.00.5_WEBUI.bin email@example.com:/tmp/
- RUT9XX_R_00.05.00.5_WEBUI.bin is the firmware file's name. Replace it with your firmware's name.
- 192.168.1.1 is the router's IP address. Replace with your own router's IP.
- /tmp/ is the directory where the file will be copied to.
NOTE: files are removed from the /tmp/ directory after a reboot. If you rebooted the router, you'll need to upload the firmware file again.
Upgrading the firmware
To upgrade the firmware, login to the router and execute the following command:
- sysupgrade is the command used to upgrade the router's firmware.
- RUT9XX_R_00.05.00.5_WEBUI.bin is the firmware file's name. Replace the firmware file's name that you are using. If you uploaded the firmware via WebUI, the name will automatically be changed to firmware.img regardless of what firmware version you use.
- Other guides concerning system upgrades:
- https://winscp.net/eng/download.php - WinSCP download