Tuesday, September 15, 2020

Network Adapter Not Found Ubuntu

If you install a second network adapter in the Ubuntu (Linux) system, sometimes it will not detect by the operating system. This problem is not only in the case of the second network adapter, many times our main network adapter does not detect by the Ubuntu (Linux) operating system. In this article, we will discuss about the solution for this problem.

When a network card is inserted into a Ubuntu (Linux) system, the operating system creates a script file for that card. By default, the network card is configured as disable in that script file. It is shown below: -


Because the "ONBOOT" value is configured as "no" here, the Ubuntu (Linux) operating system does not enable it when booting the system. Due to which, we can't find the network card.

If we set this value to "yes", our card will be activated. However, after changing the value, we need to restart the entire system once.

Here we will see the complete process for activating network card in Ubuntu (Linux) operating system step by step.

We know that when a network card is inserted, a script file is created for it. The location of the file is given below: -


One thing we need to keep in mind here is that, the name for the first network card will be “ifcfg-eth0”, then the name for the second will be “ifcfg-eth1”, the name for the third will be “ifcfg-eth2”, and so on.

Now we will open the script of that network card using “VI editor”. If you want, you can use any editor other than "VI Editor". The complete command to open the file is: -


Now we will change the value for "ONBOOT" to "yes".


Since, after opening the file it will be in “read only” mode, so we will have to go to “insert” mode. To go into “insert” mode we need to press “i” from the keyboard. After changing the value, we will exit the "insert" mode by pressing the "escape" button. At the end of all, we will save and close the file using the following command.


Now, we will restart the whole system once. I hope, this time the network card will be detected by the operating system. To view the list of network cards, the command is: -

ip link

From this script file, we can configure IP information also.

No comments:

Post a Comment