I help to manage a free wireless hotspot that is being leached off of quite severely (5-6 TB/month). I found a few sample scripts to perform bandwidth accounting over a certain period. I’ve also found the feature in User Manager to limit users downloads to a certain amount in a given time. We don’t want to have to create users or have the users login.
My question is this. What is the easiest way to allow a user to access the network without logging in (we already have a Cisco Wireless LAN Controller handling the Terms and Conditions) and then throttle or disconnect their connection if they go over a certain download thresthold (100mb/day).
Thanks for the quick reply. MAC address would be best for telling them apart. I don’t see an easy way to apply daily limits though for these users. I can see where you do that for manually created users in UM, but not for users who aren’t in the system.
Just to clarify, these are users coming in off of the street. We don’t know their MAC addresses beforehand. I want them to automatically connect, get put into the user database and then have the limits applied.
Here is a script that I’ve been trying out. It does limit the user to the lower speed once they reach the download amount, but clearing the counters doesn’t release them from that limit. Has something changed in version 3 that is making this script not work? I found this on the wiki (http://wiki.mikrotik.com/wiki/Limiting_a_user_to_a_given_amount_of_traffic_II). I am using the /que simple reset-counters-all and not /que simple reset-counters, although I’ve tried both with similar results.
I have now got this working. The scripts on the wiki had some spaces in them that were preventing them from running properly. I now have a script that runs at 10, 20, 30, 40, and 50 minutes on the hour to check and see if any queue has gone above a certain download limit. If it has, the queue’s speed is throttled back. On the hour, the counters are reset and the queue speeds are brought back up to their normal limit.
I hand out DHCP addresses for 1 hour, so there are some issues with another user possibly being punished for someone else’s downloads.
Has anyone discovered any event functionality in RouterOS? I would like to clear counters on particular queues when a new DHCP lease is assigned. For example, if 192.168.1.1 is leased out, I would like to clear the counters on my 192.168.1.1 queue.
Again, I know there are ways that users can abuse this, but I can’t find anything else that can properly throttle users on a free hotspot. This will help curtail the average user’s excessive downloads.