Bug 51844 - command not found .more help
Summary: command not found .more help
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: bash   
(Show other bugs)
Version: 6.2
Hardware: i686
OS: Linux
Target Milestone: ---
Assignee: Bernhard Rosenkraenzer
QA Contact: Aaron Brown
: 51839 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 2001-08-15 19:22 UTC by Need Real Name
Modified: 2007-04-18 16:35 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-08-15 19:38:49 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Need Real Name 2001-08-15 19:22:35 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)

Description of problem:
when I type  command, for example chkconfig or useradd or ifconfig, the 
error message is "bash:chkconfig:command not found." when I type "which 
useradd"  the error message is "no useradd found in...."
at the same time I can use vi,ls,pwd. if I reboot the system, the commands 
can work.I can add user or run ifconfig.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:

Additional info:

OUR KERNEL IS 2.2.16-4.LFS. The original kernel is 2.2.14. But I use
oracle 8.1.6 enterprise ,so I upgrade the kernel.
I found when I reboot the system, the same command can work. I notice
the lower case .

Comment 1 Need Real Name 2001-08-15 19:35:26 UTC
Could you help me? this is a bug or we did not config our system

Comment 2 Aaron Brown 2001-08-15 19:38:45 UTC
*** Bug 51839 has been marked as a duplicate of this bug. ***

Comment 3 Bernhard Rosenkraenzer 2001-08-15 20:01:24 UTC
Chances are you're just typing in wrong commands. chkconfig, useradd etc. live 
in /sbin and /usr/sbin, therefore they are not in the search path of normal 

If you want to call them up without the environment variables usually set for 
root, give the full location ("/sbin/chkconfig whatever").

If you are actually running as root, the most likely cause is that you removed 
/sbin and /usr/sbin from your PATH manually (e.g. by removing .bash_profile).

Comment 4 Need Real Name 2001-08-15 20:47:19 UTC
Yes, you are right. THANKS A LOT!!!!!!!

When I type "/usr/sbin/useradd aa', the command works. I can not find 
the .bash_profile of root user. DO you mean I should add the .bash_profile 
to root. what is the content of the .bash_profile? I have a .bash_profile of
our oracle user. The path parameter is "PATH=$PATH:$HOME/bin".

why after I reboot my computer,I type useradd without path,and the command 

Comment 5 Need Real Name 2001-08-15 21:12:15 UTC
Yes, I found there is a file:/root/.bash_profile. The path parameter
is "PATH=$PATH:$HOME/bin". I type "echo $HOME" The HOME parameter is
/root. So now what change should I make in order to run useradd in any
environment when I login as root?

Thanks in advance.

Comment 6 Need Real Name 2001-08-15 22:58:39 UTC
I am waiting for your answer. Do you think I should change .bash_profile 
under /root? How can I set the PATH in order to run chkconfig or useradd
in any directory as user root?



Note You need to log in before you can comment on or make changes to this bug.