Thanks. That took care of it. --Robert R. George
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ed H Sent: Monday, March 31, 2003 3:53 PM To: [EMAIL PROTECTED] Subject: Re: REPOST: rlm_sqlcounter not working... Hello Robert, Make sure you have a Max-Monthly-Session := 3600, for example (where 3600 is the time in seconds allowed per month) in your radgroupcheck or radcheck table. The same applies to the Max-All-Session and the Max-Daily-Session variables. Give it a shot and see if it works. Ed >From: "Robert R. George" <[EMAIL PROTECTED]> >Reply-To: [EMAIL PROTECTED] >To: <[EMAIL PROTECTED]> >Subject: REPOST: rlm_sqlcounter not working... >Date: Mon, 31 Mar 2003 00:05:06 -0800 > >I am trying to get the rlm_sqlcounter module working in >freeradius-0.8.1 and am have a bit of trouble. It appears that the >module is not querying the sql database... > >When running radius -X, I get the following: > >rlm_sqlcounter: Entering module authorize code >rlm_sqlcounter: Could not find Check item value pair > modcall[authorize]: module "allcounter" returns noop >rlm_sqlcounter: Entering module authorize code >rlm_sqlcounter: Could not find Check item value pair > modcall[authorize]: module "dailycounter" returns noop >rlm_sqlcounter: Entering module authorize code >rlm_sqlcounter: Could not find Check item value pair > modcall[authorize]: module "monthlycounter" returns noop > >The configuration directive for the modules are as follows: > >sqlcounter allcounter { > counter-name = Max-All-Session-Time > check-name = Max-All-Session > sqlmod-inst = sql > key = User-Name > reset = never > query = "SELECT SUM(AcctSessionTime) FROM radacct WHERE >UserName='%{%k}'" > } > >sqlcounter dailycounter { > counter-name = Daily-Session-Time > check-name = Max-Daily-Session > sqlmod-inst = sql > key = User-Name > reset = daily > query = "SELECT SUM(AcctSessionTime - GREATEST((%b - >UNIX_TIMESTAMP(AcctStartTime)), 0)) FROM radacct WHERE UserName='%{%k}' >AND UNIX_TIMESTAMP(AcctStartTime) + AcctSessionTime > '%b'" > } > >sqlcounter monthlycounter { > counter-name = Monthly-Session-Time > check-name = Max-Monthly-Session > sqlmod-inst = sql > key = User-Name > reset = monthly > query = "SELECT SUM(AcctSessionTime - GREATEST((%b - >UNIX_TIMESTAMP(AcctStartTime)), 0)) FROM radacct WHERE UserName='%{%k}' >AND UNIX_TIMESTAMP(AcctStartTime) + AcctSessionTime > '%b'" > } > > > --Robert R. George > > > >- >List info/subscribe/unsubscribe? See >http://www.freeradius.org/list/users.html _________________________________________________________________ - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
