LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices


Closed Thread
  Search this Thread
Old 12-15-2005, 01:04 PM   #1
turalo
Member
 
Registered: Sep 2005
Location: NL
Distribution: linux, windows,
Posts: 115

Rep: Reputation: 19
Unhappy Pleas help with commands, they are ont working.


Hy guys, this problem making me realy sick now, I cant use any normal command, when I type in the command it says : command not found, firt it was only thing like ifconfig or ifconfig -a , and I was thinking that maybe is something with the ifconfig, but now I just installed Apache 2.2 everything wass ok ./configure, make, make install everything went good, now I want to start my apache /usr/sbin/apachectl -k start , nothing works or if I do stop , nothing, it just comes up with " command not found"
:
[root@Vigor31 sbin]# clear

[root@Vigor31 sbin]# locate apachectl
/usr/share/man/man8/apachectl.8.gz
/usr/sbin/apachectl
/var/www/manual/programs/apachectl.html.ko.euc-kr
/var/www/manual/programs/apachectl.html
/var/www/manual/programs/apachectl.html.en
[root@Vigor31 sbin]# apachectl -k start
bash: apachectl: command not found
[root@Vigor31 sbin]# ls
accept

Im logged on as root, please help me, this is very strange but some commands like "who" "last" "df" are working, but others not.
I have Fedora core 4.
 
Old 12-15-2005, 01:29 PM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

Are you sure you are root?

$ id
uid=0(root) gid=0(root) groups=0(root)

I'm asking because who, last and df reside in a bin directories (accessible to 'all') and the commands not working reside in sbin directories which are (mostly) only accessible by root.

Some other things you could check:

ls -l /usr/sbin/apachectl => owner, groups and permissions. Are they correct. The same for the sbin directories.
echo $PATH => are the sbin directories present

Hope this gets you going again.
 
Old 12-15-2005, 04:42 PM   #3
turalo
Member
 
Registered: Sep 2005
Location: NL
Distribution: linux, windows,
Posts: 115

Original Poster
Rep: Reputation: 19
if you look at my copied text above, " [root@Vigor31 sbin]# locate apachectl
if you look at this, than you will see [root@vigor31 sbin] this means that I'm root at the sbin directory. when I login then u see other name, after the su command and pass, I get root@vigor31 so I'm 100% root.
 
Old 12-15-2005, 06:46 PM   #4
kurtdriver
Member
 
Registered: May 2005
Location: Vancouver, Canada
Distribution: Fedora 18, Puppy Linux, various others
Posts: 107

Rep: Reputation: 15
Possibly those commands are not in your path. when you su, is it with the dash; the command su - gives you the complete environmental variables for root. Good luck!
 
Old 12-15-2005, 06:57 PM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
To expand on Kurt's comment,
su <someuser>
without a '-' logs you in as that user, but WITHOUT their env; in fact you retain your orig env.
su - <someuser>
logs you in as that user WITH their env.
HTH
 
Old 12-15-2005, 11:49 PM   #6
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

If you used su instead of su- the PATH belonging to root is not set (as chrism01 already stated).

PS: A prompt is easy to manipulate, if it says root it doesn't have to be so.

Hope this helps.
 
Old 12-16-2005, 01:49 AM   #7
turalo
Member
 
Registered: Sep 2005
Location: NL
Distribution: linux, windows,
Posts: 115

Original Poster
Rep: Reputation: 19
ok let's try, , I'm going to try it, and will be back with the results.
 
Old 12-16-2005, 01:17 PM   #8
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Rep: Reputation: 67
If it still doesn't work then echo $PATH and tell us the result. If /sbin and /usr/sbin aren't in there then that is your problem.
 
Old 12-16-2005, 01:59 PM   #9
XavierP
Moderator
 
Registered: Nov 2002
Location: Kent, England
Distribution: Debian Testing
Posts: 19,192
Blog Entries: 4

Rep: Reputation: 475Reputation: 475Reputation: 475Reputation: 475Reputation: 475
Please do not post the same thread in more than one forum. Picking the most relevant forum and posting it once there makes it easier for other members to help you and keeps the discussion all in one place.

http://www.linuxquestions.org/rules.php
 
  


Closed Thread



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
pleas can you help me....i need you ALaa Cabo Linux - Software 2 08-15-2005 07:54 PM
Help help pleas phil75 Linux - General 9 06-18-2005 03:58 AM
Commands not working jongage Linux - Newbie 3 11-24-2004 09:29 PM
ont size / resolution wikid_one Linux - General 7 04-25-2004 04:28 PM
Pleas help! henkas Linux - Networking 13 11-04-2003 06:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora

All times are GMT -5. The time now is 07:30 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration