LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 07-21-2004, 04:18 AM   #1
ylkien
LQ Newbie
 
Registered: May 2004
Posts: 16

Rep: Reputation: 0
Fedora command prompt problem


Hi,

i just installed fedora. i tried the command "ifconfig" under root, but it doesn't work. It only works when i am in the "/sbin" folder. What could be the cause of this problem?

I tired the command "service", but it was no where to be found. Did i forget to install something?

Thanks.
 
Old 07-21-2004, 04:51 AM   #2
Goala
Member
 
Registered: May 2004
Location: Merida (Spain)
Distribution: Debian
Posts: 89

Rep: Reputation: 15
you have to add the /sbin to your PATH variable. When you run a command the system searchs for that file in the path indicated in your PATH variable. If it doesn't exist in these directories you get a "command not found" error.

You can see the PATH value:
echo $PATH

Put a line such this into the root $HOME/.profile (or $HOME/.bash_profile?) file (or you can edit the line where PATH is established).

PATH=$PATH:/sbin

bye.
 
Old 07-21-2004, 07:53 AM   #3
Joubert79
Member
 
Registered: Jul 2004
Location: Manchester, UK
Distribution: Gentoo
Posts: 46

Rep: Reputation: 15
Indeed, /sbin needs to be in roots path. If you're getting to root by changing user with "su" (rather than logging in) then this wont change any environment variables, like $PATH, from the current users. /sbin is usually not in a users path, and nor should it be really. Try "su -" to get a login shell as root and thus obtain root environment variables.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Prompt command to...? Kelphyr Slackware 10 10-03-2004 04:42 PM
Key stroke/command to shut down x and go into the command prompt screen? Fear58 Linux - General 1 07-14-2004 07:14 PM
Command Prompt? eXdener Linux - Newbie 3 01-05-2004 04:38 PM
How to recall an old command at the command prompt? J_Szucs Linux - Newbie 9 03-07-2003 12:29 AM
problem with command line prompt ??? robeb Linux - General 2 12-07-2002 08:47 PM


All times are GMT -5. The time now is 11:13 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration