LinuxQuestions.org
Register a domain and help support LQ
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 03-19-2004, 02:03 AM   #1
sunilmuddu
LQ Newbie
 
Registered: Mar 2004
Location: hyderabad
Posts: 3

Rep: Reputation: 0
i am getting command not found error when i am trying to perform commands in linux?


Hi All,

i am getting command not found error when i am trying to perform commands in linux?

i am using redhat9.

any time of command, say 1. pvcreate, 2. pvscan, 3. pvdisplay etc.,

can anyone help me in overcoming this problem, please do.

thanks,
Sunil Muddu

Last edited by sunilmuddu; 03-19-2004 at 03:52 AM.
 
Old 03-19-2004, 02:41 AM   #2
slakmagik
Senior Member
 
Registered: Feb 2003
Distribution: Slackware
Posts: 4,113

Rep: Reputation: Disabled
Saying what commands would help. If it's something you've installed, it may have ended up somewhere off your path. If it's something meant for root it may be off your path or you may not have the right permissions. Check out the man pages for 'bash' regarding 'path' and for 'chmod', I guess, to get an idea of permissions. Either editing your path, changing perms, or moving the executable someplace appropriate should do it. Or, if it *is* something you need to be root for, 'su'.

Oh, just noticed that was post #1 - welcome to LQ.
 
Old 03-20-2004, 11:28 AM   #3
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,569

Rep: Reputation: 171Reputation: 171
Moved: This thread is more suitable in Linux-Newbie and has been moved accordingly to help your thread/question get the exposure it deserves.
 
Old 03-20-2004, 12:13 PM   #4
statmobile
Member
 
Registered: Aug 2003
Location: Chapel Hill, NC
Distribution: Gentoo, Windows 95 2000 & XP
Posts: 160

Rep: Reputation: 30
What do you see when you type:
echo $PATH
(Remember that Caps lock is important here)
 
Old 03-23-2004, 12:34 AM   #5
sunilmuddu
LQ Newbie
 
Registered: Mar 2004
Location: hyderabad
Posts: 3

Original Poster
Rep: Reputation: 0
when i type echo $PATH, iam getting this path.

/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/home/qa/bin/sbin

and displaying the prompt for next command.
 
Old 03-23-2004, 01:25 AM   #6
slakmagik
Senior Member
 
Registered: Feb 2003
Distribution: Slackware
Posts: 4,113

Rep: Reputation: Disabled
I'd suspect you'd need /sbin or /usr/sbin on your path or need root permissions/paths. Try a 'which pvscan' to see where they are, assuming they're on the system at all. Then install them, add the path they're in to yours, 'su' to root - whichever's appropriate. I figure it's just an 'su'. If not, 'export PATH="$PATH:where-it-is"
 
Old 03-24-2004, 12:59 AM   #7
sunilmuddu
LQ Newbie
 
Registered: Mar 2004
Location: hyderabad
Posts: 3

Original Poster
Rep: Reputation: 0
Hi digiot,

thankyou very much for the help, it is working fine now, but one small concern, it is showing "command not found" error when i type "env" to check the environment and see the path now.

can i get any more suggestions on this.

thanks again for the great help.

thanks & regards,
Sunil Muddu
 
Old 03-24-2004, 01:18 AM   #8
slakmagik
Senior Member
 
Registered: Feb 2003
Distribution: Slackware
Posts: 4,113

Rep: Reputation: Disabled
Hm. That's strange. I have env in /usr/bin/env. I don't have much occasion to use env, but it still oughtta be there. I usually use 'set' to see everything or 'echo $VAR' to see a specific variable. This is assuming bash, actually. I'm not sure how other shells work. I guess I'd try the same principle - except I told you wrong - 'which' won't help you find something to put on your path if it's not on your path. Try 'whereis env' and then 'echo $PATH' - if the path 'whereis' shows isn't shown by 'echo' then it'd be a case of adding it, too. But that wouldn't explain how env got lost. I'm guessing there's a typo or something in one of your shell config files.
 
  


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
Can't perform root command by using Sudo acbenny Linux - General 6 05-07-2008 09:19 PM
command not found error cdsnithi Linux - Software 2 07-06-2005 01:26 PM
command not found error lordshipmayhem Linux - Newbie 4 06-28-2005 10:15 PM
Basic Commands Not Found Error varunbihani Linux - Newbie 5 01-21-2005 05:57 AM
"Command not found" for existing commands kpachopoulos Linux - Newbie 8 10-01-2004 05:34 PM


All times are GMT -5. The time now is 02:58 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration