LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-23-2001, 12:33 AM   #1
360
Member
 
Registered: Jun 2001
Distribution: FC4
Posts: 136

Rep: Reputation: 15
bash: useradd: command not found


What's the problem here when I type:
useradd -d newuser /home/users
bash: useradd: command not found

Thanks
 
Old 08-23-2001, 01:20 AM   #2
mcleodnine
Senior Member
 
Registered: May 2001
Location: Left Coast - Canada
Distribution: s l a c k w a r e
Posts: 2,731

Rep: Reputation: 45
Are you doing this a root? It's kind of a priveleged app so you need to be su.
 
Old 08-23-2001, 01:29 AM   #3
360
Member
 
Registered: Jun 2001
Distribution: FC4
Posts: 136

Original Poster
Rep: Reputation: 15
Yes I /bin/su to root.
I'll have to talk to the guy who set it up tomorrow or something.

Thanks for your help.
 
Old 08-23-2001, 09:37 AM   #4
ektoric
LQ Newbie
 
Registered: Jun 2001
Location: Austin, TX
Distribution: FC5/6
Posts: 23

Rep: Reputation: 15
when you do a su to root, you might not have your PATH set up correctly.
Depending on your distribution, users (including root) probably have their .bash_profile (runs at login) set up, but not there .bashrc (runs at new shell).

Simply append the sbin dirs to your PATH in .bashrc
#vi .bashrc
export PATH=/usr/local/sbin:/usr/sbin:/sbin

or for your specific case, just call useradd with its full path name
# /usr/sbin/useradd -d newuser /home/users
 
Old 08-23-2001, 09:41 AM   #5
360
Member
 
Registered: Jun 2001
Distribution: FC4
Posts: 136

Original Poster
Rep: Reputation: 15
I found the problem.
I was going to root with /bin/su which did not give me all the privilages of a superuser.
By going to root with su - I have all the superuserprivelages.

Thanks
 
  


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
bash: g++: command not found m_lp_ql_m Linux - Software 8 07-08-2010 01:45 PM
-bash: ls: command not found jchun Linux - General 3 11-02-2004 10:11 AM
Useradd command not found. keysorsoze Red Hat 8 05-01-2004 03:17 PM
bash: command not found jc80 Fedora 3 03-14-2004 03:11 PM
bash: useradd: command not found KennyK Linux - Software 2 04-17-2003 09:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 03:44 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