<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'>
Hi,<BR>
<BR>
I normally use MK for lots of things. The Mikrotik-Xmit-Limit attribute is recognize for MK as a limitation, so when the limit arrives, the MT cuts the user account. <BR>
You can write a exec program to modify the Mikrotik-Xmit-Limit attribute or insert a trigger in the DB or use sqlcounter.<BR>
<BR>
You choose what solucion is easier for you.<BR>
<BR>
Santiago<BR> <BR>
> From: shane@sme.net.au<BR>> Date: Sat, 27 Nov 2010 20:44:24 +1000<BR>> Subject: Mikrotik-Xmit-Limit - Not enforced on first logon but is on subsequent logons...<BR>> To: freeradius-users@lists.freeradius.org<BR>> <BR>> Hi all,<BR>> <BR>> Doing some trials with freeradius 2.x with the intention of moving from<BR>> 1.1.7<BR>> <BR>> <BR>> I have an odd problem with mikrotik nas.<BR>> An account with download limit will not enforce the limit on the first<BR>> logon but will on subsequent logons.<BR>> On the first logon, no limit is imposed in mikrotik and the account can<BR>> use unlimited traffic. If I log off then log on again, the limit is<BR>> enforced... (I have checked in winbox and the "limit bytes in" column is<BR>> not populated on first logon).<BR>> <BR>> It is taking me a while to get use to v2 of freeradius.<BR>> <BR>> Tks<BR>> <BR>> <BR>> Setup details below:<BR>> <BR>> User account has attribute Mikrotik-Xmit-Limit := 10471200 in radcheck<BR>> Do I need to have something in radreply as this is where the shaping is<BR>> done?<BR>> <BR>> <BR>> In: sql/mysql/counter.conf<BR>> <BR>> sqlcounter downloadbytecounter {<BR>> counter-name = Mikrotik-Xmit-Limit<BR>> check-name = Mikrotik-Xmit-Limit<BR>> reply-name = Mikrotik-Xmit-Limit<BR>> sqlmod-inst = sql<BR>> key = User-Name<BR>> reset = never<BR>> query = "SELECT SUM(acctoutputoctets) FROM radacct WHERE<BR>> username='%{%k}'"<BR>> }<BR>> <BR>> <BR>> <BR>> In sites-available/default<BR>> <BR>> authorize {<BR>> downloadbytecounter<BR>> -<BR>> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html<BR> </body>
</html>