Fixing myself some redundancy

I’ve never been a network technician and with any luck I never will be either. However a certain opportunity presented itself to me lately. I’ve recently upgraded my switches at home to managed switches which enables some proper shenanigans.

I’ve been lucky enough to buy a terraced house with two separate internet providers wired in. First we have a cable based ISP which provides 100mbit download and 10mbit upload. This is far too slow for my liking but it has a distinct advantage. It’s included in my fee to the housing society. The second provider is a standard cat6 connection which provides 1000mbit in both directions. Naturally since I’ve moved in this is what i have been using, the downside is that it does cost me 30euros/month.

So how does this relate to the managed switches? Well you see.. as is often the case with cable(coax) provided internet, it’s never located conveniently close to your servers. It is however often located conveniently close to your TV. Where as my cat6 provider has its jack located near the front door. I’ve already pulled an Ethernet cable to my TV box from my switch located elsewhere. So the Ethernet run to the inconvenient coax provider was already sort of there. Pulling an extra Ethernet from the TV back to my router was both inconvenient and politically sensitive in my household. The only viable solution was to call upon the power of friendship, magic and VLANs.

The first step was to create a new VLAN i my switches. I’m using rather cheap somewhat crappy zyxel managed switches. They use a somewhat different terminology to big players such as Cisco and Ubiquiti. However the end result is the same.

after creating the vlan on both of my switches i trunked the vlan on the port connecting the switches. In Zyxel terms this is called “tagging egress member” in my case for port 3 in the switch:

in the above image the coax internet is running on VLAN ID 3.
Since my coax internet provider only provides a basic DOCSIS cable modem, which has no clue what a VLAN is. The configuration for that port was set to untagged and the PVID of the port was set to 3

This means the cable modem only ever knows about vlan 3 and it has no clue about anything else.
in the other switch located next to my Ubiquiti router i configured a port in the exact same way. No need to get fancy unless we have to, right?

In the router, i plugged in a cable to my new fancy VLAN 3 port, and just added a “WAN”, told it which port to use as new WAN and I was off to the races.

The end result:

So now, whenever i lose 2 ping packets on my primary connection it will automatically fail-over to the coax provider.