Install ifconfig on debian 11 or 10, if command not found

After installing Debian 11 Bullseye or 10 Buster, if you get ifconfig: command not found error while using it to check the system’s Ip-addresses, then here are the steps to solve the problem.

It is the command tool that is used on the Linux system to look for its current IP address and other information of the network.

Install ifconfig on Debian 11 Bullseye

Although we don’t need to install ipconfig, because we already have an inbuilt tool to check the ip-address that is:

ip a

Well, the ipconfig is missing because it has been decrypted and hence is not available, by default, anymore. And replaced by ip

Still, if you want it, then just need to install net-tools

1. Run system update

The first thing is to do is running of system update command to refresh the system repo and install the latest available version of the already installed packages.

sudo apt update

 

2. Command to install ifconfig on Debian 11 or 10

The network tool is available via net-tools that is available via the default-based repository for the Debian operating system. Hence, simply run:

sudo apt install net-tools

 

3. Add ifconfig to the system path

By default, you won’t be able to use the command because it is not in the system path. If you don’t want to add it to the path then use- sbin/ifconfig

However, for ease, us the below steps:

sudo nano ~/.bashrc

Scroll to the end of the file and add:

export PATH=/usr/sbin:$PATH

Save the file by press Ctrl+O, Enter Key, and for exiting it Ctrl+X.

Add ifconfig to system path

Next, Close the Terminal and open it again.

 

4. Use the ifconfig

After the installation, you can check out your network interface with ifconfig . In the given screenshot you can see, there are two interfaces. One interface is our lo or loopback (localhost). It is mainly used for diagnostics, troubleshooting, and connecting to servers running on the local computer. The first is enp0s3 , which is called ” eth0 ” on the physical computer.

ifconfig installation on Debian 11 or 10 linux

 

Other Articles:

 

 

1 thought on “Install ifconfig on debian 11 or 10, if command not found”

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.