How to set txqueuelen (transmit queue length) for a network interface using the udev rule method?
This document (000019932) is provided subject to the disclaimer at the end of this document.
Environment
SUSE Linux Enterprise Server 12
Situation
Resolution
# /sbin/ip address show eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
link/ether 00:0c:29:35:79:97 brd ff:ff:ff:ff:ff:ff
inet 192.168.17.135/24 brd 192.168.17.255 scope global eth0
...
Configure the udev rule in the file "/etc/udev/rules.d/70-persistent-net.rules" to the following:
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:0C:29:35:79:97", KERNEL=="eth*", NAME="eth0", ATTR{tx_queue_len}="10000"
Cause
Using the udev rule method is a way to automatically set the txqueuelen value when the system boots up.
Status
Additional Information
For example:
ifconfig eth0 txqueuelen 10000
ip link set dev eth0 txqueuelen 10000
2. Take note that the name for the txqueuelen setting used by the "ifconfig", "ip" and "systool" commands are "txqueuelen", "qlen" and "tx_queue_len" respectively.
For example:
# /sbin/ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:0C:29:35:79:97
inet addr:192.168.17.135 Bcast:192.168.17.255 Mask:255.255.255.0
...
collisions:0 txqueuelen:10000
# /sbin/ip address show eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 10000
link/ether 00:0c:29:35:79:97 brd ff:ff:ff:ff:ff:ff
inet 192.168.17.135/24 brd 192.168.17.255 scope global eth0
...
# /usr/bin/systool -vc net eth0
Class = "net"
Class Device = "eth0"
Class Device path = "/sys/devices/pci0000:00/0000:00:11.0/0000:02:01.0/net/eth0"
addr_assign_type = "0"
addr_len = "6"
address = "00:0c:29:35:79:97"
broadcast = "ff:ff:ff:ff:ff:ff"
...
tx_queue_len = "10000"
...
3. Take note that "ifconfig" command is deprecated since SLES 15.
Disclaimer
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:000019932
- Creation Date: 26-Mar-2021
- Modified Date:14-Apr-2021
-
- SUSE Linux Enterprise Server
For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com