safemode IT

Unifi Security Gateway

How to Recover Bricked Unifi USG Security Gateway


We’ve all been there, a phone call comes in, a client is unable to connect to the Internet and they want answers! So what do you do? You check your Unifi Controller and sure enough, their Unifi USG Security Gateway is offline. You go through the standard steps and have the client reboot…wait and reboot again but still, the USG stays offline. <Sigh> Time to roll a truck.

You send your tech on-site, and they check the Unifi USG and see the ring is white and the link lights are not right, regardless of what’s plugged in. Of course, they reboot the device…wait…. and reboot again, but to no avail.

What are you to do? Trash it and replace it? RMA and get a new USG? Well yes, but first you swap the broken one out with one from your inventory and get the customer back online and take the broken one back to your office.
A working Unifi USG

Let’s fix it

A brand-new Unifi USG costs about $129 at Amazon (Update about $300 if you can find one) so a bricked Unifi USG isn’t the end of the world. However, I have a way to recover that bricked unit.‍

Step 1 – Dismantle Bricked Unifi USG

You will need a small Phillips head screwdriver and remove the rubber feet that cover the screws on the bottom of the #Bricked Unifi USG. Once the screws are removed, simply lift the top of the Unifi USG up.
Unifi USG with no rubber feet

Step 2 – Remove USB Drive

Now that the case is opened you will see the small USB drive located on the circuit board.  Simply slide it out. It may require a little force.
Unifi USG with out cover
Once you have the thumb drive removed, go ahead and plug it into your computer. You may get a message that Windows can’t read the drive, and it needs to format it. Just ignore the errors and close them. Please note what the drive letter it’s been assigned.

Step 3 – Download New Image

Here is a link from #Ubiquiti to download the new image. You will need this image to flash to the USB drive. Once you download, unzip the image to a location on your computer. The unzipped file name is USG-4_2_0-shipped.img.Download image from Ubiquiti This firmware version is 4.2 and you will need to upgrade it once installed on the Unifi USG (see step 7)

Step 4 – Download Image Writer

For the purpose of this article, I am using the #Windows version of the image writer. There are of course Linux and MAC OS versions as well.

Install the Win32 Disk Imager and run the application.

Step 5 – Write Image to USB

Select the image file you downloaded and extracted from the previous steps and choose the device as the drive letter the Unifi thumb drive has been assigned. Click Write and wait till it completes the operation. For me it was about 7 minutes. But maybe your computer is faster than mine. Once it completes it may again give you the unable to read the drive error, but again just ignore it and remove the thumb drive.
Image writer for USB drive

Step 6 – Reassemble Unifi USG

Re-insert the USB drive back into the port on the USG circuit board and replace the top of the case and replace the screws. (Rubber feet optional, but recommended)

Step 7 – Connect, Forget, Upgrade, Adopt, Unifi USG

You must forget the Unifi USG from the controller.   Fun Fact: After I forgot the device, I attempted to adopt the USG into the controller but had no success. It may be because the version of my controller 5.10.12, was too new to adopt the outdated version on the Unifi USG. SO, I had to manually upgrade the USG.

All you need to do is SSH into the device and use the default username and password for the Unifi USG, ubnt/ubnt. Then from #CLI type (or cut and paste it into the SSH terminal session. (Please note that there should not be a break between upgrade https://… but that’s how it displays in this post.) upgrade hit enter. The Unfi USG will reboot after about 5 min with the firmware installed and you can now adopt it into the controller.

That’s It

Overall, it took less than 30 minutes to complete, and the bricked Unifi USG was back up and running just fine.

Share this post