Community discussions

MikroTik App
 
User avatar
Techsystem
Member
Member
Topic Author
Posts: 337
Joined: Tue Dec 21, 2021 5:12 am

defining a specified data limit for users without using hotspot or user manager

Thu Dec 08, 2022 7:59 am

Hello my friends..!
so is it possible to define a specific amount of data for evey users without using usermanger or hotspot..?
i mean i want to give user1 that have the IP address 192.168.10.10/32 = 2 G for month and user2 that have the IP address 192.168.10.11/32= 4G for month
is it possible tp apply this..?
so please notice that this not queue..! i dont want to limit speed for download and upload, but i want to define a specific data packet for every user.
 
Sob
Forum Guru
Forum Guru
Posts: 9119
Joined: Mon Apr 20, 2009 9:11 pm

Re: defining a specified data limit for users without using hotspot or user manager

Sun Dec 11, 2022 5:15 am

You could use passthrough rules as counters, but then you'd need some mechanism to check whether limits are exceeded. Which probably shouldn't be too difficult to do using scripting. But unsolved problem is that if router reboots, counters will reset, so you'd need something else that would periodically save current state. Which is probably doable too, but as whole it's getting a bit complicated.
 
User avatar
Techsystem
Member
Member
Topic Author
Posts: 337
Joined: Tue Dec 21, 2021 5:12 am

Re: defining a specified data limit for users without using hotspot or user manager

Sun Dec 11, 2022 10:01 am

You could use passthrough rules as counters, but then you'd need some mechanism to check whether limits are exceeded. Which probably shouldn't be too difficult to do using scripting. But unsolved problem is that if router reboots, counters will reset, so you'd need something else that would periodically save current state. Which is probably doable too, but as whole it's getting a bit complicated.
Hi Sob..!
thanks for your replay ..!
please can you give an example on how to do that using script..?
i mean what i have to write in script menu in order to achieve that..? is there is a guide for that..?
 
Sob
Forum Guru
Forum Guru
Posts: 9119
Joined: Mon Apr 20, 2009 9:11 pm

Re: defining a specified data limit for users without using hotspot or user manager

Sun Dec 11, 2022 3:38 pm

I'm afraid not. RouterOS scripting doesn't like me. I can manage to produce something when I need it, but I always suffer while doing it, so otherwise I tend to avoid it. :)

If you're at least a bit into programming, you can check official docs:

https://help.mikrotik.com/docs/display/ROS/Scripting
https://help.mikrotik.com/docs/display/ ... g+examples

And there's even more source of inspiration here:

✂ Rextended Fragments of Snippets
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19125
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: defining a specified data limit for users without using hotspot or user manager

Sun Dec 11, 2022 7:06 pm

I'm afraid not. RouterOS scripting doesn't like me. I can manage to produce something when I need it, but I always suffer while doing it, so otherwise I tend to avoid it. :)
We must be twins? Were you adopted. '=P
 
Sob
Forum Guru
Forum Guru
Posts: 9119
Joined: Mon Apr 20, 2009 9:11 pm

Re: defining a specified data limit for users without using hotspot or user manager

Sun Dec 11, 2022 8:03 pm

I think more people have this in common. Italian cats seem to like it, but that's some weird exception.
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19125
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: defining a specified data limit for users without using hotspot or user manager

Sun Dec 11, 2022 8:32 pm

I think more people have this in common. Italian cats seem to like it, but that's some weird exception.
I think one needs to be in a very high state of euphoria supported by high quality vino.
 
User avatar
Techsystem
Member
Member
Topic Author
Posts: 337
Joined: Tue Dec 21, 2021 5:12 am

Re: defining a specified data limit for users without using hotspot or user manager

Mon Dec 12, 2022 2:18 pm

I think more people have this in common. Italian cats seem to like it, but that's some weird exception.
I think one needs to be in a very high state of euphoria supported by high quality vino.
Hello Mr anav..!
so while i am looking around in queue type, i find this CE threshold, so i dont actually know if this related at all to our discussion as tiltled above, but from your experience is there is
a queue kind in this list that we can use to achieve my scenario..?
aslo i didnt find any explination in mikrotik documentation about this CE threshold thing.
so please advise me..!
You do not have the required permissions to view the files attached to this post.
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19125
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: defining a specified data limit for users without using hotspot or user manager

Mon Dec 12, 2022 2:32 pm

I have not played with queues sorry, I have fat pipes and dont worry about limits.
 
User avatar
rextended
Forum Guru
Forum Guru
Posts: 11982
Joined: Tue Feb 25, 2014 12:49 pm
Location: Italy
Contact:

Re: defining a specified data limit for users without using hotspot or user manager

Mon Dec 12, 2022 2:47 pm

@Sob, @anav, thanks for the mention :)

Sorry @Techsystem: in this case it takes too much work...
both to understand what exactly is needed, and to implement it afterwards.
 
User avatar
Techsystem
Member
Member
Topic Author
Posts: 337
Joined: Tue Dec 21, 2021 5:12 am

Re: defining a specified data limit for users without using hotspot or user manager

Mon Dec 12, 2022 3:26 pm

@Sob, @anav, thanks for the mention :)

Sorry @Techsystem: in this case it takes too much work...
both to understand what exactly is needed, and to implement it afterwards.
dont worry..! if i had my own MT router i wouldnt ask this questions that only need someone to test , hope to have one..:-().
 
Sob
Forum Guru
Forum Guru
Posts: 9119
Joined: Mon Apr 20, 2009 9:11 pm

Re: defining a specified data limit for users without using hotspot or user manager

Sun Dec 18, 2022 2:21 am

If you don't have MT router and want to play with RouterOS, you can use (free) CHR.
 
volkirik
Member Candidate
Member Candidate
Posts: 208
Joined: Sat Jul 23, 2016 2:03 pm

Re: defining a specified data limit for users without using hotspot or user manager

Sat Jun 24, 2023 10:57 pm

i didnt find any explination in mikrotik documentation about this CE threshold thing.
so please advise me..!
Marks packets above a configured threshold with ECN. (congestion encountered)

I use 1600000 µs = 1600 ms = 1.6 second. YMMV

Who is online

Users browsing this forum: elbob2002, Ward and 27 guests