ifconfig command not found - Amazon Linux

Page content

How to Install ifconfig Command on Amazon Linux

If you are using Amazon Linux and find that the ifconfig command is not available, don’t worry, it’s not a bug! The reason for this is that ifconfig has been deprecated in favor of the ip command in many Linux distributions, including Amazon Linux. However, you can still install ifconfig if you prefer using it over ip.

Step 1: Check if ifconfig is Installed

First, check if ifconfig is already installed on your system by running the following command:

ifconfig

If you receive a “command not found” error, proceed to the next step to install it.

Step 2: Install ifconfig

To install ifconfig on Amazon Linux, you can use the following command:

sudo yum install net-tools

This command will install the net-tools package, which includes ifconfig among other networking tools.

Step 3: Verify Installation

After the installation is complete, you can verify that ifconfig is now available by running the command again:

ifconfig

You should see the network interface information displayed on your terminal.

Conclusion

In this tutorial, you learned how to install the ifconfig command on Amazon Linux, even though it is no longer the recommended tool for network configuration. It’s always good to be familiar with both ifconfig and ip commands, as they serve similar purposes in managing network interfaces.