Community discussions

MikroTik App
 
mgrabar
just joined
Topic Author
Posts: 14
Joined: Sat Sep 25, 2010 10:06 am

RADIUS Limit attributes

Sat Sep 25, 2010 10:46 am

Hello,

Could you please point me to the most recent version of the dictionary file for MikroTik because the link on wiki is broken?
http://wiki.mikrotik.com/wiki/Manual:RADIUS_Client

In the old MikroTik dictionary file I have found the attributes that can be used to provide prepaid services for the customers on the network:
Mikrotik-Recv-Limit
Mikrotik-Recv-Limit-Gigawords
Mikrotik-Xmit-Limit
Mikrotik-Xmit-Limit-Gigawords
There are also rumors on various forums that the following parameter exists:
Mikrotik-Total-Limit
Mikrotik-Total-Limit-Gigawords
Can you confirm this? What are your experience with these parameters?

Can you please explain me how this parameters work?
If I describe the customer session trough RADIUS with these parameters, customer will be disconnected after interface counters for his session reach defined limit. What happens when customer disconnect and he didn’t still reach this limit? Are the values from this parameters stored somewhere in session database on MikroTik? If so, what happens if there are multiple routerboards in network?

I can solve these problems trough RADIUS with a little script which monitor accounting data and disconnect customer after he reach traffic limit.

Could you please share your experience with me about this topic?
I am running v4 OS.
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: RADIUS Limit attributes

Mon Sep 27, 2010 5:09 pm

Since this isn't in the User Manager forum I'm assuming you're using a different RADIUS server.

When you send those attributes and the client reaches those limits the client's session is terminated. If the limits are not reached and the session terminates otherwise the router will send a RADIUS accounting packet back to the RADIUS server that authenticated the client, that packet will report bytes/octets used by the client. It is up to the RADIUS server to store that information and - potentially, at least - send back a lower limit next time the client is authenticated.

As an example, say that a client is sold 5GB of access. The client connects, the RADIUS server authenticates him and sends back a limit of 5GB. Then client two hours later disconnects. The router reports back that the client used 4GB. The RADIUS server stores that information, for example right in the database that contains client information, and subtracts 4GB from the user's data limit. The next time the client connects the RADIUS server sends back a limit of 1GB. The client transmits 1GB and the router disconnects him.
 
mgrabar
just joined
Topic Author
Posts: 14
Joined: Sat Sep 25, 2010 10:06 am

Re: RADIUS Limit attributes

Mon Sep 27, 2010 8:12 pm

Thank you very much for this clarification. You should put this example into documentation.

Regards,
Matija

Who is online

Users browsing this forum: almdandi, araqiel, ips, Majestic-12 [Bot], mkx, Seko777 and 78 guests