Account over quota issue

boing

Member
May 4, 2015
12
0
1
United States
cPanel Access Level
Root Administrator
Hello,

Pre-diagnosis: I've already run:
/scripts/fixquotas

On cpanel's quota page:
Home »Account Information »Show Accounts Over QuotaDocumentation

I've got an account listed as:
12521.73 MB

For files, I can see:
[email protected] [/home]# du -sm /home/{username}
5765 /home/***

and under /var/lib/mysql I see about 1 GB worth of databases that belong to that user. Heck, check this out:
[email protected] [/var/lib/mysql]# du -sm /var/lib/mysql
1308 /var/lib/mysql

So even if ALL of those databases belong to that user (they don't), we're still at about 7 GB. Nowhere near the ~12.5GB cpanel is reporting. Where else should I be looking for files at?

Thanks!
 

boing

Member
May 4, 2015
12
0
1
United States
cPanel Access Level
Root Administrator
Any other ideas? I've got several accounts that are suddenly reporting at/near quota that I cannot account for when I inspect the directories mentioned above. I happen to be picking on the one mentioned above, but several are in that boat. (Some accounts I've had to artificially inflate, so to speak.)
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello,

It's possible files owned by this user exist outside it's home directory. You can obtain a list of files owned by the user with commands such as:

Code:
id username
find / -uid $UIDNUMBER > /root/username.output
Thank you.
 

boing

Member
May 4, 2015
12
0
1
United States
cPanel Access Level
Root Administrator
Hello,

Still no luck. (Thanks for the tip though!)

Even after that, and not even narrowing down some of these directories to just that user, I've only got:
Code:
[email protected] [~]# du -sm /tmp/ /var/spool/mail/ /etc/vfilters/ /etc/vdomainaliases/ /etc/valiases/ /home/username/
1       /tmp/
1       /var/spool/mail/
1       /etc/vfilters/
1       /etc/vdomainaliases/
1       /etc/valiases/
5766    /home/username/
[email protected] [~]#
(I did exclude things like /home/virtfs/*, which is correct to do, ya?)

Yet cpanel is reporting 12522.11 MB used.
 

akust0m

Well-Known Member
Feb 19, 2016
72
4
58
Melbourne
cPanel Access Level
Root Administrator
Hey, not sure if it will help. But just in case the usage is incorrectly reported, you could try clearing and building the disk usage cache for this user to make sure?

cpapi2 --user=username DiskUsage clearcache
cpapi2 --user=username DiskUsage buildcache
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello,

Feel free to open a support ticket using the link in my signature so we can take a closer look.

Thank you.
 

boing

Member
May 4, 2015
12
0
1
United States
cPanel Access Level
Root Administrator
Hello akust0m,

Hrm... all sorts of errors with that. Thoughts?

Code:
[email protected] [~]# cpapi2 --user=MyUserName DiskUsage clearcache
[2017-10-27 09:34:17 -0700] warn [cpanel] Failed to write â/home/MyUserName/.cpanel/caches/filesys/~â
                                                                                                        Cpanel::Filesys::__ANON__(Cpanel::Exception::IO::WriteError=HASH(0x40ef000)) called at /usr/local/cpanel/3rdparty/perl/524/lib64/perl5/cpanel_lib/Try/Tiny.pm line 119
        Try::Tiny::try(CODE(0x40ee958), Try::Tiny::Catch=REF(0x1a01cd8)) called at /usr/local/cpanel/Cpanel/Filesys.pm line 121
        Cpanel::Filesys::disk_space_check("/", 1) called at cpanel.pl line 772
        cpanel::cpanel::script("cpanel::cpanel", "--json-fast-connect", "--stdin") called at cpanel.pl line 272
[2017-10-27 09:34:17 -0700] warn [cpanel] Failed to write â/home/MyUserName/.cpanel/caches/filesys/~home~MyUserNameâ
                                                                                                                        Cpanel::Filesys::__ANON__(Cpanel::Exception::IO::WriteError=HASH(0x40eedd8)) called at /usr/local/cpanel/3rdparty/perl/524/lib64/perl5/cpanel_lib/Try/Tiny.pm line 119
        Try::Tiny::try(CODE(0x40ef048), Try::Tiny::Catch=REF(0x40ee838)) called at /usr/local/cpanel/Cpanel/Filesys.pm line 121
        Cpanel::Filesys::disk_space_check("/home/MyUserName", 1) called at cpanel.pl line 773
        cpanel::cpanel::script("cpanel::cpanel", "--json-fast-connect", "--stdin") called at cpanel.pl line 272
---
cpanelresult:
  apiversion: 2
  data:
    -
      status: 1
      statusmsg: cache cleared
  event:
    result: 1
  func: clearcache
  module: DiskUsage
[email protected] [~]#
The buildcache produced similar errors and cpanel results. I ran both commands, then ran both again in case something was corrupt the first time through. (and of course replaced MyUserName with the actual username in the snippet above)

After doing so, cpanel still reports this user as using ~2.5x more data than it appears to be using. I then ran:
/scripts/fixquotas

And still the same, cpanel still reports this user as using ~2.5x more data than it appears to be using.