← Back to team overview

touch-packages team mailing list archive

[Bug 988072] Re: Can't remove user if they're not in /etc/passwd

 

I have the same issue.  In a school environment with LDAP authentication
on the LTSP server.  Every 3 months we change students in the lab.  Each
time they log in it creates an entry for them and then when they leave
we can't delete them.

Have a lightdm screen with 50+ names on it.  Awesome.

deluser will not remove them because they are not found in the
/etc/passwd file.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to accountsservice in Ubuntu.
https://bugs.launchpad.net/bugs/988072

Title:
  Can't remove user if they're not in /etc/passwd

Status in “accountsservice” package in Ubuntu:
  Confirmed

Bug description:
  Thanks to nss, there are many ways for a user account to exist.

  If you have user accounts authenticated with LDAP (say), and use nss
  tables other than passwd to store user information, then you find that
  the system automatically creates an entry in the user account database
  on login. This is handy: it means the user gets listed by lightdm in
  the greeter, for example, and things like background and keyboard
  prefs can be known to the greeter. It's all good.

  However, these users cannot be deleted. If you use the accounts-daemon
  from the control center to remove them, you get this error:

  Failed to delete user
  GDBus.Error:org.freedesktop.Accounts.Error.Failed: running '/usr/sbin/userdel' failed: /usr/sbin/userdel returned an error (1): userdel: cannot remove entry 'tbushnell' from /etc/passwd

  And alas, the user then stays in the system database.

  Please make it possible to remove users from the system database even
  if deluser and userdel don't work on them.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/accountsservice/+bug/988072/+subscriptions