I don't access on internet with VLANs

I create 6 VLANs on backup - bonding interface (ether3 and ether4).
I have lan card who support VLANs. I got ip from vlan pool but I don’t have access on internet.

Internet works good from ether5 port who don’t have vlans. Gateway is 192.168.1.1 and I have ping 8.8.8.8 reply from ether1.

Here is config:


/interface ethernet
set [ find default-name=ether4 ] mac-address=CC:2D:E0:09:0E:98

/interface bonding
add mode=active-backup name=bonding1 slaves=ether3,ether4

/interface vlan
add interface=bonding1 name=vlan9 vlan-id=9
add interface=bonding1 name=vlan10 vlan-id=10
add interface=bonding1 name=vlan20 vlan-id=20
add interface=bonding1 name=vlan30 vlan-id=30
add interface=bonding1 name=vlan40 vlan-id=40
add interface=bonding1 name=vlan50 vlan-id=50


/ip pool
add name=vlan9 ranges=192.168.0.20-192.168.9.254
add name=vlan10 ranges=192.168.10.1-192.168.19.254
add name=vlan20 ranges=192.168.20.1-192.168.29.254
add name=vlan30 ranges=192.168.30.1-192.168.39.254
add name=vlan40 ranges=192.168.40.1-192.168.49.254
add name=vlan50 ranges=192.168.50.1-192.168.59.254
add name=dhcp_pool6 ranges=192.168.88.2-192.168.88.254

/ip dhcp-server
add address-pool=vlan10 disabled=no interface=vlan10 name=dhcp-vlan10
add address-pool=vlan20 disabled=no interface=vlan20 name=dhcp-vlan20
add address-pool=vlan30 disabled=no interface=vlan30 name=dhcp-vlan30
add address-pool=vlan40 disabled=no interface=vlan40 name=dhcp-vlan40
add address-pool=vlan50 disabled=no interface=vlan50 name=dhcp-vlan50
add address-pool=dhcp_pool6 disabled=no interface=ether2 name=dhcp1

/ip address
add address=192.168.1.115/16 interface=ether1 network=192.168.0.0
add address=192.168.0.10/16 interface=vlan9 network=192.168.0.0
add address=192.168.0.11/16 interface=vlan10 network=192.168.0.0
add address=192.168.0.12/16 interface=vlan20 network=192.168.0.0
add address=192.168.0.13/16 interface=vlan30 network=192.168.0.0
add address=192.168.0.14/16 interface=vlan40 network=192.168.0.0
add address=192.168.0.15/16 interface=vlan50 network=192.168.0.0
add address=192.168.88.1/24 interface=ether2 network=192.168.88.0

/ip dhcp-server network
add address=192.168.0.0/16 gateway=192.168.0.10
add address=192.168.88.0/24 dns-server=8.8.8.8 gateway=192.168.88.1

/ip firewall nat
add action=masquerade chain=srcnat log=yes
/ip route
add distance=1 gateway=192.168.1.1

You use the same subnet (192.168.0.0/16) on several interfaces, which is possible but requires some additional efforts to work and is far from usual. So you should use a distinct subnet for each vlan and give each local interface in that vlan an address from that subnet.

Besides, the /ip pool only controls which addresses to assign to DHCP clients, but the rest (default gateway, dns, etc.) must be defined using /ip dhcp-server network.