I'm trying to set-up 802.1p VLAN priorities on my Linksys E8450. I've tried configuring egress_qos_mapping by editing the config. I've also tried the following command:
ip link set br-lan.15 type vlan egress 0:4 1:4 2:4 3:4 4:4 5:4 6:4 7:4
/etc/config/network
config device
option name 'br-lan'
option type 'bridge'
list ports 'lan1'
list ports 'lan2'
list ports 'lan3'
list ports 'lan4'
list ports 'wan'
config bridge-vlan
option device 'br-lan'
option vlan '15'
list ports 'lan2:u*'
list ports 'lan3:u*'
list ports 'wan:t'
config device
option name 'br-lan.15'
option type '8021q'
option ifname 'br-lan'
option vid '15'
list egress_qos_mapping '0:4'
list egress_qos_mapping '1:4'
list egress_qos_mapping '2:4'
list egress_qos_mapping '3:4'
list egress_qos_mapping '4:4'
list egress_qos_mapping '5:4'
list egress_qos_mapping '6:4'
list egress_qos_mapping '7:4'
Everything appears to work, but I'm not seeing any changes in Wireshark.
Priority is inherited only other way, i.e if you set dscp then it is trated as priority, not vice versa.
Please connect to your OpenWrt device using ssh and copy the output of the following commands and post it here using the "Preformatted text </> " button:
Remember to redact passwords, MAC addresses and any public IP addresses you may have:
QoS mapping only applies to local qdic like pfifo_fast that takes local priorities, what you are expecting is DSCP marking which you can do in firewall or tc.
Not sure, VLAN priorities are orthogonal to DSCPs... @wahflz how did you check with wireshark, and on which interface did you capture the data for confirmation?
It works only one way. DSCP is copied to local priority, then local priority is used by qdisc, if you alter priority then DSCP in packet does not change but new priority is used.
I might be missing something here, as my understanding is that the OP wants to change the 802.1Q VLAN tag PCP priority field, in which case I wonder how DSCPs should matter? But as I said, I might simply be confused here...
I moved on to nftables bridge filtering and DSCP, but I honestly didn't give the traffic a thorough enough look.
My initial thought was that QoS mapping took Linux's internal value and mapped it to 802.1p. I'm a little confused with the DSCP comparisons as well. I'm by far no expert on the subject, though.
I thought 802.1p would be easier than writing nft rules, but I already burned a decent chunk of time on it.
I chose VLAN priorities because that's all pfSense supports. I realized that only traffic coming from the router will be tagged, so I figured I would make things consistent instead of mixing 802.1p and DSCP. I kind of went down a rabbit hole for no reason, as I'll probably save nanoseconds (at most) like brada4.
I have a weird set-up where I have multiple switches hooked up to MoCA devices. I figured I would prioritize some traffic over all the media streaming since the switches support QoS (but not enough for fine tuning).
Looking into this some more, I found that running the 'ip' command in my original post works very briefly. The AP sends a couple of IPv6 multicast packets with whatever priority I set in the command. I tested this on another Netgear AP. It does the same thing.
I believe the qos-egress-mapping is supposed to set the VLAN priority, but it's not working.
Yeah, it's working as expected. I guess most of the traffic isn't going thru the interface, so it's not being mapped. That packet is link-local IPv6, so technically it's local to the interface. The mapping works fine with MGMT. I guess that's what @brada4 was trying to say.