Topic: limiting user by bandwith quota

dear all ..iam new in this forum
my first post is, i want to ask how to liming user by bandwidth quota that they used.
for example i want to limit a user just 10mb in a day or 100 in a week.. how to perform this..please help and sorry for my very bad English.
appreciate for your help
regard

Re: limiting user by bandwith quota

i've try using sqlcounter from freeradius, but it is not limiting user bandwidht quota, it is for limitation by time counter.

Re: limiting user by bandwith quota

mmm as i khow that WISPr-Max-Bandwidth-Down and WISPr-Max-Bandwidth-up is to limiting user trafic not for quota limitation, what i want is to do limitation for bandwidth usage, for example, i want to allow the user to access the Internet 100mb in a week, when the user reach the limit they cannot log in before one week.

Re: limiting user by bandwith quota

how to implementing this code?or just copy and paste this code to realm_sqlcounter??i litle about the octet do i have to include the chillispot.dictinary in radiusd.conf??sorry for so many question, i just new chillispot users..thank a lot for your help..

Re: limiting user by bandwith quota

ok friend, i'll try just like told me smile, but please don't bored if i ask u a question again big_smile

Re: limiting user by bandwith quota

i got this error when i implementing that sqlcounter...chillispot vendor unidentified by freeradius..
what next step..??
read_config_files:  reading dictionary
Errors reading dictionary: dict_init: /etc/freeradius/dictionary[33]: unknown vendor ChilliSpot
Errors reading radiusd.conf

Re: limiting user by bandwith quota

yaps it workss......!!! thank you so much.

Re: limiting user by bandwith quota

hi all,
there is a quoting for day ??? One user only can download 100MB by day per example ??

Thanks!!!

Re: limiting user by bandwith quota

Hi guys, im also new in chillispot. Nizarjoe i wanna ask some question, do Quota limiting really work for you? I have tried implemented Chillispot-Max-Total-Octets in my freeradius with daily accounting. But some strange behaviour is occured. When the quota is end (for example 10MB a day) then i cant login again another day (it should be resetted daily) except i reset the account manually. I have examined freeradius in debugging mode, it said always rejected because value is low than zero. And another buggy is when using quota limitation together with time limitation, im curious if we can do something like limiting quota and time together, whenever it comes first. I've searching around and have a dead end.. sad Any clue appreciated..

Re: limiting user by bandwith quota

Thanks dmkhn, i think its for time accounting. But its a good idea to make time counting on the first login, i'll make note on this.
In my case, have you found solution to mix time limitation together with quota limitation whenever which reached first?

Re: limiting user by bandwith quota

yes my friend, i have tried it and its not working either. I thought it was only query for invert the counting into reverse order from the beginning. In my case my time limitation is working fine,the issues is only about quota limitation. Im using quota limitiation with reset set to daily. Im not using noresetcounter. But if i put those two counter together (both check about quota and time), my time counter is not working too (sometimes its working sometimes not). Here my counter looks like now:

sqlcounter quotalimit {
                counter-name = Total-Max-Octets
                check-name = Max-Daily-Octets
                reply-name = Chillispot-Max-Total-Octets
                key = User-Name
                reset = daily
                query = "SELECT IFNULL(SUM(acctinputoctets+acctoutputoctets),0) from radacct WHERE UserName='%{%k}'"
                sqlmod-inst = sql
        }
Im wonder why its not working, It will not disconnect if the quota has reached. But if we logout and login again, the counter is working and return message that our daily quota has reached the limit. After a day, the counter still not resetted and the user still cant login because quota has reached the limit. I can login again after i delete radacct record for this user.
Im had checked in debug mode, i dont think there is an error because it say that the counter will be resetted on the next day. I should be working.. strange isnt it?
Please Let me know if you found anything..

Re: limiting user by bandwith quota

Yup, im already initialize quotalimit in the authorize section. But i dont use noresetcounter so i didnt put it into my config. Had tested it for downloading files bigger than the quota and i still connected when quota had reached (both tested using browser and download manager). The counter working after second login, and daily quota never resetted except if i delete it manually. Is this issue is about Access Point problem? Im using Linksys WRT54GL DDWRT..

Re: limiting user by bandwith quota

Thanks dmkhn for assisting. I still dont know whats wrong with my configuration. Last time i completely uninstall freeradius package and reinstall, and still not showing any working result.
Here is my installed package :freeradius  2.1.0+dfsg-0ubuntu2~hardy, freeradius-common, freeradius-mysql, freeradius-utils, libfreeradius2.
Do i missing something here..?

Re: limiting user by bandwith quota

yay!! its working thanks a lot..

Re: limiting user by bandwith quota

i am also looking to limit data limit. Can you please share the code as to how did you achieve it?
Thanks

16 (edited by louya062 2015-07-06 03:08:31)

Re: limiting user by bandwith quota

that's works? i will try it coque samsung galaxy note 4