Re: Freeradius accounting question

This is a discussion on Re: Freeradius accounting question within the FreeRADIUS Users forums, part of the Networking and Network Related category; Hi. I just resubscribed to the mailinglist and found that topic unanswered. You can accomplish that in two ways. One ...


Go Back   Usenet Forums > Networking and Network Related > FreeRADIUS Users

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 05-10-2005
Marcin Jessa
 
Posts: n/a
Default Re: Freeradius accounting question

Hi.

I just resubscribed to the mailinglist and found that topic unanswered.
You can accomplish that in two ways. One is with counter module and one with SQL which uses sqlcounter module.
The sqlcounter needs the experimental modules to be compiled in.
I use MySQL to store my users's info so for me the natural way was to use the sqlcounter module.
Follow this howto http://www.lh.freeradius.org/radiusd/doc/rlm_sqlcounter
If you want to use groups instead of adding individual attributes to each of the users, add e.g. Max-Daily-Session to the radgroupcheck table instead of radcheck.

INSERT INTO `radgroupcheck` VALUES (1,'02hours','Max-Daily-Session',':=','7200');
Then add your users to the 02hours group.
Be sure to add Session-Timeout with the same value to the radgroupreply table as well.
An example:

INSERT INTO `radgroupreply` VALUES (1,'02hours','Framed-Protocol',':=','ppp',0),
(2,'02hours','Framed-IP-Address',':=','255.255.255.254',0),
(3,'02hours','Framed-IP-Netmask',':=','255.255.255.255',0),
(4,'02hours','Service-Type',':=','Framed',0),
(5,'02hours','Session-Timeout',':=','7200',0),
(6,'02hours','Termination-Action',':=','Your Session Has Been Terminated',0),
(7,'02hours','Port-Limit',':=','1',0),
(8,'02hours','Reply-Message',':=','Hello %u',0);

Works like a charm on FreeBSD and Linux.

My radius config for Linux:
http://www.yazzy.org/configs/linux/radiusd.conf



--

Regards,
M. Jessa
http://www.yazzy.org


-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 12:24 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0