Command ifconfig Used in Linux operating systems to configure the network or to view information about it. It was also present in the Debian distribution 9, but later it was decided to replace this tool with other more suitable utilities for this procedure. Despite this, now there is nothing stopping you from re-entering this command on your system and continuing to use it, just do a normal install of this component.
Troubleshooting the error “ifconfig: command not found”
If when trying to activate a command in “Terminal”. find a bug “Ifconfig: command not found”means that the software responsible for this command is not on the system. Today we want to show not only a method to solve this problem, but also talk about a newer alternative that replaces ifconfig. Let's start with a step-by-step breakdown of the first method.
Method 1: add ifconfig utility
Those users who are used to using this particular command will find this method optimal. The tool ifconfig not removed at all, it's just not in the standard suite of the system, and you can add it by following these instructions:
- First, We suggest you make sure once more ifconfig Not available. Run the classic terminal as you like.
- Grant permanent superuser privileges by typing
su -. - Enter the password for root access and wait for a new entry line to appear.
- Here you just have to enter
ifconfigand press the key Entered. - If the notification that there is no command in the system still appears, install the component set network toolspresenting
apt install net-tools. - Wait for new libraries to be added and configured.
- After the installation is complete, run the program
ifconfigto make sure the operation has been successful. - For more information on the rules of the utility in use, the line
ifconfig --help.
By now you are familiar with the method of returning the old standard utility to the Debian operating system. 9. Despite this, should pay attention that it has been replaced by a more convenient tool, so it makes sense to understand how to handle it and maintain the old ones. Habits.
Method 2: use ip command
There are several reasons why the command ifconfig has been replaced by ip in the standard kernel of the Linux operating system. First, did not allow the configuration of the traffic control system, did not work properly with some devices, it did not show its hardware address and it did not allow to generate TUN network devices / TAP. All these deficiencies were corrected and improved, but already introduced in the functionality. ip. As an example, You can see basic information of the interface by entering ip a.
Issuance in “Terminal”. after activation of the above command, will correspond to the one that would be shown in ifconfigbut with some additional data. Additional information about IPv4 is obtained through ip -4 aand for IPv6. ip -6 a. It is also possible to obtain data in a specific interface by entering ip a show wlan0and the list of working interfaces is displayed after ip link ls up.
One of the main tasks when configuring a network has always been the procedure of assigning a specific local address to a specific interface.. By using the above utility, the input string looked like this: ifconfig eth0 192.168.1.101But with the new, the user would have to enter ip a add 192.168.1.101/255.255.255.0 dev eth0making sure to specify the subnet mask. Also note the feasible abbreviation of ip a add 192.168.1.101/24 dev eth0.
If the need to map an interface to an IP address is no longer required, that string is pretty easy to delete. You just have to specify ip a del 192.168.1.101/24 eth0and if you need to delete the entire relationship list, it is better to use ip -s -s a f to 192.168.1.0/24.
Team ip also sets the routing table management. A routing table is a list of network routes designed to establish the best route for transmitting a network packet.. You can see all the available tables with the next line ip r.
In situations where you need to manually redirect traffic, it is better to use the command ip with certain arguments. Then the chain will have the form, as an example ip route add 192.168.5.0/24 dev eth0. The established route can also be easily deleted with ip route del 192.168.5.0/24 dev eth0.
Thanks to the two previous methods, now you know how you can not only recover the equipment ifconfig on Debian 9 YOU, but also what is a decent alternative to this outdated utility. The decision to use the new tool or go back to the old one is up to you.
We are glad we were able to help you with your problem..
Describe what didn't work for you.
Our specialists will try to respond as soon as possible.



