Force diskusage to refresh. HOW?

Hi,

I’ve just started using Cyberpanel for two weeks and already ran in to this issue a few times. Client runs out of diskspace, I make the package bigger of move them to a bigger package and they have to wait a full day for it to take effect.
This is not user friendly. How can I force a refresh?

I’m just going to leave this here for anyone who runs in to this in the future (and I know you will, because I’ve seen a lot of these questions and no one seems to know the answer)

This is what I ran to manually refresh the usage and remove the enforcement. Run this in the CLI:

/usr/local/CyberCP/bin/python /usr/local/CyberCP/IncBackups/IncScheduler.py CalculateAndUpdateDiskUsage

/usr/local/CyberCP/bin/python /usr/local/CyberCP/IncBackups/IncScheduler.py checkDiskUsage

Now the disk usage show the correct values. Check if you can upload media in WP. If not, the limit enforcement is still there. Run this last command: (replace {{website}} with the folder name of the website)

chattr -R -i /home/{{website}}

I hope this helps someone in the future. I’d be great if this runs automatically on changing the package, right?

2 Likes

During installation cyberpanel adds a cronjob */15 * * * * /usr/local/CyberCP/bin/python /usr/local/CyberCP/IncBackups/IncScheduler.py CalculateAndUpdateDiskUsage that runs every 15th minute.

Always when you encounter this issue try and upgrade and reboot. Everything will be ok.

I have never experience this. Kindly check from crontab -e if you have the above cronjob

"Just reboot the server " is not really professional is it…? There are dozens of websites running on the server.

We installed this server two weeks ago, but that cron is not there.
I’m going to add it myself, but I’m a bit disappointed in Cyberpanel. This should be ran automatically when changing packages.

How long does a reboot take for you server? It should not take more than a minute even if its a dedicated server. You can always restart individual services i.e lscpd, lsws etc

You probably forked the source code because that step cannot be skipped

There are a dozen of cron jobs, but not that one… didnt fork it, used the recommended instructions.
Everthing else works fine, backups, ssl, email. Also the disk usage is updated every night, just not every 15 min.

Sorry i just checked my own fork so maybe the original’s cronjob runs once a day. Well the source code is open source to a degree or whatever license they use it is not public. Just change what you need.

This topic was automatically closed 3 hours after the last reply. New replies are no longer allowed.