The ifconfig in Centos7
Today to minimize the installation of CENTOS7, installation completed, want to check the network configuration:
Ifconfig command after display
-bash:ifconfig:command not found
Solution: Determine if Ifconfig is installed
First see if/sbin/ifconfig exists
1. If present, check the environment variable settings:
Echo $PATH
If the environment variable does not contain the path where the Ifconfig command is located:
1) temporarily modify environment variables:
Export PATH = $PATH:/sbin
The environment variable setting disappears when the shell is closed.
2) Change the environment variables permanently:
Open a./etc/profile file, where you enter Export path= $PATH:/sbin, save and restart.
Or, under the/etc/profile.d/directory, create a new ifconfig.sh script file with the following file contents:Export path= $PATH:/sbin Save and restart.
2. If it does not exist:
Yum Upgradeyum Install Net-tools
The CENTOS7 of the---of Linux learning article ifconfig