Community discussions

MikroTik App
 
suvasishpaul
just joined
Topic Author
Posts: 5
Joined: Tue Jun 30, 2020 7:14 am

DHCP server cannot run on slave interface

Thu Feb 09, 2023 9:06 am

I have DHCP server on this VLAN interface. When I try to configure this Vlan interface on bridge. DHCP server stops working. it says DHCP server can not run on slave interface.

My configuration are bellow

/interface bridge
add name=ACCESS_999
add name=LAN
/interface vlan
add interface=LAN name=VLAN_101 vlan-id=101
add interface=LAN name=VLAN_201 vlan-id=201
add interface=LAN name=VLAN_999 vlan-id=999

/ip pool
add name=dhcp_pool1 ranges=10.2.100.2-10.2.100.254
add name=dhcp_pool2 ranges=10.2.96.2-10.2.96.254
add name=dhcp_pool3 ranges=10.2.99.2-10.2.99.254
/ip dhcp-server
add address-pool=dhcp_pool1 interface=VLAN_101 name=DHCP_VLAN_101
add address-pool=dhcp_pool2 interface=VLAN_201 name=DHCP_VLAN_201
# DHCP server can not run on slave interface!
add address-pool=dhcp_pool3 interface=VLAN_999 name=DHCP_VLAN_999

/interface bridge port
add bridge=ACCESS_999 interface=ether2
add bridge=ACCESS_999 interface=VLAN_999
/ip address
add address=10.2.96.1/24 interface=VLAN_201 network=10.2.96.0
add address=10.2.100.1/24 interface=VLAN_101 network=10.2.100.0
add address=10.2.99.1/24 interface=VLAN_999 network=10.2.99.0
/ip dhcp-server network
add address=10.2.96.0/24 dns-server=8.8.8.8,10.2.99.1 gateway=10.2.96.1
add address=10.2.99.0/24 dns-server=8.8.8.8,10.2.99.1 gateway=10.2.99.1
add address=10.2.100.0/24 dns-server=8.8.8.8,10.2.99.1 gateway=10.2.100.1
You do not have the required permissions to view the files attached to this post.
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19323
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: DHCP server cannot run on slave interface

Thu Feb 09, 2023 3:10 pm

(1) A vlan cannot be a bridge port normally its etherports and wlans......

/interface bridge port
add bridge=ACCESS_999 interface=ether2
add bridge=ACCESS_999 interface=VLAN_999


(2) Additionally you assigned vlan 99 to the LAN bridge, then trying to associate vlan 99 to the ACCESS_999 bridge
methinks you are confused!!!
 
User avatar
rumahnetmks
Frequent Visitor
Frequent Visitor
Posts: 56
Joined: Mon Dec 21, 2020 10:00 am

Re: DHCP server cannot run on slave interface

Thu Feb 09, 2023 5:00 pm

First why 2 bridge and using vlan? As a newbie I've been there long time ago, always make 2 bridge (or more zZz) just to make another netwok segment.
Now with vlan no need many bridge anymore, just one and next can create more than one network segment.

/interface bridge
add name=ACCESS_999
add name=LAN

Just one bridge then put all your ethernet port into that single bridge.. Let say you choose to use only LAN bridge, delete the ACCESS_999 bridge entry.
/interface bridge port
add bridge=ACCESS_999 interface=ether2
add bridge=ACCESS_999 interface=VLAN_999
<= as anav mention this make that error about slave. Only entry ethernet port and/or wlan with corresponding match pvid.
since u delete ACCESS_999 bridge, change it to
/interface bridge port
add bridge=LAN interface=ether2

/interface vlan
add interface=LAN name=VLAN_101 vlan-id=101
add interface=LAN name=VLAN_201 vlan-id=201
add interface=LAN name=VLAN_999 vlan-id=999

The rest I think you must know about tagged and untagged, firewall etc. You can read nice tutorial here viewtopic.php?t=143620
Your config above not complete.

Who is online

Users browsing this forum: Ahrefs [Bot], tosie and 100 guests