ifconfig is a command for Linux to display network devices. It can set the status of network devices. However, in RedHat Linux 5 system, sometimes the ifconfig command cannot be used. The following small series will introduce you to RedHat Linux 5. Use the resolution of the ifconfig command.
Use some commands in the terminal, such as: ifcinfig view the IP of the machine, use this command can not be found, suggesting that & ldquo; command not found & rdquo ;, then think about how to do this is certainly an environment variable If it is not loaded, then modify the environment variable, modify it as follows:
1. After the initial installation completes the system, the system is safer. Some commands are not in the PATH environment variable. You can use the echo $PATH command. The query knows that the way to add the path to the PATH environment variable is as follows:
(such as adding /sbin to the PATH environment variable)
(1) If you only want to temporarily install this boot process Sexual additions and modifications, if the next boot is invalid, you can:
Enter export PATH=$PATH:/sbin
(2) If you only add the current user permanently, then:
In the ~/.bash_profile near the end of a line like PATH=$PATH:$HOME/bin, add: /sbin, it becomes PATH=$PATH:$HOME/bin:/sbin
After the file is modified and kept, run source ~/.bash The _profile command will make the modification take effect immediately.
(3) If all users in the system are permanently added:
Add export PATH=$PATH:/sbin
at the end of the /etc/profile file. After the file is modified and kept, run the source etc/profile command to make the modification take effect immediately.
2, there is a solution
[root@admin007]# /sbin/ifconfig
or modify the /etc/profile file
[ Root@amdin007]# vi /etc/profile
Comment out the following if statement
# Path manipulation
if [ “$EUID” = “0” ] ; then
pathmunge /sbin
pathmunge /usr/sbin
pathmunge /usr/local/sbin
fi
:
# Path manipulation
#if [ “$EUID” = “0” ]; then
pathmunge /sbin
pathmunge /usr /sbin
pathmunge /usr/local/sbin
#fi
Save, restart the system!
The above is the method that RedHat Linux 5 can't use the ifconfig command. This article introduces two solutions, mainly by modifying the /etc/profile file, and remember to restart the system after modification.
When browsing the website suddenly changed the card, I do not know the reason for the computer or th
AWK is a regular expression and an important text processing tool. In Linux systems
The Linux command Xconfigurator is mainly used to scan the display and adjust the s
Autofs is an automount tool for mounting file systems. When you start Linux system, Autofs will also
Linux how to use cp command guide
Ubuntu replaces the Firefox version of the method
How to boot a Linux ISO image file from the hard disk
How to run the compiler with root privileges under Linux?
Install the deb package operation instance on Ubuntu
What is the command to specify the line in the Linux view file?
Linux using the fdisk tool to create partitions
Ubuntu 12.04 how to install and use Byobu
How does Ubuntu recover the GNOME Panel that was accidentally deleted?
10 questions that must be solved for Windows 7 to succeed
Win10 official version will be on July 29th Build 10147 new wallpaper first
What does ppap mean, what is the process file?
Win7 optimize the registry to solve the computer failure tutorial
Hearthstone legend big chaos with what deck is good
Five-step operation allows the win8 system to completely shut down
How can I solve the problem that Win7 cannot change the account password?
Shell script analysis nginx log access times and most time-consuming pages (slow query)