users-admin lies about changing home directory for active users

Bug #484501 reported by Robert
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
GST
Confirmed
Undecided
Unassigned
gnome-system-tools (Ubuntu)
Triaged
Low
Unassigned

Bug Description

Binary package hint: gnome-system-tools

The user-admin tools allows you to change the home directory for a user in the advanced tab of user properties but when you close the tool it fails to update /etc/passwd! If it's not intended to work this option should be greyed out, otherwise it should work...

I encountered this after installing a fresh karmic on a two-user system with a separate /home partition (previously running karmic beta). I wanted to restore one of the old user accounts but had neglected to preserve the passwd files so thought I'd just create a new user with the same name. The tool complained that the home directory already existed for that user so I created it with a different home dir instead. Afterwards when I tried to change the home dir to what it should have been it appeared to work in the GUI but had no effect.

This whole faff could have been avoided if the tool gave me the option to use the existing home dir when re-creating the user (after all, I know what I'm doing).

Regards,

Robert

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

Thanks for the report. Are you able to modify any settings at all? Is your system up-to-date? I reckon this is a duplicate of bug 463353, which has been fixed recently.

About reusing an already existing home directory: you know what you're doing, but the program has to make sure 1) the directory is owned by the new user, and 2) if we change the permissions so that's the case, we don't break the home directory of another user, in case it's shared - and then, what to do? I'd like to get this fixed in the next release, but that's not so simple, as you can see.

Changed in gnome-system-tools (Ubuntu):
status: New → Incomplete
Revision history for this message
Robert (ubuntu-10-rmn30) wrote :

Sorry, this bug is not a duplicate of the cited bug. I just tried it in on fully updated karmic system and changing a user's home directory has no effect at all. Try it for yourself if you don't believe me!

Revision history for this message
Robert (ubuntu-10-rmn30) wrote :

P.S. I agree that setting the home directory to an existing directory is a dangerous thing to do and should not be done without a warning and a great deal of care. I could completely understand if you choose not to support this for that reason. Appearing to change it without actually doing anything is misleading and clearly a bug though. Just disable the option!

Revision history for this message
Robert (ubuntu-10-rmn30) wrote :

P.P.S. Yes I am able to make other changes: I changed my real name successfully, for example.

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

Thanks for the reply. I'm not able to reproduce the problem on my computer. Could you check that the command "sudo usermod -d [PATH TO HOMEDIR] [USER LOGIN]" works? If it does please follow the instructions for the too "users-admin" at https://wiki.ubuntu.com/DebuggingGnomeSystemTools.

Changed in gnome-system-tools (Ubuntu):
importance: Undecided → Low
Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

No news on that bug?

Revision history for this message
Robert (ubuntu-10-rmn30) wrote : Re: [Bug 484501] Re: users-admin lies about changing home directory

I think I've gotten to the bottom of it. I was surprised to find that
if i create a new user i can successfully change the home directory of
that user but that I was unable to change my own home directory or
that of another user who had a running process. This seems to be
because usermod will refuse to do so, complaining that the user is
logged in. That seems quite sensible so it seems that all that is
missing is for the GUI to report the error to the user in a sensible
fashion.

On 11 January 2010 20:21, Milan Bouchet-Valat <email address hidden> wrote:
> No news on that bug?
>
> --
> users-admin lies about changing home directory
> https://bugs.launchpad.net/bugs/484501
> You received this bug notification because you are a direct subscriber
> of the bug.
>

Revision history for this message
Milan Bouchet-Valat (nalimilan) wrote :

I see. The backends are not really good at reporting errors to the GUI, but we should simply block changing home dir for active users.

summary: - users-admin lies about changing home directory
+ users-admin lies about changing home directory for active users
Changed in gnome-system-tools (Ubuntu):
status: Incomplete → Fix Released
Changed in gst:
status: New → Confirmed
Changed in gnome-system-tools (Ubuntu):
status: Fix Released → Triaged
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.