The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Disk Quota Email Notifications

Discussion in 'E-mail Discussions' started by pfmartin, Nov 25, 2003.

  1. pfmartin

    pfmartin Well-Known Member

    Joined:
    Aug 18, 2001
    Messages:
    167
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Earth
    Can anyone tell me if the Tweak Settings option to email users when their disk quota or email disk quota is being reached actually sends emails?

    I have customers complain that they never receive any type of warning before running out of disk space.

    Is an email being sent? If so, how does it work? Does it wait for 80% like the bandwidth message? Does it email to the contact email or to the default catch all account?

    if anyone has any insights into this, I would really appreciate any feedback you can give me.

    Thank you!
     
  2. pfmartin

    pfmartin Well-Known Member

    Joined:
    Aug 18, 2001
    Messages:
    167
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Earth
    -bump-

    I really think this would be nice for everyone to know.
     
  3. Tom Pyles

    Tom Pyles Well-Known Member

    Joined:
    Apr 26, 2002
    Messages:
    254
    Likes Received:
    0
    Trophy Points:
    16
    Have you checked to see if they have updated their e-mail address in their CPanel? It should also be viewable by you when logged into WHM and viewing your accounts list. I've never had a problem (not that I've been made aware) receiving these warnings when their e-mail is listed within CPanel.
     
  4. pfmartin

    pfmartin Well-Known Member

    Joined:
    Aug 18, 2001
    Messages:
    167
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Earth
    Their contact email address is correct, yet no emails are sent. It used to work, now it does not. Can anyone confirm if theirs is working? I am running the latest STABLE build.

    Thanks.
     
  5. pfmartin

    pfmartin Well-Known Member

    Joined:
    Aug 18, 2001
    Messages:
    167
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Earth
    After further review, this is what I found:

    There is a file called /var/cpanel/quotewarned

    This file has all the accounts and email accounts that [have been warned] of quota issues. My guess is that this is here so that users don't get endless streams of emails saying quota is exceeded.

    The /scripts/quotawarn file reads the /var/cpanel/quotawarned file to determine if an email should be sent or not. If the user or email account is in the file, it does NOT send the email.

    As far as I can tell, once a user is added to the /var/cpanel/quotawarned file, they never get removed. This means that users will only get 1 notice of quota issues. After that, there are no further notices sent.

    So it seems that the quota warning emails work up to a certain point. That is, once an email is sent to a user regarding quota issues, no further emails are sent, ever...

    Still looking for someone to help me out with this. Maybe we can figure out what to do. So far, I am considering deleting the /var/cpanel/quotawarned file one per week so that the system checks quotas again. Any suggestions?
     
  6. pfmartin

    pfmartin Well-Known Member

    Joined:
    Aug 18, 2001
    Messages:
    167
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Earth
    Fix to send emails nightly if user quota usage is "warning" level (80-90%)

    Modify quotacheck as follows:

    Code:
    147c147
    <             if ($WARNED{"$euser\@$domain"} ne "warn") {
    ---
    >             if ($WARNED{"$euser\@$domain"} == "warn") {
    173c173
    <       if ($WARNED{$user} ne "warn") {
    ---
    >       if ($WARNED{$user} == "warn") {
    
    This will keep sending emails as long as the quota level is 'warn'. Once it reaches critical level, it will only send 1 email. This makes sense since you don't really want to send emails when quota is at critical levels.

    I hope this helps and/or becomes standard in cpanel.

    Thanks.
     
  7. majoosh

    majoosh Well-Known Member

    Joined:
    Feb 18, 2006
    Messages:
    97
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    India
    How often is the quota checked ? What will happen if the bandwidth/disk usage exceeds in one day when it was it 70% ?

    Regards
    Majoo
     
Loading...

Share This Page