SOLVED Backup failure disk usage update

coursevector

Well-Known Member
Feb 23, 2015
154
19
68
cPanel Access Level
Root Administrator
When a "Disk usage warning" email is sent out, how old is the disk usage data included in the email? I know disk usage is typically only updated once a day, but is it updated right before sending the email? I ask because if a disk is say 60% full and an automated cPanel backup occurs, disk usage grows up to say 85% (or more?) triggering an email. But what I'm wondering is, is that 85% that is reported the peak or old information from up to 24 hours ago? Could it be actually peaking at say 90% or more and the email is just reporting what data it just happened to have on hand?

I assume it's updating the data before reporting it, but my colleague thinks otherwise so I'm trying to confirm when the data is actually updated before the email notification is sent out. Thanks!
 

cPanelLauren

Product Owner
Staff member
Nov 14, 2017
13,295
1,273
313
Houston
The Disk Usage email is only sent once a day but it is checked with chksrvd more frequently (every 5 minutes to be precise) - you can see the check itself and it's results in /var/log/chksrvd.log

Mine for example shows the following:

Code:
[[email protected] logs]# grep -i disk /var/log/chkservd.log |tail -5
[2020-01-08 12:39:11 -0600] Disk check .... / (/) [37.23%] ... /tmp (/tmp) [37.23%] ... /var/tmp (/var/tmp) [37.23%] ... {status:ok} ... Done
[2020-01-08 12:44:13 -0600] Disk check .... / (/) [37.23%] ... /tmp (/tmp) [37.23%] ... /var/tmp (/var/tmp) [37.23%] ... {status:ok} ... Done
[2020-01-08 12:49:15 -0600] Disk check .... /var/tmp (/var/tmp) [37.23%] ... / (/) [37.23%] ... /tmp (/tmp) [37.23%] ... {status:ok} ... Done
[2020-01-08 12:54:16 -0600] Disk check .... / (/) [37.23%] ... /tmp (/tmp) [37.23%] ... /var/tmp (/var/tmp) [37.23%] ... {status:ok} ... Done
[2020-01-08 12:59:18 -0600] Disk check .... /var/tmp (/var/tmp) [37.23%] ... / (/) [37.23%] ... /tmp (/tmp) [37.23%] ... {status:ok} ... Done
The notification will be sent at the first threshold breach past 24 hours since the last notification was sent. So if the notification was sent at 1am the previous day and at 1am today you do not reach the threshold (85% in this example) you won't get a notification.

If the notification was sent previously at 1am and at 12:45am the next day the threshold is reached, you will not get a notification unless it continues to be reached at 1am.

Please let me know if that makes sense/helps.