[solved] VLAN strangeness using systemd-networkd on aarch64

This forum is for discussion about general software issues.

[solved] VLAN strangeness using systemd-networkd on aarch64

Postby Klepto » Wed Feb 23, 2022 8:54 am

Solution:

My bad. I had some over aggressive module hardening in play. Arch Linux ARM works perfectly if you don't break it :D

Specifically I had a file in /etc/modprobe.d containing the following line.

$this->bbcode_second_pass_code('', '
install llc /bin/true
')

Don't do that if you want to use VLANs :roll:

Original post below.
------------------------

Hi

I'm setting up a machine I'm planning to use as a router and I'd like to partition the internal network using VLANs. I'm using a Rock64 running the stock aarch64 kernel. The relevant parts of my configuration are as follows. There's just one VLAN in this configuration, I'll add the rest when I get it working. I've renamed the interface to int.

/etc/systemd/network/int.network
$this->bbcode_second_pass_code('', '
[Match]
Name=int
Type=ether

[Network]
Description=Internal network interface
ConfigureWithoutCarrier=yes

VLAN=int.dmz

LinkLocalAddressing=no
LLDP=no
EmitLLDP=no
IPv6AcceptRA=no
IPv6SendRA=no
')

/etc/systemd/network/int.dmz.netdev
$this->bbcode_second_pass_code('', '
[NetDev]
Name=int.dmz
Kind=vlan

[VLAN]
Id=1
')

/etc/systemd/network/int.dmz.network
$this->bbcode_second_pass_code('', '
[Match]
Name=int.dmz
Type=vlan

[Network]
Description=DMZ network
DHCP=no

[Address]
Address=192.168.1.1/24
')

It doesn't create the VLAN. Inspecting the log shows the following.

$this->bbcode_second_pass_code('', '
Feb 23 08:04:55 cerberus systemd-networkd[515]: int: Could not create stacked netdev: Unknown device type. Operation not supported
Feb 23 08:04:55 cerberus systemd-networkd[515]: int: Failed
')

Any ideas?
Last edited by Klepto on Wed Feb 23, 2022 12:10 pm, edited 1 time in total.
Klepto
 
Posts: 10
Joined: Tue Jun 23, 2015 4:27 pm

Re: VLAN strangeness using systemd-networkd on aarch64

Postby graysky » Wed Feb 23, 2022 10:59 am

I only used VLANs on a managed switch and on OpenWRT devices, never with systemd. You might want to also ask on the raspberry pi forums for more coverage.
graysky
Developer
 
Posts: 1876
Joined: Sun Jun 26, 2011 6:56 am
Location: /run/user/1000

Re: VLAN strangeness using systemd-networkd on aarch64

Postby Klepto » Wed Feb 23, 2022 11:22 am

Further investigation revealed the 8021q module isn't loading. Attempting to modprobe it manually returns...

$this->bbcode_second_pass_code('', '
modprobe: ERROR: could not insert '8021q': Unknown symbol in module, or unknown parameter (see dmesg)
')

dmesg shows the following....

$this->bbcode_second_pass_code('', '
[ 93.366550] stp: Unknown symbol llc_sap_close (err -2)
[ 93.366582] stp: Unknown symbol llc_sap_open (err -2)
')

I have an rpi4 that's still on the 5.15.5-1 mainline kernel and is using VLANs successfully. I downgraded to that kernel version on the Rock64 but it didn't help. I have used a VLAN on the Rock64 before without any problems, but that was with netctl, which is my next thing to try.
Klepto
 
Posts: 10
Joined: Tue Jun 23, 2015 4:27 pm

Re: VLAN strangeness using systemd-networkd on aarch64

Postby graysky » Wed Feb 23, 2022 12:02 pm

If the module is bad somehow, why would you think netctl would work? Which kernel are you running? linux-aarch64?
graysky
Developer
 
Posts: 1876
Joined: Sun Jun 26, 2011 6:56 am
Location: /run/user/1000

Re: [solved] VLAN strangeness using systemd-networkd on aarc

Postby Klepto » Wed Feb 23, 2022 12:11 pm

Thanks for your input graysky. I figured it out :)
Klepto
 
Posts: 10
Joined: Tue Jun 23, 2015 4:27 pm

Re: [solved] VLAN strangeness using systemd-networkd on aarc

Postby graysky » Wed Feb 23, 2022 12:35 pm

Sharing your solution can potentially help others finding your thread on a search in the future.
graysky
Developer
 
Posts: 1876
Joined: Sun Jun 26, 2011 6:56 am
Location: /run/user/1000

Re: [solved] VLAN strangeness using systemd-networkd on aarc

Postby Klepto » Wed Feb 23, 2022 1:24 pm

First post edited with the solution. TLDR: my own silly mistake :oops:
Klepto
 
Posts: 10
Joined: Tue Jun 23, 2015 4:27 pm


Return to General

Who is online

Users browsing this forum: No registered users and 38 guests