Dieser Inhalt ist in der von Ihnen ausgewählten Sprache nicht verfügbar.
Chapter 10. Tuning the device driver and NIC
In RHEL, kernel modules provide drivers for network interface controllers (NICs). These modules support parameters to tune and optimize the device driver and the NIC.
For example, if the driver supports delaying the generation of receive interrupts, you can reduce the value of the corresponding parameter to avoid running out of receive descriptors.
Not all modules support custom parameters, and the features depend on the hardware, as well as the driver and firmware version.
10.1. Configuring custom NIC driver parameters Link kopierenLink in die Zwischenablage kopiert!
Many kernel modules support setting parameters to tune the driver and the network interface controller (NIC). You can customize the settings according to the hardware and the driver.
If you set parameters on a kernel module, RHEL applies these settings to all devices that use this driver.
Prerequisites
- A NIC is installed in the host.
- The kernel module that provides the driver for the NIC supports the required tuning feature.
- You are logged in locally or by using a network interface that is different from the one that uses the driver for which you want to change the parameters.
Procedure
Identify the driver:
ethtool -i enp0s31f6
# ethtool -i enp0s31f6 driver: e1000e version: ... firmware-version: ... ...Copy to Clipboard Copied! Toggle word wrap Toggle overflow Note that certain features can require a specific driver and firmware version.
Display the available parameters of the kernel module:
modinfo -p e1000e
# modinfo -p e1000e ... SmartPowerDownEnable:Enable PHY smart power down (array of int) parm:RxIntDelay:Receive Interrupt Delay (array of int)Copy to Clipboard Copied! Toggle word wrap Toggle overflow For further details on the parameters, see the kernel module’s documentation. For modules in RHEL, see the documentation in the
/usr/share/doc/kernel-doc-<version>/Documentation/networking/device_drivers/directory that is provided by thekernel-docpackage.Create the
/etc/modprobe.d/nic-parameters.conffile and specify the parameters for the module:options <module_name> <parameter1>=<value> <parameter2>=<value>
options <module_name> <parameter1>=<value> <parameter2>=<value>Copy to Clipboard Copied! Toggle word wrap Toggle overflow For example, to enable the port power saving mechanism and set the generation of receive interrupts to 4 units, enter:
options e1000e SmartPowerDownEnable=1 RxIntDelay=4
options e1000e SmartPowerDownEnable=1 RxIntDelay=4Copy to Clipboard Copied! Toggle word wrap Toggle overflow Unload the module:
modprobe -r e1000e
# modprobe -r e1000eCopy to Clipboard Copied! Toggle word wrap Toggle overflow WarningUnloading a module that an active network interface uses immediately terminates the connection and you can lock yourself out of the server.
Load the module:
modprobe e1000e
# modprobe e1000eCopy to Clipboard Copied! Toggle word wrap Toggle overflow Reactivate the network connections:
nmcli connection up <profile_name>
# nmcli connection up <profile_name>Copy to Clipboard Copied! Toggle word wrap Toggle overflow
Verification
Display the kernel messages:
dmesg
# dmesg ... [35309.225765] e1000e 0000:00:1f.6: Transmit Interrupt Delay set to 16 [35309.225769] e1000e 0000:00:1f.6: PHY Smart Power Down Enabled ...Copy to Clipboard Copied! Toggle word wrap Toggle overflow Note that not all modules log parameter settings to the kernel ring buffer.
Certain kernel modules create files for each module parameter in the
/sys/module/<driver>/parameters/directory. Each of these files contain the current value of this parameter. You can display these files to verify a setting:cat /sys/module/<driver_name>/parameters/<parameter_name>
# cat /sys/module/<driver_name>/parameters/<parameter_name>Copy to Clipboard Copied! Toggle word wrap Toggle overflow