ifconfig won't work
I go into my /sbin directory and can't seem to run ifconfig. it is found in the directory but it won't start up. I'm currently running RH 8. Feedback would be greatly appreciated.
|
Tell us exactly what you are typing and what you're trying to accomplish.
cheers Jamie... |
I type "ifconfig -a"
I am trying to accomplish a preview of my IP Address. |
Give this a try instead
Code:
cd /sbin cheers Jamie... |
hey that seemed to work and I wasn't logged in as root, how do I get it to work no matter what directory I'm in?
|
/sbin isn't in the path of non-root users as most of those commands need yout to be root to do anything useful with. You can add it to your path (and everyone's path on the machines) by editing the PATH statement in /etc/profile. Alternatively if you just want to edit your user's path you can create a .profile/.bash_profile/.bashrc/.cshrc/whateverFileYourShellUses in your home directory and put a new PATH statement in there.
cheers Jamie... |
Ok I set the PATH variable in the .profile of my user account. Do I need to log out and log in again to invoke the new .profile settings in order for this new PATH to work?
|
You either need to logout and log back in, start a new shell, or run
Code:
source ~/.profile cheers Jamie... |
Thanks alot for your help. Can I use the .profile as a startup on applications as well?
|
I don't follow... The .profile file is typically used to define environment variables and carry out tasks at startup, you could start applications from it but you would end up starting those applications evertime you opened a shell.
Is that the answer to the question you asked or did I just answer the question I thought you were asking? cheers Jamie... |
All times are GMT -5. The time now is 01:38 AM. |