Skip to content

Instantly share code, notes, and snippets.

@robbkidd
Created June 8, 2024 20:18
Show Gist options
  • Save robbkidd/2c131e5e290606ce9602d16e7327e90c to your computer and use it in GitHub Desktop.
Save robbkidd/2c131e5e290606ce9602d16e7327e90c to your computer and use it in GitHub Desktop.
So, you're upgrading a UniFi gateway and you have fiddled with the Default VLAN1 network ...

UniFi Gateways (not the Cloudy type that have a Network controller baked in) really want to be brought into the collective from the 192.168.1.x subnet. But maybe you've tinkered with the Default untagged VLAN1 network because 192.168.1.x is sooo pedestrian. Maybe you prefer the business-like attitude of 10.x.x.x, or the hipster vibes of 172.23.42.x. Whatever your reasons, here's what help I can offer when the time comes to change out your gateway.

Pre-requisites

  • Prepare yourself (and your family/housemates) emotionally and spiritually for network fuckery.
  • Work from a wired host.
  • If at all possible, dual-home your UniFi Network app for its current subnet and for 192.168.1.x.
    • Thankfully (maybe?) mine runs in a container on a NAS that has two NICs and I hadn't done anything yet with the second one.
    • I have no idea what an official Cloudkey is capable of and can offer no advice there.
    • Update the Unifi Inform Host setting to the 192.168.1.x address given to the Network app.

Rough steps

  • Accept your fate at the hands of Ubiquiti and configure Default/VLAN1 back to 192.168.1.0/24.
  • Add a new network for the subnet range you used to have on VLAN1.
    • I'll call this one Home.
  • "Trunks": ensure switch ports downlinking to other switches and wireless access points are set for:
    • Native VLAN: Default
    • Tagged VLAN: Allow all (or be specific if you know what you're doing)
  • WiFi: running an SSID specific for the Home subnet?
    • Change the associated network for that SSID from Default to Home.
  • Wired: any hosts wired for the Home subnet?
    • Any without a VLAN tag on the host's NIC?
      • If you don't know what this means, the answer is "yes."
    • For each port a Home host is connected to, update the native VLAN from Default to Home.
  • Does your network now still work roughly as before?
    • Continue on to ...

Adoption

  • Your UniFi gear should be talking amongst themselves on 192.168.1.x at this point.
  • Power up your new UniFi gateway.
  • Unplug the network cables from the old gateway and plug them into the equivalent on the new gateway.
  • In the Network controller app looking at this site, the old gateway should appear offline and a new gateway should appear as available for adoption.
  • Remove the old gateway from the site.
  • Adopt the new gateway.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment