Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Audit mail usage

Discussion in 'E-mail Discussion' started by Robert Spencer, Feb 10, 2016.

  1. Robert Spencer

    Robert Spencer Registered

    Joined:
    Feb 10, 2016
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    South Africa
    cPanel Access Level:
    Root Administrator
    I'm busy writing a script to audit a specific domains email usage.

    I can see who the top bandwidth users, but noticed a discrepancy. In cPanel for the 3rd of February the entire domain used 471.23 MB via IMAP.

    Yet in the logs:

    Code:
    # zgrep "^Feb  3" /var/log/maillog-20160207.gz | awk '/dovecot: imap/ && /example.com/ && /bytes=/ {print $NF}' | sed -e 's/bytes=//' -e 's/\// /' | awk '{sum+=$1+$2} END {print sum}'
    2336787930
    That's almost a 2GB difference.

    Checking the 4th and there's about a 700MB difference with the logs being higher.

    5th there's about a 800MB difference with the logs being higher.

    What am I misunderstanding or is there something wrong?
     
  2. cPanelMichael

    cPanelMichael Technical Support Community Manager
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    45,141
    Likes Received:
    1,932
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Twitter:
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice