Vlan bridging wlan

Im trying to configure a vlan bridging and just assign vlan to wlan guest interface, but with config below devices cannot obrain ip address:

/interface bridge
add admin-mac=3E:81:9F:76:72:2B auto-mac=no frame-types=admit-only-vlan-tagged name=bridge1 pvid=99 vlan-filtering=yes
/interface wifiwave2
set [ find default-name=wifi2 ] configuration.mode=ap .ssid=ssss disabled=no security.authentication-types="" .group-encryption=gcmp-256
/interface vlan
add interface=bridge1 name=bridge1.20 vlan-id=20
/interface wifiwave2
add configuration.mode=ap .ssid=Kguest disabled=no mac-address=4A:A9:8A:DA:5D:3E master-interface=wifi2 name=kguest
/ip pool
add name=dhcp_pool1 ranges=10.1.0.200-10.1.0.254
add name=dhcp_pool2 ranges=10.1.0.200-10.1.0.254
add name=dhcp_pool3 ranges=172.16.0.200-172.16.0.254
/ip dhcp-server
add address-pool=dhcp_pool2 interface=ether4 lease-time=1h name=dhcp1
# DHCP server can not run on slave interface!
add address-pool=dhcp_pool3 interface=kguest name=dhcp2
/interface bridge port
add bridge=bridge1 frame-types=admit-only-untagged-and-priority-tagged interface=kguest pvid=20
/ip neighbor discovery-settings
set discover-interface-list=!dynamic
/ip address
add address=10.1.0.1/24 interface=ether4 network=10.1.0.0
add address=172.16.0.1/24 interface=bridge1.20 network=172.16.0.0
/ip dhcp-client
add interface=ether1 use-peer-dns=no use-peer-ntp=no
/ip dhcp-server network
add address=10.1.0.0/24 dns-server=192.168.1.109 gateway=10.1.0.1
add address=172.16.0.0/24 gateway=172.16.0.1

Where is the problem?

As the comment says, DHCP server can not run on slave interface. In this case slave interface is kguest and it’s slave of bridge. It’s properly configured as sccess port of v,an 20. So “master” interface for vlan 20 is now interface bridge1.20 and you should bind DHCP server to that interface. Just like you did it correctly with address 172.16.0.1/24.

Ty for reply. I have tried possible variations, so forgot to change back. If I understood u correctly I have only to change dhcp server and bind to bridge1.20, but I have the same problem, I cannot get Ip.

/interface bridge
add admin-mac=4A:A9:8A:DA:5D:3E auto-mac=no frame-types=admit-only-vlan-tagged name=bridge1 pvid=99 vlan-filtering=yes
/interface wifiwave2
set [ find default-name=wifi2 ] configuration.mode=ap .ssid=ssss disabled=no security.authentication-types="" .group-encryption=gcmp-256
/interface vlan
add interface=bridge1 name=bridge1.20 vlan-id=20
/interface wifiwave2
add configuration.mode=ap .ssid=Kguest disabled=no mac-address=4A:A9:8A:DA:5D:3E master-interface=wifi2 name=kguest
/ip pool
add name=dhcp_pool1 ranges=10.1.0.200-10.1.0.254
add name=dhcp_pool2 ranges=10.1.0.200-10.1.0.254
add name=dhcp_pool3 ranges=172.16.0.200-172.16.0.254
add name=dhcp_pool4 ranges=172.16.0.2-172.16.0.254
/ip dhcp-server
add address-pool=dhcp_pool2 interface=ether4 lease-time=1h name=dhcp1
add address-pool=dhcp_pool4 interface=bridge1.20 name=dhcp2
/interface bridge port
add bridge=bridge1 frame-types=admit-only-untagged-and-priority-tagged interface=kguest pvid=20
/ip neighbor discovery-settings
set discover-interface-list=!dynamic
/ip address
add address=10.1.0.1/24 interface=ether4 network=10.1.0.0
add address=172.16.0.1/24 interface=bridge1.20 network=172.16.0.0
/ip dhcp-client
add interface=ether1 use-peer-dns=no use-peer-ntp=no
/ip dhcp-server network
add address=10.1.0.0/24 dns-server=192.168.1.109 gateway=10.1.0.1
add address=172.16.0.0/24 gateway=172.16.0.1

Check the MAC addresses, they are explicitly set on bridge and kguest slave wlan and tgey are set to same value. I’d set them to different values. And also verify these are not the same as MAC address of any of other interfaces. In particular, wireless interface MAC addresses of master and all slave interfaces have to be different.

Same issue :neutral_face:
I have change master and slave wlans mac, but nothing..