Ubiquiti Cloud Key G2 Upgrade firmware via SSH

Just a quick post today to show you how update the firmware on your Ubiquiti Cloud Key G2 via SSH. I recently had to do this after an update created the dreaded "UniFi is having trouble with this direction..." within the web GUI so I needed to downgrade the firmware to make it functional again.

In my case we upgrade to the latest firmware 2.1.11 from 2.0.27. Why this happened I'm unsure as are alot of disgruntled Ubiquiti admins and you can read about that here... Before starting any of the following procedure, ensure you have a current backup of your device download to your PC in case something goes wrong.

I thought the downgrade process would be similar to when you downgrade an AP with the really simple SSH command:

upgrade https://fw-download.ubnt.com/data/unifi-cloudkey/4724-UCKG2-2.1.7-11ca020dba684770b2ebe6a832cb9911.bin

You just copy the URL above from the Ubiquiti download site and you're done. Very well implemented firmware update procedure that works for both upgrades and downgrades.

Sadly to update the firmware via SSH on a Cloud Key is slightly different and for that I'll outline the procedure below:

First, go the Ubiquiti download site here... and find the firmware you wish to upgrade or downgrade to and click the download link and select "Copy URL" from the pop screen like the following example:

Now open Putty of your preferred SSH client and connect to your Cloud Key and type the following command:

ubnt-systool fwupdate <URL>

Replace <URL> in the example above by pasting the copied URL from the previous step so your syntax should look like the example below:

ubnt-systool fwupdate https://fw-download.ubnt.com/data/unifi-cloudkey/e9cc-UCKG2-2.1.11-1cf4bd8262b64919ac100cc5b69dc0b1.bin

The device will automatically reboot once the firmware update procedure is complete. Sadly, this didn't rectify my problem and in actual fact, made the situation worse because the web GUI wouldn't come up at all now.

I decide to reset the device to factory defaults and you can do the by logging onto the device via SSH and executing the following command:

ubnt-systool reset2defaults

The device will reboot and you will need to go through the initial setup procedure when you access the web GUI. You can log on and configure your device and then restore from your backup that you created earlier.

If you've found this useful, you may want to sign up to our newsletter where you'll receive notices on when we post new articles and helpful "how tos". Just fill out your details below and we'll do the rest…

1 Response

  1. You are a life saver.

Leave a comment


Sign up to our newsletter where you’ll receive notices on when we post new articles and helpful “how tos” to make your IT life easier.