Network and uplinks → VLANs

An 802.1Q VLAN splits one physical connection into several separate networks, each with its own addressing and its own zone. The sub-interface is named…

What it is for

An 802.1Q VLAN splits one physical connection into several separate networks, each with its own addressing and its own zone. The sub-interface is named after the card followed by a dot and the ID: VLAN 20 on eth1 is eth1.20. Routes, gateways, QoS and PPPoE links can use it like any other interface.

For John Smith Ltd:

VLAN Address Zone
eth1.20 (guests) 192.168.20.1/24 GUESTS
eth1.30 (production) 10.30.0.1/24 PRODUCTION

The switch behind eth1 must carry the same tagged VLANs on the port towards the appliance. The scenario A separate guest network on a VLAN shows the complete path, zone included.

How the page is laid out

The list shows each VLAN with its name, the address (or “DHCP”, or “Manual (no address)”), the zone and the kernel’s state (up, down…). The list’s bar holds “Reload” and “Add VLAN”; the detail of a VLAN, “Delete VLAN”.

VLANs: the detail of the guest VLANVLANs: the detail of the guest VLAN
VLANs: the detail of the guest VLAN

The fields

For a new VLAN only:

  • “Parent interface” — the physical card the VLAN runs over.
  • “VLAN id” — from 1 to 4094. The hint gives the name that results (“parent.id”, for example eth0.100).

Parent card and ID cannot be changed after creation: to move a VLAN, create a new one and delete the old one.

Then, as for a card: “Method” (“Static”, the default for a new VLAN, “DHCP” or “Manual (no address)”), “Zone”, “Address (CIDR)” and “Additional addresses”, with the same rules seen in Interfaces.

Saving

“Create VLAN” or “Save VLAN” rewrites the VLAN’s stanza and restarts networking (if the file changed or a managed interface is not up), without a further question: the “Effect of saving” box says so: “Updates the network immediately. The connection to this console may be interrupted.”. When the work is done “VLAN applied” appears. The zone goes into the configuration at once and into the firewall rules with “Apply”. If instead you save from the unsaved-changes window, when you leave the page, the console first asks for the same confirmation as for the cards (“Saving rewrites /etc/network/interfaces…”), to be confirmed with “Save”.

Deleting a VLAN

“Delete VLAN” asks “Delete VLAN eth1.20? Its address is removed and it leaves its zone.”. Argos takes the VLAN down, removes its stanza from the file, restarts the network if needed and finally removes the device from the kernel: the VLAN does not linger with its address until the next reboot.

A VLAN still in use cannot be deleted. The message is “Applying the VLAN failed — still referenced by a route, a gateway, a shaping rule or a PPPoE link”: first delete the route, the gateway, the QoS rule or the PPPoE link that use it.

Deletion also goes through the lockout protection: the VLAN leaves its zone at once, so if you are using the console through that VLAN the deletion is refused with “Applying the VLAN failed — You would lose the console on the interface you are using: do this from another zone, or with argos-cli”.

Messages

Message What it means
“Choose a valid parent interface” The parent card does not exist.
“VLAN id must be 1-4094” ID out of range.
“A VLAN with this id already exists on the parent” That VLAN is already there.
“Not a valid CIDR (e.g. 192.168.100.1/24)”, “An additional address overlaps…”, “Two additional addresses overlap…” As in Interfaces.
“This network overlaps an enabled VPN profile’s networks” As in Interfaces.
“A gateway takes its address from this VLAN’s DHCP lease…” The VLAN has a gateway that uses the lease’s router: first type an address in the gateway.
“This VLAN has a gateway: it is the WAN side and cannot be in the LAN…” The VLAN carries a gateway: delete the gateway first, or put another interface in the LAN.
“You would lose the console on the interface you are using…” The new zone, or the deletion, would take the console away from you on the VLAN you work from.
“Zone not found” Reload the page.

For the technician The VLANs are vlan-raw-device <parent> stanzas in the # --- argos managed vlans --- section of /etc/network/interfaces. As for the cards, a hand-written VLAN nobody edits keeps its options (mtu, its own hooks); once rewritten by Argos, it is Argos’s. The deletion runs ifdown eth1.20 while the stanza is still in the file, removes it, restarts the network and ends with ip link del dev eth1.20 if the device is still there (an ifdown -a does not touch an interface the file no longer has).

LET’S TALK INFRASTRUCTURE

Control starts with a conversation.

Tell us about your infrastructure. Let’s start with what you actually need.

Talk to an engineer