Recovery of lost configuration

Created by Yuriy Andamasov, Modified on Wed, 26 Apr, 2023 at 11:09 AM by Aslan Hajiyev

Scenario : If in case the device is stuck in booting process or unable to access via ssh and there is no configuration backup, then follow the below instructions to recover the lost configuration:

  1. When you will see the boot menu with the version chosen, you need to enter the "e" key. After this, you will see the commands list that executes to boot the system.
  2. You should go to the line that starts from "linux" and ends with "console=XXX". Add "init=/usr/bin/busybox init" to the end of this line, so it will looks: "linux [skipped part of the command that may vary] console=XXX init=/usr/bin/busybox init"
  3. Press F10 and wait till the system start. You should see:  root@(none):/#
    Please press Enter to activate this console.
  4. The configuration file will be available in the regular place. You can see it with cat /config/config.boot.
  5. If you need to copy the file to another machine, you can set up an IP address and use scp to upload it elsewhere. For example:
    ip a add 192.168.122.5/24 dev eth0

    ip link set eth0 up

    scp /config/config.boot [email protected]:/tmp/
  6. Reboot the router if necessary to a normal mode: "reboot -f".

Note: While connecting the device to the serial port for console access, make sure to set to proper settings.

The most common serial configuration is:

Baud rate: 9600 or 115200
Data bits: 8
Stop bits: 1
Parity: None
Flow control: None

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article