Password recovery for XRE200 has been broken since 12.3R1. In problematic JUNOS version, JUNOS will request root password during the password recovery process.
This article provides a workaround to recover the system and the affected or fixed JUNOS version information.
(snip)
Enter root password, or ^D to go multi-user Password: <--- here Enter full pathname of shell or 'recovery' for root password recovery or RETURN for /bin/sh: recovery Performing filesystem consistency checks ...
Workaround Solution
If an affected JUNOS version is being used, the issue can be avoided with the following steps:
For both primary/backup XRE,
(1) Remove the softlink "/etc/ttys" (2) Copy "/var/etcroot/ttys" to "/etc/ttys" (Primary) root@8200VC:RE:8% cd /etc root@8200VC:RE:8% ls -al tty* lrwxrwxrwx 1 root wheel 17 Apr 20 16:57 ttys -> /var/etcroot/ttys lrwxr-xr-x 1 root wheel 32 Apr 20 16:57 ttys.sys -> /packages/mnt/jbase/etc/ttys.sys root@8200VC:RE:8% rm ttys root@8200VC:RE:8% cp /var/etcroot/ttys /etc/ttys root@8200VC:RE:8% ls -al ttys -rw-r--r-- 1 root wheel 7586 Jun 26 14:52 ttys
root@8200VC:RE:8% cd /etc root@8200VC:RE:8% ls -al tty* lrwxrwxrwx 1 root wheel 17 Apr 20 16:57 ttys -> /var/etcroot/ttys lrwxr-xr-x 1 root wheel 32 Apr 20 16:57 ttys.sys -> /packages/mnt/jbase/etc/ttys.sys root@8200VC:RE:8% rm ttys root@8200VC:RE:8% cp /var/etcroot/ttys /etc/ttys root@8200VC:RE:8% ls -al ttys -rw-r--r-- 1 root wheel 7586 Jun 26 14:52 ttys
(Backup) root@8200VC:RE:9% cd /etc root@8200VC:RE:9% ls -al tty* lrwxrwxrwx 1 root wheel 17 Apr 20 16:57 ttys -> /var/etcroot/ttys lrwxr-xr-x 1 root wheel 32 Apr 20 16:57 ttys.sys -> /packages/mnt/jbase/etc/ttys.sys root@8200VC:RE:9% rm ttys root@8200VC:RE:9% cp /var/etcroot/ttys /etc/ttys root@8200VC:RE:9% ls -al ttys -rw-r--r-- 1 root wheel 7586 Jun 26 14:52 ttys
root@8200VC:RE:9% cd /etc root@8200VC:RE:9% ls -al tty* lrwxrwxrwx 1 root wheel 17 Apr 20 16:57 ttys -> /var/etcroot/ttys lrwxr-xr-x 1 root wheel 32 Apr 20 16:57 ttys.sys -> /packages/mnt/jbase/etc/ttys.sys root@8200VC:RE:9% rm ttys root@8200VC:RE:9% cp /var/etcroot/ttys /etc/ttys root@8200VC:RE:9% ls -al ttys -rw-r--r-- 1 root wheel 7586 Jun 26 14:52 ttys
Recover system access (cannot recover configuation itself)
If an affected JUNOS version is being used, but the above workaround solution has not been applied. There is no way to recover the password. Instead, you can still recover the system access by selecting 'FACTORY DEFAULT' from the LCD panel. In this case, the configuration will be erased and cannot be recovered.
(1) Move to "MAINTENANCE MENU" using "Up" or "Down" button and select it pushing "Enter" button (2) Move to "FACTORY DEFAULT" using "Up" or "Down" button and say "yes" pushing "Enter" button (3) You will see "RESOTRE DEFAULT" here and say "yes" pushing "Enter" button Notice: In case of XRE200, USB reinstall only copies the JUNOS image into internal CF memory. Recovery install from CF memory does not erase configuration. So, 'FACTORY DEFAULT' from LCD panel button is the only the way to get access back.
Affected JUNOS version & JUNOS version with Permanent Fix
This issue has been introduced since 12.3R1 and fixed in 12.3R12-S10, 15.1R7-S2, 15.1R8 or later.
2021-03-25: Updated the article terminology to align with Juniper's Inclusion & Diversity initiatives.