nikdoof.com

/posts/ 2023/adopting-a-usw-mini

Adopting a Ubiquiti USW-Mini via DHCP

Mar 4, 2023

#unifi#homelab#ubiquiti#hardware

The USW Mini is a tiny, 5 port, PoE or USB-C powered switch from Ubiquiti. As part of my homelab reorganization, I picked two up to serve as small spur switches for the downstairs media hub and my office desk. The problem is that, unlike the rest of Ubiquiti’s switching range, these devices are relatively dumb and can be a bit of a pain to get adopted into the Unifi console if you have anything unusual on your network.

In my case, my controller is a pod on my Kubernetes cluster and doesn’t have much of a Layer 2 presence on the network. The USW Mini depends on the L2 features of the controller to enable adoption, but with a little bit of work, you can get them added. The switches support using DHCP to gather their configuration information, but information on how to configure this outside of Ubiquiti’s gateway devices is difficult to find. First of all, they make use of DHCP Option 43, and the value in this option should be an encoded version of your controller’s IP. I use pfSense as my DHCP server, so here is what I did:

Now, you can restart your USW-Mini, and it should appear as adoptable in the controller interface.