How to find network card driver name and version on Linux

Question: An Ethernet network interface card is attached to my Linux box, and I would like to know which network adapter driver is installed for the NIC hardware. Is there a way to find out the name and version of a network card driver for my network card?

For network interface card (NIC) hardware to operate properly, you need a suitable device driver for the NIC hardware. A NIC device driver implements a hardware-independent common interface between the Linux kernel and the NIC, so that packets can be moved between the kernel and the NIC. While some drivers may be statically built in the kernel, most drivers for modern NICs are dynamically loaded as kernel modules.

When you are troubleshooting a NIC hardware problem, one thing you can do is to check whether a correct network adapter driver is installed properly. In this case, you need to know which kernel module is your NIC driver.

There are several ways to find the name/version of an Ethernet card driver on Linux.

Method One

The first method is to to check dmesg messages. Since the kernel loads necessary hardware drivers during boot, dmesg output should tell if an Ethernet card driver is installed.

$ dmesg | grep -i ethernet

The above output shows that a driver named tg3 is loaded in the kernel.

If you want to know more detail about this driver (e.g., driver version), you can use modinfo command.

$ modinfo tg3

If dmesg does not print any information about Ethernet driver, that means no suitable network device driver is available on your system.

Method Two

The second method is to use the ethtool command. To find out the driver name for an interface eth0, run the following.

$ ethtool -i eth0

Method Three

Another useful tool for NIC driver information is lshw. Type the following command to get detailed information about available Ethernet card(s) and their driver.

$ sudo lshw -class network

In the lshw output, look for the "capabilities" line, and examine "driver" and "driverversion" in the line.

If no suitable NIC driver is installed on your system, the driver field will remain empty.

Download this article as ad-free PDF (made possible by your kind donation): 
Download PDF

Subscribe to Ask Xmodulo

Do you want to receive Linux related questions & answers published at Ask Xmodulo? Enter your email address below, and we will deliver our Linux Q&A straight to your email box, for free. Delivery powered by Google Feedburner.

Support Xmodulo

Did you find this tutorial helpful? Then please be generous and support Xmodulo!

Leave a comment

Your email address will not be published. Required fields are marked *