Hello,

I'm playing with cluebringer 2.0.11 and I'm having some problems with
Quota module. Platform is CentOS 5, PostgreSQL 8.4 and cluebringer 2.0.11RC1


In short, I've created setup where one user should be able to send 5
email per hour, i.e.

---8<---
SELECT quotaslimitsid AS qid,trackkey,to_timestamp(lastupdate) AS
lastupdate,counter AS c FROM quotas_tracking;

 qid |           trackkey            |       lastupdate       |   c
-----+-------------------------------+------------------------+--------
   7 | SASLUsername:adislinux.org.ba | 2010-10-05 14:41:06+02 | 8.0571


SELECT * FROM quotas_limits;

 id | quotasid |     type     | counterlimit | comment | disabled
----+----------+--------------+--------------+---------+----------
  7 |        6 | MessageCount |            5 |         |        0


SELECT id,policyid,name,track,period,verdict FROM quotas;

 id | policyid |       name        |    track     | period | verdict
----+----------+-------------------+--------------+--------+---------
  6 |        7 | LimitOutboundMail | SASLUsername |   3600 | REJECT
--->8---


The problem is that "counter" column always grows. It doesn't get set to
0 after 3600 seconds without mail, nor it is lowered when I try to send
email during 3600 seconds after last email. Notice 8.0571 above. It
shouldn't get higher values than 6m right?

Also, I've calculated $currentCounter from "Quotas.pm" by hand, and it
should get lower value.
  $currentCounter = ( 1 - ($elapsedTime / $quota->{'Period'}) ) *
  $qtrack->{'Counter'};

After elapsed period, I'm able to send only one email, 1.0 is added to
counter, and after that, I'm not able to send additional emails.

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Users mailing list
[email protected]
http://lists.policyd.org/mailman/listinfo/users

Reply via email to