After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 515677 - user admin can't create a account if the home folder already exist
user admin can't create a account if the home folder already exist
Status: RESOLVED FIXED
Product: gnome-system-tools
Classification: Deprecated
Component: users-admin
2.21.x
Other All
: Normal normal
: 2.30
Assigned To: Carlos Garnacho
Carlos Garnacho
Depends on:
Blocks:
 
 
Reported: 2008-02-11 03:31 UTC by Oxmosys
Modified: 2010-01-11 21:07 UTC
See Also:
GNOME target: ---
GNOME version: 2.21/2.22


Attachments
Screenshot (106.06 KB, image/png)
2008-02-11 03:32 UTC, Oxmosys
Details

Description Oxmosys 2008-02-11 03:31:46 UTC
Please describe the problem:
If user-admin try to create a user account when the /home directory for that account already exist ( even if the user is deleted ), it fails and give a error message "Home directory already exist".

Assuming that user-admin does not delete home folder for previous users, I think that it could be a improvement to user-admins to make it ask "Home directory already exist but no user account is actually associated with that folder, overwriting that folder will erase all file from the previous user. Do you want to overwrite that folder?"

Steps to reproduce:
1. Open user-admins and create the user test, close user-admins
2. Make sure that the /home/test folder has been created
3. Open user-admins and delete the user test, close user-admins
4. Open user-admins and create the user test


Actual results:
user-admins show a error message about the existing /home/test folder

Expected results:
user-admins should give choice to the user about this problem.

Does this happen every time?
yes

Other information:
Comment 1 Oxmosys 2008-02-11 03:32:20 UTC
Created attachment 104889 [details]
Screenshot
Comment 2 Charlie Kravetz 2008-12-13 00:27:52 UTC
I can confirm that this bug is still present in Xubuntu 9.04 and gnome-system-tools version 2.22.1-0ubuntu2.

After installing Xubuntu 9.04 in an existing partition and keeping the /home partition so as not to lose important documents, I can not add any user that exists in the /home directory. I do get an error message:
"Home directory already exists
Please enter a different home directory path"

The $USER exists in the /home directory, but not in the system. The only way to add the user is change the existing /home/$USER to a different name, add my user, then copy the existing /home/$USER files to that user directory. This seems like a long way around to avoid losing my data.

Checking permissions, all files are currently owned by UID 1001, and the new user is being added as the second user on the system, UID 1001 and GID charlie.

The $USER being added is "charlie" and the group "charlie" with GID 1001 has been added.

If I can help with any other information or logs, please email me.

Comment 3 Milan Bouchet-Valat 2009-12-13 21:07:01 UTC
In 2.29.1, we accept to create the user, but don't change the permissions of the folder. This means everything will be right when UID is the same, but that nothing will work if that's not the case.

We need support in the system-tools-backends for changing file owner if wanted. I'll try to do so for 2.30.