Community discussions

MikroTik App
 
mobilexpi
Member Candidate
Member Candidate
Topic Author
Posts: 115
Joined: Thu May 26, 2005 5:24 am
Location: Santiago

Associate a specific DHCP server based on MAC address?

Fri Apr 02, 2010 7:39 pm

Hello guys,
I've a RB450G with 1 cable 8/1mbps connection. I want to have three kind of users 512Kbps, 1mbps and 2mbps.

My idea is to use ip range 192.168.50.x - 512k users, 192.168.60.x - 1mbps users, and 192.168.70.1 - 2mbps users.
I am going to create 3 DHCP servers, each one with the described pool, now I want to automatically associate one specific user to a predefined DHCP server based on their MAC address. It is possible? I was reading the wiki, but I only found topics related to RADIUS.

Thank you
Best regards,
Last edited by mobilexpi on Sun Apr 04, 2010 10:36 am, edited 1 time in total.
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: Associate a specific DHCP server based on MAC address?

Fri Apr 02, 2010 8:16 pm

http://wiki.mikrotik.com/wiki/Manual:IP ... ver#Leases
You can also add static leases to issue a particular client (identified by MAC address) the desired IP address.
 
mobilexpi
Member Candidate
Member Candidate
Topic Author
Posts: 115
Joined: Thu May 26, 2005 5:24 am
Location: Santiago

Re: Associate a specific DHCP server based on MAC address?

Sun Apr 04, 2010 10:39 am

Hello,
I was reading the manual in leases, thank you.
Now I have another problem, I can't create more than one DHCP server associated to one port (in my case bridge).
My idea is to connect the RB450g to my ubiquiti bullet m2hp using one cable, and that different types of users connect to the same AP.
How can I create 3 dhcp server associated to one port, and then assign the IP based on the MAC (according to MAC address this user will be assigned to 512k users or 1mbps or 2mbps).

Thanks
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: Associate a specific DHCP server based on MAC address?

Sun Apr 04, 2010 6:58 pm

You can only have one DHCP server per network on the same router. I don't understand why you think you need several. There's many ways you can use just one in a way to identify the user for bandwidth requirements. Make it a /22 private space and assign users that are to get 128/256kbps addresses within the first /24, and users that are to get 256/512kbps addresses within the second /24 and then mangle packets based on source address. Or, with recent versions, assign the users to an address list in the hard set lease, and mangle based on src-address-list. That's probably the cleanest solution.
 
mremme
just joined
Posts: 12
Joined: Tue Sep 01, 2020 12:06 pm

Re: Associate a specific DHCP server based on MAC address?

Thu Sep 10, 2020 4:14 pm

I think you can achieve it with one dhcp server (you can have only one per network/bridge) and severla IP POOL

then you can classify your users by vendor-class-id assigning the correct IP Pool

I'm working on this in these days on my LAN splitting IP ranges per IoT, Server, Mobile and other devices
ciao
M
 
rdtech
just joined
Posts: 2
Joined: Sat Sep 28, 2019 4:26 pm

Re: Associate a specific DHCP server based on MAC address?

Sat Apr 17, 2021 4:04 am

looking on the same setup. any working solutions?

Who is online

Users browsing this forum: Bing [Bot], Guntis, Happyrob, mogiretony, phascogale and 69 guests