[Valvula] problem with mod-mquota "no match is found"

Francis Brosnan Blázquez francis.brosnan en aspl.es
Jue Nov 9 19:12:33 CET 2017


Hello Xavier.

Looking at your description everything is fine. I created a regression
test (test_07a) with, exactly, your configuration:

https://github.com/ASPLes/valvula/commit/fec960341040ed51f57859d5802f1f90c906c019

...and I was hoping to find a bug but it works for me:


                >> ./test_01 --run-test=test_07a --debug
                [....]
                Test 07-a: detect period right at 16:46:00 -> day
                quota..
                (proc:0) [msg] (mod-mquota.c:116)
                mod_mquota_get_current_period (current_minute=46,
                current_hour=16) :: axl_list_length
                (__mod_mquota_limits) = 2
                (proc:0) [msg] (mod-mquota.c:130) Checking now is 16:46
                (start 09:00 - end 21:00)
                (proc:0) [msg] (mod-mquota.c:96) Selecting sending
                mquota period with label [day quota] limits g: 750, h:
                600, m: 10
                Test 07-a: detect period right at 08:16:00 -> day quota
                (by selecting first)..
                (proc:0) [msg] (mod-mquota.c:116)
                mod_mquota_get_current_period (current_minute=16,
                current_hour=8) :: axl_list_length (__mod_mquota_limits)
                = 2
                (proc:0) [msg] (mod-mquota.c:130) Checking now is 08:16
                (start 09:00 - end 21:00)
                (proc:0) [msg] (mod-mquota.c:130) Checking now is 08:16
                (start 21:00 - end 07:00)
                (proc:0) [msg] (mod-mquota.c:164) No period matched,
                checking for no match configuration..
                (proc:0) [msg] (mod-mquota.c:177) No match found,
                reporting first period (current_hour=8,
                current_minute=16): day quota (hour-limit=600,
                minute-limit=10)
                (proc:0) [msg] (mod-mquota.c:96) Selecting sending
                mquota period with label [day quota] limits g: 750, h:
                600, m: 10
                Test 07-a: detect period right at 23:12:00 -> night
                quota (by direct selection)..
                (proc:0) [msg] (mod-mquota.c:116)
                mod_mquota_get_current_period (current_minute=12,
                current_hour=23) :: axl_list_length
                (__mod_mquota_limits) = 2
                

I decided to test more cases and add more debug information (that's why
you see more output), but essentially, same code.

Maybe you are using an old valvula version that has a bug :-? Which
version are you running (valvulad --version)?

Anyway, I've just compiled latest (if you are using packages). If you
are building from source, be sure you are using latest:


                >> valvulad --version
                1.0.8.b351

Best Regards.





El jue, 09-11-2017 a las 15:58 +0000, LAURE Xavier escribió:
>  
> 
> Hello,
> 
>  
> 
> I’m having a problem with time period in mod-quota.
> 
>  
> 
> I’m using 2 time periods:
> 
>  
> 
> <limit label='day quota' from='9:00' to='21:00' status='full'
> minute-limit='10' hour-limit='600' global-limit='750'
> domain-minute-limit='-1' domain-hour-limit='-1'
> domain-global-limit='-1' />
> 
> <limit label='night quota' from='21:00' to='9:00' status='full'
> minute-limit='10' hour-limit='300' global-limit='300'
> domain-minute-limit='100' domain-hour-limit='300'
> domain-global-limit='2000' />
> 
>  
> 
> But in my syslog file I can read that valvula can’t find a match
> period …  
> 
>> 
> Nov  9 16:46:02 SMTPSv2 valvulad[1630]: info: Checking now is 16:46
> (start 21:00 - end 09:00)
> 
> Nov  9 16:46:02 SMTPSv2 valvulad[1630]: info: No period matched,
> checking for no match configuration..
> 
> Nov  9 16:46:02 SMTPSv2 valvulad[1630]: info: Reporting first period:
> 0x21694a0
> 
> Nov  9 16:46:02 SMTPSv2 valvulad[1630]: info: Selecting sending mquota
> period with label [night quota] limits g: 300, h: 300, m: 10
> 
>> 
>  
> 
> The configuration is so simple that I can’t find any problem …
> certainly I’m make a mistake … bur where can I’m looking for ?
> 
>  
> 
> Thank you
> 
>  
> 
> Regards
> 
>  
> 
> xavier
> 
>  
> 
> ----------------------
> 
>        Laure
> 
>   CNRS- Délégation Centre Limousin Poitou-Charentes
> 
>   Campus CNRS d’Orléans
> 
>   3E Avenue de la recherche scientifique 
> 
>   Tel : 0238257617
> 
> -----------------------------------
> 
>  
> 
>  
> 
> 
> 
> _______________________________________________
> Valvula mailing list
> Valvula en lists.aspl.es
> http://lists.aspl.es/cgi-bin/mailman/listinfo/valvula


-- 
Francis Brosnan Blázquez  -  ASPL
http://www.asplhosting.com/
http://www.aspl.es/
https://twitter.com/aspl_es
https://twitter.com/asplhosting
https://twitter.com/francisbrosnanb
https://es.linkedin.com/in/francis-brosnan-blázquez-1353a218

91 134 14 22 - 91 134 14 45 - 91 116 07 57
Av. Juan Carlos I 13, 2ºC, Torre Garena
28806 - Alcalá de Henares (España)

AVISO LEGAL
 
En virtud de lo dispuesto en la Ley Orgánica 15/1999, de 13 de
diciembre, de Protección de Datos de Carácter Personal, le informamos de
que sus datos de carácter personal, recogidos de fuentes accesibles al
público o datos que usted nos ha facilitado previamente, proceden de
bases de datos propiedad de Advanced Software Production Line, S.L.
(ASPL).
 
ASPL garantiza que los datos serán tratados con la finalidad de mantener
las oportunas relaciones comerciales o promocionales con usted o la
entidad que usted representa. No obstante, usted puede ejercitar sus
derechos de acceso, rectificación, cancelación y oposición dispuestos en
la mencionada Ley Orgánica, notificándolo por escrito a ASPL -
Protección Datos, Av. Juan Carlos I 13, 2ºC, Alcalá de Henares
(Madrid).
------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: <http://lists.aspl.es/pipermail/valvula/attachments/20171109/461ec02f/attachment.html>


Más información sobre la lista de distribución Valvula