My home network used to be one flat network. My server, my laptop, my phone and every device my parents own all sat on the same subnet behind the ISP modem, and any of them could talk to any other.
That's fine until something on it goes wrong. My server runs services that are reachable from the internet, so I wanted it in a box of its own: it can reach the internet, but it can't start a connection to anything else in the house. I also wanted my parents' Wi-Fi kept separate from my own devices and from the lab.
So I rebuilt the network around VLANs: four separate networks on one router and one switch, with a firewall deciding what can talk to what. This post walks through the hardware, the design and the configuration.
| Role | Device |
|---|---|
| Router and firewall | GL.iNet Brume 3 (GL-MT5000) |
| Managed switch (L2) | FS S3220-5M |
| Server | Lenovo ThinkCentre M70q |
| My Wi-Fi | TP-Link Deco AX3000, 2-pack |
| My parents' Wi-Fi | Optus Ultra WiFi Modem Gen 2 |
The Brume 3 does the routing, DHCP and firewall for the whole house, and its WAN port connects straight to the NBN FTTP connection. The FS switch splits the VLANs out onto separate ports. Both Wi-Fi systems sit behind them as access points, each on its own VLAN.
The whole network: one trunk, three access ports
There are four networks, each with its own subnet:
| VLAN | Name | Subnet | What's on it |
|---|---|---|---|
| 1 | Default | 192.168.8.0/24 | The Brume's default LAN |
| 20 | SERVER | 192.168.20.0/24 | Lenovo ThinkCentre M70q |
| 30 | TRUSTED | 192.168.30.0/24 | My devices, through the Deco Wi-Fi |
| 40 | PARENT | 192.168.40.0/24 | My parents' devices, through the Optus modem |
The idea is simple: a single cable runs from the router to the switch and carries all four networks at once. The switch then gives each device a port that belongs to one network only. Every packet that crosses from one VLAN to another has to go up that cable to the Brume, and that's where the firewall gets its say.
NBN FTTP ──► Brume 3 WAN
└─ LAN1 ── trunk (1, 20, 30, 40) ──► FS S3220-5M port 1
├─ port 2 VLAN 20 SERVER → ThinkCentre M70q
├─ port 3 VLAN 30 TRUSTED → Deco AX3000
└─ port 4 VLAN 40 PARENT → Optus modemOn the Brume, each VLAN is created on the LAN1 port and gets its own interface, subnet and DHCP server. LAN1 is the trunk to the switch, so it carries all four.
The four VLANs on the Brume's LAN1 port
Each VLAN gets its own interface and gateway address
The FS S3220-5M is a layer 2 switch: it doesn't route, it only keeps the VLANs apart and passes them to the right ports. Each port has a mode.
Port 1 carries every VLAN; ports 2–4 each carry one
| Port | Mode | VLAN | Connected to |
|---|---|---|---|
| 1 | Trunk (hybrid) | 1, 20, 30, 40 tagged | Brume 3 LAN1 |
| 2 | Access | 20 | Lenovo ThinkCentre M70q |
| 3 | Access | 30 | TP-Link Deco AX3000 |
| 4 | Access | 40 | Optus Ultra WiFi Modem Gen 2 |
Because the Deco is plugged into a VLAN 30 port, everything that joins its Wi-Fi lands on 192.168.30.0/24 without any VLAN setting on the Deco itself. The same goes for the Optus modem and VLAN 40.
Port VLAN settings on the FS S3220-5M
VLANs keep the networks apart at layer 2, but the Brume routes between them, so the firewall decides what's actually allowed. I started from "nothing talks to anything" and added only what I need:
| From | To | Allowed |
|---|---|---|
| SERVER | Internet | Yes |
| TRUSTED | Internet | Yes |
| PARENT | Internet | Yes |
| TRUSTED | SERVER | SSH only (TCP 22 to the ThinkCentre) |
| TRUSTED | VLAN 1 and the Brume | Yes, to manage the switch and the router |
| SERVER, PARENT | The Brume itself | DHCP and DNS only |
| Anything else between VLANs | No |
Everything that isn't allowed here is blocked
The firewall is stateful, which is what makes the SSH rule work. My laptop on TRUSTED can open an SSH session to the server, and the server's replies are allowed back because they belong to a connection my laptop started. The server itself still can't start a connection to my laptop, to my parents' devices or to anything else in the house.
Forwarding only covers traffic between networks. Traffic to the Brume itself is a separate setting, Input. SERVER and PARENT have it set to reject, with two exceptions each: DHCP, so devices still get an address, and DNS, so names still resolve. So the server can't reach the router's admin page or its SSH either.
Zones: who forwards where, and who can talk to the router
Traffic rules: SSH to the server, plus DHCP and DNS
This build made the layers concrete. VLANs live at layer 2: the switch keeps them apart by adding an 802.1Q tag to each Ethernet frame, and the devices on access ports never see it. IP lives at layer 3: each VLAN is its own /24 subnet with its own gateway on the Brume, and getting from one subnet to another means routing, which is exactly where the firewall sits.
It also made me learn which protocol and port each service really uses, because every firewall rule asks for both:
| Service | Protocol | Port | What it's for |
|---|---|---|---|
| DHCP | UDP | 67 (server), 68 (client) | Getting an IP address |
| DNS | UDP, and TCP for large answers | 53 | Turning names into addresses |
| SSH | TCP | 22 | Logging in to the server |
DHCP has to be UDP. A device asking for an address doesn't have one yet, so it can't open a TCP connection; it broadcasts a request and waits for a reply. That's why the DHCP rules are UDP only, while the DNS rules allow both.
Forward and Input are different settings. Forward covers traffic passing through the router from one zone to another. Input covers traffic to the router itself. I had forwarding locked down, but Input was still set to accept on SERVER and PARENT, so the server could reach the Brume's admin page and its SSH.
Deny by default, then add exceptions. I set Input to reject on those zones and added back exactly what they need: DHCP and DNS, nothing else. The SSH rule is just as narrow: one source zone, one destination IP, one port.
Stateful means one rule per direction you care about. I only allow TRUSTED to start a connection to the server. The replies come back automatically because they belong to a connection my laptop started, so the server can answer an SSH session without being allowed to open connections of its own.
Reject inside, drop at the edge. The internal zones reject blocked traffic, so a mistake fails straight away with "connection refused" instead of hanging. The WAN zone drops it, so the internet gets no answer at all.
To get ready for a NAS later, I upgraded the server from its onboard 1 Gb Ethernet to a 2.5 Gb network card. At first everything looked right: the switch linked at 2.5 Gb, it learned the server's MAC address, and the server got its IP address from the Brume.
But the connection barely worked. A ping got one or two replies, then nothing but timeouts. SSH took a long time to connect, and once I was in, I'd wait ages for a single typed character to appear before the session dropped.
I worked through it one step at a time:
So the card worked, and the switch was fine with the rest of the network; the problem was the two of them together. The card used a Realtek chip, so I replaced it with one using an Intel chip, which works with a wider range of devices. Back on the FS switch, the connection was normal.
Next: Home Lab part 2: The server set-up covers what runs on the ThinkCentre: Ubuntu, Docker, Cloudflare Tunnel and Traefik.