Re: sqlcounters for traffic

2008-09-09 Thread Alexandre Chapellon
Looking at the source of rlm_sqlcounter i saw that when a users tries to conect at a time close to the next reset time, the value of the check-item for the next cycle is added to the reply item. I'd like to avoid this behaviour for **some** of my users. Indeed I want to use counters to count traffi

Re: sqlcounters for traffic

2008-09-09 Thread tnt
reset parameter controls value of %b. Ivan Kalik Kalik Informatika ISP Dana 9/9/2008, "Alexandre Chapellon" <[EMAIL PROTECTED]> piše: >so what's the use of the reset parameter if th sql query is managing it >all by its own? > >Alexandre Chapellon a écrit : >> >> >> [EMAIL PROTECTED] a écrit : >

Re: sqlcounters for traffic

2008-09-09 Thread Alexandre Chapellon
so what's the use of the reset parameter if th sql query is managing it all by its own? Alexandre Chapellon a écrit : > > > [EMAIL PROTECTED] a écrit : >>> here is the counter definition: >>> sqlcounter bytesQuota { >>>counter-name = traffic_quota >>>check-name = Max-Traffic >>>

Re: sqlcounters for traffic

2008-09-09 Thread Alexandre Chapellon
[EMAIL PROTECTED] a écrit : >> here is the counter definition: >> sqlcounter bytesQuota { >>counter-name = traffic_quota >>check-name = Max-Traffic >>reply-name = Tmp-Integer-0 >>sqlmod-inst = mysqldb >>key = User-Name >>reset = hourly >>que

Re: sqlcounters for traffic

2008-09-09 Thread tnt
>here is the counter definition: >sqlcounter bytesQuota { >counter-name = traffic_quota >check-name = Max-Traffic >reply-name = Tmp-Integer-0 >sqlmod-inst = mysqldb >key = User-Name >reset = hourly >query = "SELECT SUM(acctinputoctets + acctou

Re: sqlcounters for traffic

2008-09-09 Thread Alexandre Chapellon
[EMAIL PROTECTED] a écrit : >> Good it's sent in the reply to the nas! Thx >> But the sqlcounter i setup was supposed to reset every hours , but >> apparently doesn't... >> Where can i take a look to find out why? >> > > Check the sql query definition and value of reset in counter.conf. >

Re: sqlcounters for traffic

2008-09-09 Thread tnt
>Good it's sent in the reply to the nas! Thx >But the sqlcounter i setup was supposed to reset every hours , but >apparently doesn't... >Where can i take a look to find out why? Check the sql query definition and value of reset in counter.conf. Ivan Kalik Kalik Informatika ISP - List info/subscr

Re: sqlcounters for traffic

2008-09-09 Thread Alexandre Chapellon
Good it's sent in the reply to the nas! Thx But the sqlcounter i setup was supposed to reset every hours , but apparently doesn't... Where can i take a look to find out why? Is it supposed to update the database to reset counters (which seems a bad solution to me) or does freeradius maintain separa

Re: sqlcounters for traffic

2008-09-05 Thread Alan DeKok
Alexandre Chapellon wrote: > Here is the full debug outputed during the auth query/reply ... > rlm_sqlcounter: Sent Reply-Item for user scott, > Type=Session-Traffic-Limit, value=12694 ... > Sending Access-Accept of id 201 to 127.0.0.1 port 37792 > Session-Traffic-Limit = "" That's the prob

Re: sqlcounters for traffic

2008-09-05 Thread Alexandre Chapellon
[EMAIL PROTECTED] a écrit : >> My first problem is that the Session-Traffic-Limit (from the redback >> dictionnary) is not returned. I can't see it neither in the output of >> radtest nor with radsniff. >> Yet, looking at the output of radiusd -X i can see it's correctly >> understood by freeradi

Re: sqlcounters for traffic

2008-09-05 Thread Alexandre Chapellon
] > *On Behalf Of *Alexandre Chapellon > *Sent:* Samstag, 06. September 2008 01:53 > *To:* FreeRadius users mailing list > *Subject:* sqlcounters for traffic > > > > I want to se sqlcounters to count bytes transferred from clients so > that i manage quota. > Aiming

Re: sqlcounters for traffic

2008-09-05 Thread tnt
>My first problem is that the Session-Traffic-Limit (from the redback >dictionnary) is not returned. I can't see it neither in the output of >radtest nor with radsniff. >Yet, looking at the output of radiusd -X i can see it's correctly >understood by freeradius: > >rlm_sqlcounter: Check item is gre

RE: sqlcounters for traffic

2008-09-05 Thread Edvin Seferovic
? E:S From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] g] On Behalf Of Alexandre Chapellon Sent: Samstag, 06. September 2008 01:53 To: FreeRadius users mailing list Subject: sqlcounters for traffic I want to se sqlcounters to count bytes transferred from clients so that i manage quota. Aiming

sqlcounters for traffic

2008-09-05 Thread Alexandre Chapellon
I want to se sqlcounters to count bytes transferred from clients so that i manage quota. Aiming this i configured the following counter: sqlcounter bytesQuota { counter-name = traffic_quota check-name = Max-Traffic reply-name = Session-Traffic-Limit sqlmod-inst = my