LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Bash says that config (ifconfig, chkconfig and others) don't exist (https://www.linuxquestions.org/questions/linux-software-2/bash-says-that-config-ifconfig-chkconfig-and-others-dont-exist-245429/)

Pedal2Metal 10-21-2004 03:50 AM

Bash says that config (ifconfig, chkconfig and others) don't exist
 
I'm new to Linux and I am trying to get my server/workstation going. I am having trouble connecting to my Lan and Wan. I believe I configured all the addresses correctly. But every time I try to use any config commands to try to locate problems and determine if network cards and connections are working properly, Bash tells me that the commands don't exist--???? I have been trying to use ifconfig and chkconfig. Is it a problem with my Redhat 7.3 distro or some other issue??

darthtux 10-21-2004 04:45 AM

In Linux there is what is called a PATH. It is a list of directories where programs are looked for when you type them in at the command line. For instance the command ls is in /bin. If you do a
Code:

echo $PATH
you will notice that directory is in your PATH.

Most system config commands are in /sbin and /usr/sbin. These directories are not by default in a users PATH but are in root's.

If you "su -" to root then those commands can be accessed with a ifconfig. But a normal user has to do /sbin/ifconfig

If you want those commands in your PATH then add this to ~/.bashrc
Code:

export PATH=$PATH:/sbin:/usr/sbin
Hope that was clear.

Pedal2Metal 10-21-2004 05:50 AM

Thank. It was very helpful


All times are GMT -5. The time now is 01:26 PM.