LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-21-2005, 06:38 AM   #1
dev_mohamed
LQ Newbie
 
Registered: Jun 2005
Posts: 18

Rep: Reputation: 0
user home dir doesn't create when new user add


Dear,
i have a problem when create new user the system doesn't create a user home dir under /home i don't want to use the -d option to tell where is the home dir i want use the default.

note i am on debian.

can any one tell me why does it can't create a user home dir

thank you
 
Old 06-21-2005, 10:09 AM   #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,

Take a look at the useradd manpage, especially the -b option (part of the 'Changing the default values' section).

Hope this helps.
 
Old 06-22-2005, 02:13 AM   #3
dev_mohamed
LQ Newbie
 
Registered: Jun 2005
Posts: 18

Original Poster
Rep: Reputation: 0
try adduser

hi,

i try adduser instad of useradd to create the new user and it's work fine it's create the user home dir and also it ask me about all the user info like the passwd, full name and other.

as i think this is happend on debian i didn't see this in redhat or fedora

thank you.
 
Old 01-12-2007, 01:08 AM   #4
osdeals
Member
 
Registered: Jul 2006
Distribution: RHEL, CentOS, PuppyLinux, SuSe, Ubuntu, Debian
Posts: 59

Rep: Reputation: 15
Use the '-m' option with useradd. This tells the command to create the home directory.
You may also want to use the '-d' option to specify the directory to be created. The '-k' option will specify the skeleton directory from where the initial files to be put into the home directory will be picked up (the default is /etc/skel).

useradd -d /home/username -m -k /etc/skel username

Hope that helps.
 
  


Reply



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
Lock user in home dir JJX Linux - General 9 06-28-2011 02:09 PM
lock new user into home dir eyewittness Linux - Security 4 06-19-2005 12:33 PM
HELP! When I create a new user a home dir isn't created lynchpin9 Linux - General 5 01-18-2005 11:05 AM
user home dir/permissions xilace Linux - Security 5 07-21-2004 12:33 PM
recover user and home dir powadha Linux - General 5 04-16-2004 09:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:51 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
Open Source Consulting | Domain Registration