I have created the following NetworkManager dispatcher files on my system, following the instructions I read here: https://www.bufferbloat.net/projects/codel/wiki/CakeRecipes :
$ cat /etc/NetworkManager/dispatcher.d/30-ethtool
#!/bin/bash
if [ "$1" == "enp68s0" ] && [ "$2" == "up" ]; then
ethtool -K "$1" tso off gro off gso off
fi
$ cat /etc/NetworkManager/dispatcher.d/pre-up.d/40-qdisc-cake
#!/bin/bash
if [ "$1" == "enp68s0" ]; then
tc qdisc replace dev "$1" root cake ethernet bandwidth 1gbit
fi
cat /etc/NetworkManager/dispatcher.d/45-qdisc-cake-inbound
#!/bin/bash
if [ "$1" == "enp68s0" ] && [ "$2" == "up" ]; then
ifb="ifb4$1"
ip link add name "$ifb" type ifb
tc qdisc del dev "$1" ingress
tc qdisc add dev "$1" handle ffff: ingress
tc qdisc del dev "$ifb" root
tc qdisc add dev "$ifb" root cake bandwidth 1gbit besteffort
ip link set "$ifb" up
tc filter add dev "$1" parent ffff: matchall action mirred egress redirect dev "$ifb"
fi
And this is the status of my network devices once the system is booted (I have disabled IPv6 on enp68s0):
$ tc -s qdisc show dev enp68s0
qdisc cake 8001: root refcnt 9 bandwidth 1Gbit diffserv3 triple-isolate nonat nowash no-ack-filter split-gso rtt 100ms noatm overhead 38 mpu 84
Sent 349141491 bytes 355525 pkt (dropped 0, overlimits 412519 requeues 1275)
backlog 0b 0p requeues 1275
memory used: 205056b of 15140Kb
capacity estimate: 1Gbit
min/max network layer size: 28 / 1500
min/max overhead-adjusted size: 84 / 1538
average network hdr offset: 14
Bulk Best Effort Voice
thresh 62500Kbit 1Gbit 250Mbit
target 5ms 5ms 5ms
interval 100ms 100ms 100ms
pk_delay 13us 17us 3us
av_delay 5us 2us 1us
sp_delay 0us 0us 0us
backlog 0b 0b 0b
pkts 305582 49404 539
bytes 342836359 6282092 23040
way_inds 876 2189 0
way_miss 4837 8131 9
way_cols 0 0 0
drops 0 0 0
marks 0 0 0
ack_drop 0 0 0
sp_flows 7 6 1
bk_flows 0 0 0
un_flows 0 0 0
max_len 3012 3487 112
quantum 1514 1514 1514
qdisc ingress ffff: parent ffff:fff1 ----------------
Sent 35716092 bytes 195928 pkt (dropped 0, overlimits 0 requeues 0)
backlog 0b 0p requeues 0
$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp68s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc cake state UP group default qlen 1000
link/ether d4:5d:64:55:a0:4c brd ff:ff:ff:ff:ff:ff
inet 192.168.1.3/24 brd 192.168.1.255 scope global dynamic noprefixroute enp68s0
valid_lft 85806sec preferred_lft 85806sec
3: ifb0: <BROADCAST,NOARP> mtu 1500 qdisc noop state DOWN group default qlen 32
link/ether 46:0f:08:5b:58:19 brd ff:ff:ff:ff:ff:ff
4: ifb1: <BROADCAST,NOARP> mtu 1500 qdisc noop state DOWN group default qlen 32
link/ether 5a:6e:1b:6a:11:ea brd ff:ff:ff:ff:ff:ff
5: ifb4enp68s0: <BROADCAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc cake state UNKNOWN group default qlen 32
link/ether ca:5b:3f:51:a9:a7 brd ff:ff:ff:ff:ff:ff
inet6 fe80::c85b:3fff:fe51:a9a7/64 scope link
valid_lft forever preferred_lft forever
My doubts are: is that ip
output correct? is it "normal" that ifb0
and ifb1
are created and in the DOWN state? is it also "normal" that ifb4enp68s0
has the status UNKNOWN
?