Ubiquiti devices SSH cheatsheet
Most Ubiquiti access points need a controller to be managed (Unifi), but there are certain scenarios when we need to access the device via SSH to perform various actions, most of them I will explain here.
Take in consideration that when a device has been adopted once with a controller, th SSH acces must be enabled on that controller settings and the username and password is set and dependant on such controller, all of the devices adopted will have the same credentials. Is the device is brand new or has been reset to default configuration the credentials use to be:
- UniFi Gateways - root / ubnt
- UniFi Consoles - root / ubnt
- UniFi Devices - ubnt / ubnt
Essential SSH Commands
Basic Information
info
Displays device details including:
- Operating mode
- Firmware version
- MAC address
- IP address
- Hostname
- Uptime
- Status
- Inform address
Controller Association
set-inform http://URL-OF-CONTROLLER:8080/inform
Points the device to a specific controller for adoption. Note: This command typically needs to be executed twice unless you have a DNS entry for UniFi that resolves to your controller's IP address.
Factory Reset
syswrapper.sh restore-default
Restores the device to factory default settings.
Firmware Updates
Method 1: Offline Update
For devices without internet access:
- Download firmware from UI.com Download Page
- Copy the firmware file to
/tmp/
on the device via SSH - Rename the
.bin
file tofwupdate.bin
- Execute the update:
cd /tmp/
syswrapper.sh upgrade2 &
The device will automatically reboot after the update.
Method 2: Online Update
For devices with internet access:
- SSH into the device
- Run the upgrade command with the direct firmware URL:
upgrade https://dl.ui.com/unifi/firmware/[DEVICE-SPECIFIC-PATH]/[FIRMWARE-FILE].bin
Additional Resources
For more detailed information about UniFi device management:
Note: Always ensure you're using the correct firmware version for your specific device model.