How to Install Missing ifconfig Command on Linux
When running the “ifconfig” command on Linux, you may experience a missing “ifconfig” command error or the “ifconfig: no such file or directory” error as shown below:
The above problem occurs because you have accidentally deleted the ifconfig command line utility from Linux system and you can install it on your system again by running the following command:
The net-tools are a suite of network-related packages that includes ifconfig command line utility.
After the installation of net-tools, you can get ifconfig command in your system and you can check if it exists on your system or not by executing the command given below:
Now, you can get the details about your network interfaces by executing the command given below:
Alternative to ifconfig Command on Linux
There is another alternative of the ifconfig command that provides similar outputs as ifconfig command. As an alternative to the ifconfig command run the given below command to get the network interfaces information on the terminal.
Conclusion
Sometimes commands or utilities are accidentally deleted from the system and as a result, you won’t be able to run the command on the terminal. The same is the case with the ifconfig command which is used to get the network interface details on your Linux system. If you find a missing ifconfig error while executing the command, you can install net-tools and use the command again on the Linux system.