Sent emails in stats are wrong and not been reset

sis.argentina

Verified User
Joined
Nov 8, 2006
Messages
24
Location
Mendoza, Argentina
Hi, I have a problem with a server, the count of delivery emails in CMD_SHOW_USER?user=xxxx are wrong, and they are not being reseted at the end of the day, DirectAdmin keep adding day after day the sent emails to the /usr/local/directadmin/data/users/xxxx/user.usage file

I try this:
  • update exim
  • update all with custombuild
  • update all in CentOS with "yum update"

Thanks for your help.
 
Last edited:
Hello,

Is crontab running on your server?

Code:
ps aux | grep crond

and

Code:
cat /var/log/cron | grep dataskq

Note, if you need some experienced hands to do the job on your server, you might want to hire somebody from these forums, and me for example of course.
 
Dear zEitEr, cron is running:

Code:
# ps aux | grep crond

root      3431  0.0  0.0   4184   772 pts/0    S+   10:34   0:00 grep crond
root      3694  0.0  0.0   5296  1112 ?        Ss   Sep29   0:05 crond
root     18006  0.0  0.0   5876  1516 ?        S    10:01   0:00 crond

And:

Code:
# cat /var/log/cron | grep dataskq

[...]
Oct 18 10:29:01 server11 crond[622]: (root) CMD (/usr/local/directadmin/dataskq)
Oct 18 10:30:01 server11 crond[1094]: (root) CMD (/usr/local/directadmin/dataskq)
Oct 18 10:31:01 server11 crond[1724]: (root) CMD (/usr/local/directadmin/dataskq)
Oct 18 10:32:01 server11 crond[2157]: (root) CMD (/usr/local/directadmin/dataskq)
Oct 18 10:33:01 server11 crond[2695]: (root) CMD (/usr/local/directadmin/dataskq)
Oct 18 10:34:01 server11 crond[3240]: (root) CMD (/usr/local/directadmin/dataskq)
 
That must be a bug, I guess and John should take a look at it. I'm not using the feature, I use customized exim.pl with enabled hourly limits.
 
Would just clearing/emptying the /etc/virtual/usage/<userfile> be a temporary fix, until its actually claimed to be a bug?
 
Hello,

1) Everything in the user.usage is a monthly usage. It's all days combined.
It's counted by adding up all of the emails send in
/etc/virtual/usage/user.bytes

Note that duplicate message ID's are ignored.

2) The daily limits (triggered with email notifications to everyone) are done with:
/etc/virtual/usage/user

and are triggered when the size of the file exceeds the limit.

The actual cause of the size of the file can vary, and can be larger than the number of emails sent in the user.bytes file due to the fact the duplciate ID numbers are not removed for this case. (it's only so smart, but scanning for duplciate ID numbers before adding the byte to the "user" file woud take far too much cpu to do it for each message).

4) The limit in DA for email sends is a per-daily limit, but as mentioned in #1, the usage is the total number for the entire month.

3) If you have the lastest version of DA, you can see the daily usage (as counted in the user.bytes file) by going to:
Admin Level -> Show All Users -> user -> Bandwidth [Details].

The email info is in the far right column.


Again, the logged usage (user.bytes) in DA may be slightly different than the numbers reportd by the "user" file, due to the lack of duplicate ID checks.

Duplicate IDs can be caused by things such as message delivery retries.. forwarders sending to multiple IDs (which actually deserves the multiple send-billing anyway, since it's uses more bandwidth), etc..

John
 
Back
Top