Community discussions

MikroTik App
 
prawira
Trainer
Trainer
Topic Author
Posts: 359
Joined: Fri Feb 10, 2006 5:11 am

different gateway according to user domain

Fri Nov 19, 2010 11:39 am

Hi all,

let say there is one resto with internet facility serve by three different isp. each isp connected to ether1, ether2 and ether3

and all of the above three isp mempers can use this internet connection with theirown username; such us albert@isp-a.com, bob@isp-b.com, etc.

question is, how to make the different gateway ? such as if all@isp-a.com login than the traffic go to ether1, if any@isp-b.com than the traffict go to ether2, etc.

cheers

Paul
 
SurferTim
Forum Guru
Forum Guru
Posts: 4636
Joined: Mon Jan 07, 2008 10:31 pm
Location: Miramar Beach, Florida

Re: different gateway according to user domain

Fri Nov 19, 2010 1:22 pm

In FreeRADIUS, you would return "Framed-Route"
In "/ip hotspot user", you would enter that in "routes".
In User Manager, I don't see an entry. ??
 
prawira
Trainer
Trainer
Topic Author
Posts: 359
Joined: Fri Feb 10, 2006 5:11 am

Re: different gateway according to user domain

Fri Nov 19, 2010 1:53 pm

Hi surfertim, you got my point ;)

how about "group" and "address list" in user @ user manager ?
perhaps we can put something on one of the above fields and re-route with mangle.

Paul
 
SurferTim
Forum Guru
Forum Guru
Posts: 4636
Joined: Mon Jan 07, 2008 10:31 pm
Location: Miramar Beach, Florida

Re: different gateway according to user domain

Fri Nov 19, 2010 2:04 pm

I presumed that was what you were getting at. :D

You could use Pool Name to use a specific ip pool from dhcp. Then route that pool subnet through the appropriate gateway.
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: different gateway according to user domain

Fri Nov 19, 2010 2:26 pm

There is no routes in User Manager.
Address-list option could be useful for you, you may set address-list from User Manager, then use address-list and apply specific policy-routing for the user.
 
prawira
Trainer
Trainer
Topic Author
Posts: 359
Joined: Fri Feb 10, 2006 5:11 am

Re: different gateway according to user domain

Fri Nov 19, 2010 4:45 pm

well.. I can not see the relation between @domain-name at username with group or address pool.

of course each users can login to their radius server; isp-a, isp-b, or isp-c respectively as setup under radius.
but it does not mark the connection to be routed.

perhaps on the next release of ROS, there is an option 'route mark' to be added under each radius line; not under usermanager.

Paul
 
SurferTim
Forum Guru
Forum Guru
Posts: 4636
Joined: Mon Jan 07, 2008 10:31 pm
Location: Miramar Beach, Florida

Re: different gateway according to user domain

Fri Nov 19, 2010 7:10 pm

How many radius servers do you have? You can have each RADIUS server return a different Group. Each group (/ip hotspot user profile) can have a different ip pool (address-pool).
default (routeA) ip pool issues 192.168.1.2-127
routeB ip pool issues 192.168.1.128-191
routeC ip pool issues 192.168.1.192-254

Then use mangle to put a routing-mark on each src-address subnet.
/ip firewall mangle
add chain=prerouting action=mark-routing new-routing-mark=routeA src-address=192.168.1.0/25
add chain=prerouting action=mark-routing new-routing-mark=routeB src-address=192.168.1.128/26
add chain=prerouting action=mark-routing new-routing-mark=routeC src-address=192.168.1.192/26

Who is online

Users browsing this forum: No registered users and 8 guests