Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 454034 - Removing package-added users/groups on unmerge
Summary: Removing package-added users/groups on unmerge
Status: RESOLVED DUPLICATE of bug 53269
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Ebuild Support (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: PMS/EAPI
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-01-25 15:26 UTC by Roman Žilka
Modified: 2013-01-25 15:39 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Roman Žilka 2013-01-25 15:26:23 UTC
Some packages add new user accounts / groups on emerge. I think it would be nice if they removed these on unmerge. That way, the system would really become as clean as it had been before the emerge.

This deletion would include the accounts' homes and all superordinate directories created solely for those home dirs. E.g., lighttpd creates the user lighttpd with home=/var/www/localhost/htdocs. On unmerge, not just /var/www/localhost/htdocs should be removed, but the whole of
1. /var, if empty (except for the subdirs www/localhost/htdocs); if non-empty, then
2. /var/www, if empty (except for the subdirs localhost/htdocs); if non-empty, then
3. /var/www/localhost, if empty (except for the subdir htdocs); if non-empty, then
4. /var/www/localhost/htdocs, if empty.

This functionality should be taken care of easily by adding the homedir and its superordinates to the list of package-owned files (don't know if this happens purposefully now).

This would also take care of the SNAFU of a package unmerge deleting its own user's homedir. Take again lighttpd, which creates the account lighttpd with home=/var/www/localhost/htdocs, but also claims this dir as its own. On unmerge, it deletes this dir, if empty, but the account remains - homeless.

Reproducible: Always
Comment 1 Roman Žilka 2013-01-25 15:30:44 UTC
The account-removal feature could be a FEATURE then.
Comment 2 Zac Medico gentoo-dev 2013-01-25 15:39:01 UTC

*** This bug has been marked as a duplicate of bug 53269 ***