disk quotas: orphan files after user deletion

When deleting a website or a user on a site, they still remain in /etc/webmin/mailboxes/maildircache/

Example:

-rw-r--r-- 1        508 example        0 Feb 13 23:39 _home_example_homes_someguy_Maildir_.Junk

May seem small until you realize that this is the last remnant of the deleted user and is the reason that deleted users still show up under "Webmin: Disk Quotas"! Get rid of their orphan files there, and voila - no more "User #508" in the Disk Quotas section!

Status: 
Closed (fixed)

Comments

Thanks for pointing this out - this will be fixed in the 4.00 Virtualmin release.

Excellent. Also laughed when I saw the "4.00". Yeah, there certainly has been enough fixes recently to warrant a version bump, hehe! ;)

A small update, after I checked on a production system (not dev system) where things had been in use for a bit longer:

Use "find / -uid 616" to find all orphaned files for user 616 (as an example).

I discovered that there are other orphaned files when deleting users.

Mainly: /tmp

-rw-------  1  616  592 192512 Feb 10 19:19 clamav-c823d3912a298bffdb9b03988250e070
-rw-------  1  642  605      0 Feb 15 00:37 clamwrapper.12757
-rw-------  1  640  605      0 Feb 14 22:21 clamwrapper.8806
-rw-------  1  640  605      0 Feb 14 22:22 clamwrapper.8833
-rw-------  1  616  592      0 Feb 10 19:19 .spamassassin15053O9inUAtmp
-rw-------  1  616  592      0 Feb 10 19:20 .spamassassin151023hRHtztmp
-rw-------  1  643  606      0 Feb 15 03:53 .spamassassin1517tZ7AnYtmp
-rw-------  1  643  606      0 Feb 15 03:58 .spamassassin1585pCuRVNtmp
-rw-------  1  616  592      0 Feb 10 19:41 .spamassassin16135z74E60tmp
-rw-------  1  616  592      0 Feb 10 19:44 .spamassassin16264G64XQgtmp
-rw-------  1  640  605      0 Feb 14 12:15 .spamassassin21028KlRwFytmp
-rw-------  1  640  605      0 Feb 14 12:20 .spamassassin2111927R8xKtmp
-rw-------  1  640  605      0 Feb 14 20:49 .spamassassin6341FVmzHztmp
-rw-------  1  640  605      0 Feb 14 20:51 .spamassassin64139QJjLYtmp

And of course: /var/log/virtualmin/[domain].gz (which I already reported earlier and which you already fixed: https://www.virtualmin.com/node/25460)

And finally: /var/spool/mail:

-rw-rw---- 1  643 mail    0 Feb 15 01:01 bleh
-rw-rw---- 1  643 mail    0 Feb 15 03:35 bleh2
-rw-rw---- 1  500 mail    0 Jan 26 15:21 BOGUS.foo.QtC
-rw------- 1  665 mail    0 Feb 19 07:42 BOGUS.test.com._tC
-rw------- 1 root root  160 Feb 15 00:36 root
-rw------- 1  660 mail    0 Feb 18 06:40 test.example.com
-rw-rw---- 1  630 mail    0 Feb 12 19:54 webmin

After cleaning up these additional locations, even my production systems got rid of all orphan users from Disk Quotas. :)

Thanks - I will include deletion of those files in /tmp in the next release.

The next release will be 3.99, but we have branched that already. So this specific fix will go into 4.00.

Ahh got it. Excellent. :)

Automatically closed -- issue fixed for 2 weeks with no activity.