LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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-31-2011, 05:52 AM   #1
aocferreira
Member
 
Registered: Feb 2011
Posts: 116

Rep: Reputation: 0
Cannot add user!


Hello,
I'm getting an error when adding a user.

# adduser bla
Adding user `bla' ...
Adding new group `bla' (1001) ...
Adding new user `bla' (1001) with group `bla' ...
Creating home directory `/home/bla' ...
Stopped: Couldn't create home directory `/home/bla': No such file or directory.

Removing directory `/home/bla' ...
Removing user `bla' ...
Removing group `bla' ...
groupdel: group 'bla' does not exist
adduser: `groupdel bla' returned error code 6. Exiting.

What's the problem? Ty
 
Old 03-31-2011, 05:58 AM   #2
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 670Reputation: 670Reputation: 670Reputation: 670Reputation: 670Reputation: 670
Try looking in Kernel messages for more information on what went wrong. Does /home/ exist? Is the filesytem OK, and is the directory writable?

The "Couldn't create home directory '/home/bla'. No such file or directory, seems to indicate a problem with /home/.
 
Old 03-31-2011, 05:58 AM   #3
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2beta2 on Lenovo Thinkpad W520
Posts: 6,780

Rep: Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117
Please tell us which distribution you use and post the output of following command:
Code:
ls -l /home
 
Old 03-31-2011, 06:05 AM   #4
aocferreira
Member
 
Registered: Feb 2011
Posts: 116

Original Poster
Rep: Reputation: 0
thanks for quick reply.

both of you are right, the problem is indeed that folder /home.

# ls -l /home
total 0

My distribution is debian.. I think the folder it's used instead of /home here is /homelocal because i only add the 'operador' user

# ls -la /homelocal
total 20
drwxr-xr-x 5 root root 4096 2010-07-21 19:40 .
drwxr-xr-x 26 root root 4096 2011-03-29 13:08 ..
drwxrwxrwx 2 operador operador 4096 2010-11-22 20:22 files
drwxrwxrwx 40 operador operador 4096 2011-03-31 10:32 operador
drwxrwxrwx 3 operador operador 4096 2010-11-22 20:23 scripts

is there any problem? i have to create /home to add a new user?
 
Old 03-31-2011, 06:09 AM   #5
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2beta2 on Lenovo Thinkpad W520
Posts: 6,780

Rep: Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117
Quote:
Originally Posted by aocferreira View Post
is there any problem? i have to create /home to add a new user?
Yes
 
Old 03-31-2011, 06:10 AM   #6
aocferreira
Member
 
Registered: Feb 2011
Posts: 116

Original Poster
Rep: Reputation: 0
/etc/adduser.conf

# The DHOME variable specifies the directory containing users' home
# directories.
DHOME=/home

And if I change this variable to /homelocal, it's the same thing? Thank you.
 
Old 03-31-2011, 06:23 AM   #7
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2beta2 on Lenovo Thinkpad W520
Posts: 6,780

Rep: Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117Reputation: 2117
I don't know, as this setting is Debian-specific.

But I would try.
 
Old 03-31-2011, 06:36 AM   #8
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 670Reputation: 670Reputation: 670Reputation: 670Reputation: 670Reputation: 670
I'm going to make a wild guess that /homelocal or (/home/local/) is for users whose home directories are on that computer, while /home contains users' home directories where the actual filesystem is on another computer, and a mount point is created and an nfs share is mounted when the user logs in.

If you don't find the answer here, you might want to report your post and ask that the thread be moved to the Linux-Debian forum, where viewers will be more familiar with the Debian distribution.

Last edited by jschiwal; 03-31-2011 at 06:39 AM.
 
  


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 add local system user - useradd keeps saying user already exists ADeluiz Linux - Security 5 07-26-2013 04:17 PM
How to list user in Linux box, add an user to a group! steady_lfcfan Linux - Newbie 12 01-27-2013 02:14 PM
Create user add file with default password and force user to change it? Morgandy Linux - Newbie 3 02-02-2010 06:06 PM
samba - add user script - User account does not exist itzamecwp Linux - Server 2 01-18-2007 11:52 PM
How to automatically add smb user when unix user added Winanjaya Linux - Newbie 3 01-07-2007 12:17 PM


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