I've read the guide, and tried essentially to integrate what I have already got that works and the Router-Switch-AP, with the goal of getting the guest VLAN working, and then replicating from there the other VLANs I want to create. Not stopping everything from working all at once also has very high wife acceptance factor while I try to make the VLANs work.
Ether10 goes to a Unifi wireless bridge and on to another RB4011 a couple of Km away that provides my internet access. That unit has the firewall on it, hence mine is really bare.
RB4011 lives out in a workshop. Ether 1 connects to an Aruba switch which is in the house, as well as an Aruba AP, configured to create an SSID that is tagged with VLAN40. If I connect a wireless device to the VLAN40 SSID, I get an IP address from the VLAN40 pool on the RB4011, so I think I have got that part sorted and working. What I don't seem to be able to sort is getting VLAN40 to the internet - and I can't quite work out what I'm missing - trying to combine my working setup with the wireless bridge and the VLAN guide is obviously not going quite to plan.
Code: Select all
# 2025-03-28 11:38:52 by RouterOS 7.17.1
# software id = XNUF-D3YG
#
# model = RB4011iGS+
# serial number =
/interface bridge
add name=bridge1 port-cost-mode=short
/interface vlan
add interface=bridge1 name=BASE_VLAN vlan-id=99
add comment="Guest VLAN" interface=bridge1 name=vlan40 vlan-id=40
/interface list
add name=LAN
add name=WAN
add name=VLAN
add name=BASE
/interface lte apn
set [ find default=yes ] ip-type=ipv4 use-network-apn=no
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_pool1 ranges=192.168.100.200-192.168.100.254
add name=dhcp_pool40 ranges=192.168.140.2-192.168.140.254
add name=BASE_POOL ranges=192.168.110.10-192.168.110.254
/ip dhcp-server
add address-pool=dhcp_pool1 interface=bridge1 lease-time=10m name=dhcp1
add address-pool=dhcp_pool40 comment="Guest VLAN" interface=vlan40 name=\
dhcp40
add address-pool=BASE_POOL interface=BASE_VLAN name=BASE_DHCP
/ip smb users
set [ find default=yes ] disabled=yes
/port
set 0 name=serial0
set 1 name=serial1
/routing bgp template
set default disabled=no output.network=bgp-networks
/routing ospf instance
add disabled=no name=default-v2
add disabled=no name=default-v3 version=3
/routing ospf area
add disabled=yes instance=default-v2 name=backbone-v2
add disabled=yes instance=default-v3 name=backbone-v3
/interface bridge port
add bridge=bridge1 ingress-filtering=no interface=ether2 internal-path-cost=\
10 path-cost=10
add bridge=bridge1 ingress-filtering=no interface=sfp-sfpplus1 \
internal-path-cost=10 path-cost=10
add bridge=bridge1 ingress-filtering=no interface=ether1 internal-path-cost=\
10 path-cost=10
add bridge=bridge1 interface=ether9 pvid=99
/ip firewall connection tracking
set udp-timeout=10s
/ip settings
set max-neighbor-entries=8192
/ipv6 settings
set max-neighbor-entries=8192 soft-max-neighbor-entries=8191
/interface bridge vlan
add bridge=bridge1 tagged=bridge1 vlan-ids=40
add bridge=bridge1 tagged=bridge1 vlan-ids=99
/interface list member
add interface=BASE_VLAN list=VLAN
add interface=BASE_VLAN list=BASE
add interface=ether10 list=WAN
add interface=vlan40 list=VLAN
/interface ovpn-server server
add auth=sha1,md5 mac-address=FE:9F:0C:A3:AF:3D name=ovpn-server1
/ip address
add address=192.168.120.1/24 interface=ether10 network=192.168.120.0
add address=192.168.100.1/24 interface=bridge1 network=192.168.100.0
add address=192.168.140.1/24 interface=vlan40 network=192.168.140.0
add address=192.168.110.1/24 interface=BASE_VLAN network=192.168.110.0
/ip dhcp-server lease
add address=192.168.100.4 client-id=1:f0:9f:c2:9:d4:6a comment=\
"Workshop Switch 8 150W" mac-address=F0:9F:C2:09:D4:6A server=dhcp1
/ip dhcp-server network
add address=192.168.100.0/24 dns-server=192.168.100.101 gateway=192.168.100.1
add address=192.168.110.0/24 dns-server=192.168.100.101 gateway=192.168.100.1
add address=192.168.140.0/24 dns-server=192.168.100.101 gateway=192.168.140.1
/ip dns
set servers=114.23.1.1
/ip firewall address-list
add address=192.168.120.0/24 list=Allowed_Internet
add address=192.168.100.0/24 list=Allowed_Internet
add address=192.168.140.0/24 list=Allowed_Internet
/ip firewall filter
add action=accept chain=forward comment="Our Networks <-> Our Networks" \
dst-address-list=Allowed_Internet src-address-list=Allowed_Internet
add action=accept chain=forward comment="Our Networks -> Internet" \
out-interface=ether10 src-address-list=Allowed_Internet
add action=accept chain=forward comment="Internet -> Our Networks" \
dst-address-list=Allowed_Internet in-interface=ether10
add action=accept chain=input comment="Allow Estab & Related" \
connection-state=established,related
add action=accept chain=input comment="Allow VLAN" in-interface-list=VLAN
add action=accept chain=input comment="Allow Base_Vlan Full Access" \
in-interface=BASE_VLAN
add action=accept chain=forward comment="Allow Estab & Related" \
connection-state=established,related
add action=accept chain=forward comment="VLAN Internet Access only" \
connection-state=new in-interface-list=VLAN out-interface-list=WAN
add action=drop chain=forward
/ip firewall nat
add action=masquerade chain=srcnat dst-address=192.168.100.0/24 src-address=\
192.168.120.0/24
add action=masquerade chain=srcnat dst-address=192.168.120.0/24 src-address=\
192.168.100.0/24
add action=masquerade chain=srcnat dst-address=192.168.100.0/24 protocol=udp \
src-address=192.168.100.0/24
add action=masquerade chain=srcnat comment="Default masquerade" \
out-interface-list=WAN
/ip ipsec profile
set [ find default=yes ] dpd-interval=2m dpd-maximum-failures=5
/ip route
add disabled=no dst-address=0.0.0.0/0 gateway=192.168.120.6
/ip service
set telnet disabled=yes
set www disabled=yes
set ssh disabled=yes
/ip smb shares
set [ find default=yes ] directory=/pub
/ipv6 address
# address pool error: pool not found: test (4)
add from-pool=test interface=sfp-sfpplus1
/ipv6 dhcp-client
add add-default-route=yes interface=ether10 pool-name=test \
pool-prefix-length=56 request=prefix use-peer-dns=no
/routing bfd configuration
add disabled=no interfaces=all min-rx=200ms min-tx=200ms multiplier=5
/system clock
set time-zone-name=Pacific/Auckland
/system note
set show-at-login=no
/system ntp client
set enabled=yes
/system ntp server
set enabled=yes multicast=yes
/system ntp client servers
add address=162.159.200.123
add address=192.107.172.20
/system resource irq rps
set sfp-sfpplus1 disabled=no
Thanks.