Centos 7 does not have the ifconfig command, centosifconfig
Centos 7 does not have the ifconfig command:
Installation command: yum install net-tools
Why does centos input ifconfig saying that this command is not available?
First, normal users do not have the permission to execute this command. If you have to execute this command, the search path of the executable file of the current user is incorrect. First, locate ifconfig to check the location of the command. it should be in/sbin/ipconfig, and then use echo $ PATH to check whether your current user's PATH contains the/sbin PATH. If it is not in ~ /. Add/sbin after PATH = $ PATH: $ HOME/bin in bash_profile ~ To use the command: source. bash_profile
In centos63, The ifconfig-a command is used to display three items: l0, p1p1, wlan0, and eth0.
Check whether the NAME in/etc/udev/rules. d/70-persistent-cd.rules is written in p1p1.
Change to eth0, delete the physical address in/etc/sysconfig/network-scripts/ifc-eth0, and restart the machine.