Cisco Nexus 5000/6000 Password Recovery¶
Complete procedure for recovering the admin password on Cisco Nexus 5000 and 6000 series switches.
Prerequisites¶
| Item | Details |
|---|---|
| Console Cable | DB9 serial console cable (USB console will NOT work) |
| Terminal Software | PuTTY, TeraTerm, or similar |
| Console Settings | 9600 baud, 8 data bits, 1 stop bit, no parity |
| Keyboard Layout | EN-US recommended (for break sequence) |
USB Console Not Supported
Password recovery requires a DB9 serial console connection. USB console cables will not work for the break sequence.
Break Sequence Reference¶
| Keyboard | Break Sequence | Notes |
|---|---|---|
| US English | Ctrl+] | Hold Ctrl, press ] |
| German (US layout) | Ctrl++ | Strg + the + * ~ key |
| German (native) | ++ctrl+alt-gr+9++ | Works through Opengear |
| Older NX-OS (4.0) | Ctrl+B | Ctrl+Shift+B on some |
Password Recovery Procedure¶
Part 1: Access Boot Mode¶
- Connect console cable to the switch's DB9 serial port
- Open terminal session with settings:
9600-8-N-1 - Power on (or power cycle) the switch
- Watch for the boot sequence messages
- When you see:
Checking all filesystems....r. done. - Immediately press the break sequence (Ctrl+])
- You should see the
switch(boot)#prompt
Timing is Critical
The break sequence window is short. Press it as soon as you see "Checking all filesystems" - don't wait for it to complete.
Part 2: Reset Admin Password¶
# Enter configuration mode
switch(boot)# configure terminal
# Set new admin password
switch(boot-config)# admin-password YourNewPassword123
# Exit configuration mode
switch(boot-config)# exit
Part 3: Boot the System¶
# List available images
switch(boot)# dir bootflash:
# Boot the system image (example filename)
switch(boot)# load bootflash:n5000-uk9.5.1.3.N2.1b.bin
Part 4: Verify and Save¶
# Login with new credentials
Username: admin
Password: YourNewPassword123
# Verify you're logged in
switch# show users
# Save the configuration
switch# copy running-config startup-config
Optional: Factory Reset¶
If you want to completely reset the switch after password recovery:
# Erase all configuration
switch# write erase
# Reload the switch
switch# reload
# After reboot, save clean config
switch# copy running-config startup-config
Quick Reference Commands¶
| Command | Purpose |
|---|---|
dir bootflash: |
List boot images |
load bootflash:<image> |
Boot specific image |
admin-password <pass> |
Set admin password (boot mode only) |
show version |
Display NX-OS version |
show users |
Show logged-in users |
write erase |
Erase startup configuration |
copy run start |
Save running config |
Troubleshooting¶
Break Sequence Not Working¶
- Verify using DB9 serial port, not USB console
- Try different break sequences (see table above)
- Check terminal settings are exactly
9600-8-N-1 - Ensure EN-US keyboard layout is active
- Try pressing break sequence repeatedly during boot
Cannot Find Boot Image¶
# List all files in bootflash
switch(boot)# dir bootflash:
# If empty, check USB
switch(boot)# dir usb1:
switch(boot)# dir usb2:
Password Still Not Working After Reset¶
- Password recovery only updates the local user database
- Remote AAA authentication will still use old credentials
- Ensure local authentication is enabled:
switch# show aaa authentication
SNMP Community String¶
After password recovery, update SNMP if needed:
switch# configure terminal
switch(config)# snmp-server community <string> ro
Important Notes¶
Service Disruption
Password recovery requires a reboot. Schedule a maintenance window as all traffic will be disrupted.
Local Authentication Only
The recovered password only works for local authentication. Remote AAA servers retain their original credentials.