Thanks.
I have run a few tests to verify if the DHCP settings is the root cause of the Internet problem. In short, it seems DHCP is NOT the root cause of the problem based on the following results. I’ve tested with the mask bits /16 and /24 as suggested and disabling the DHCP in the VLAN. All three settings yield the same result unfortunately.
Here are the config in case anyone want to double check:
/24:
# sep/02/2023 15:19:03 by RouterOS 7.6
# software id = KI2X-PHFS
#
# model = CRS326-24G-2S+
# serial number = D9260D352571
# serial number = XXX
/interface bridge
add admin-mac=aa:bb:cc:dd:ee:ff auto-mac=no comment=defconf name=BR1 \
vlan-filtering=yes
/interface vlan
add interface=BR1 name=CAMERA_VLAN vlan-id=30
add interface=BR1 name=GUEST_VLAN vlan-id=20
add interface=BR1 name=IOT_VLAN vlan-id=40
add interface=BR1 name=MGMT_VLAN vlan-id=99
add interface=BR1 name=TRUST_VLAN vlan-id=10
/interface list
add name=WAN
add name=VLAN
add name=MGMT
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip hotspot profile
set [ find default=yes ] html-directory=hotspot
/ip pool
add name=TRUST_POOL ranges=172.20.0.2-172.20.0.254
add name=GUEST_POOL ranges=172.21.0.2-172.21.255.254
add name=CAMERA_POOL ranges=172.22.0.2-172.22.255.254
add name=IOT_POOL ranges=172.23.0.2-172.23.255.254
add name=MGMT_POOL ranges=172.30.0.2-172.30.255.254
/ip dhcp-server
add address-pool=TRUST_POOL interface=TRUST_VLAN name=TRUST_DHCP
add address-pool=GUEST_POOL interface=GUEST_VLAN name=GUEST_DHCP
add address-pool=CAMERA_POOL interface=CAMERA_VLAN name=CAMERA_DHCP
add address-pool=IOT_POOL interface=IOT_VLAN name=IOT_DHCP
add address-pool=MGMT_POOL interface=MGMT_VLAN name=MGMT_DHCP
/port
set 0 name=serial0
/interface bridge port
add bridge=BR1 comment=defconf interface=ether1
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether2
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether3
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether4
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether5
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether6
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether7
add bridge=BR1 comment=defconf interface=ether8
add bridge=BR1 comment=defconf interface=ether9
add bridge=BR1 comment=defconf interface=ether10
add bridge=BR1 comment=defconf interface=ether11
add bridge=BR1 comment=defconf interface=ether12
add bridge=BR1 comment=defconf interface=ether13
add bridge=BR1 comment=defconf interface=ether14
add bridge=BR1 comment=defconf interface=ether15
add bridge=BR1 comment=defconf interface=ether16
add bridge=BR1 comment=defconf interface=ether17
add bridge=BR1 comment=defconf interface=ether18
add bridge=BR1 comment=defconf interface=ether19
add bridge=BR1 comment=defconf interface=ether20
add bridge=BR1 comment=defconf interface=ether21
add bridge=BR1 comment=defconf interface=ether22
add bridge=BR1 comment=defconf interface=ether23
add bridge=BR1 comment=defconf interface=ether24
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
sfp-sfpplus1
add bridge=BR1 comment=defconf interface=sfp-sfpplus2
/interface bridge vlan
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=10
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=20
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=30
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=40
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=99
/interface list member
add interface=ether1 list=WAN
add interface=MGMT_VLAN list=VLAN
add interface=TRUST_VLAN list=VLAN
add interface=GUEST_VLAN list=VLAN
add interface=CAMERA_VLAN list=VLAN
add interface=IOT_VLAN list=VLAN
add interface=MGMT_VLAN list=MGMT
/ip address
add address=172.30.0.1/16 interface=MGMT_VLAN network=172.30.0.0
add address=172.20.0.1/24 interface=TRUST_VLAN network=172.20.0.0
add address=172.21.0.1/16 interface=GUEST_VLAN network=172.21.0.0
add address=172.22.0.1/16 interface=CAMERA_VLAN network=172.22.0.0
add address=172.23.0.1/16 interface=IOT_VLAN network=172.23.0.0
/ip dhcp-client
add comment="to connect isp modem+router" interface=BR1
/ip dhcp-server network
add address=172.20.0.0/24 dns-server=172.20.0.1 gateway=172.20.0.1
add address=172.21.0.0/16 dns-server=172.21.0.1 gateway=172.21.0.1
add address=172.22.0.0/16 dns-server=172.22.0.1 gateway=172.22.0.1
add address=172.23.0.0/16 dns-server=172.23.0.1 gateway=172.23.0.1
add address=172.30.0.0/16 dns-server=172.30.0.1 gateway=172.30.0.1
/ip dns
set allow-remote-requests=yes servers=9.9.9.9
/ip firewall filter
add action=accept chain=input comment="Allow Estab & Related Input" \
connection-state=established,related
add action=accept chain=input comment="Allow VLAN" in-interface-list=VLAN
add action=accept chain=input comment="Allow MGMT_VLAN Full Access" \
in-interface=MGMT_VLAN
add action=drop chain=input comment=Drop
add action=log chain=forward comment="Log traffic from WAN back to VLAN" \
in-interface-list=WAN out-interface-list=VLAN
add action=log chain=forward comment="Log traffic from BR1 to WAN" \
in-interface=BR1 out-interface-list=WAN
add action=log chain=forward comment="Log traffic from BR1 to VLAN" \
in-interface=BR1 out-interface-list=VLAN
add action=accept chain=forward comment="Allow Estab & Related Forward" \
connection-state=established,related
add action=drop chain=forward comment="Drop Camera from Internet" \
in-interface=CAMERA_VLAN out-interface-list=WAN
add action=log chain=forward comment="VLAN -> WAN HTTPS log" \
connection-state=new dst-port=443 in-interface-list=VLAN \
out-interface-list=WAN protocol=tcp
add action=log chain=forward comment="VLAN -> BR1 HTTPS log" \
connection-state=new disabled=yes dst-port=443 in-interface-list=VLAN \
out-interface=BR1 protocol=tcp
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 comment=Drop
/ip firewall nat
add action=masquerade chain=srcnat comment="Default masquerade" \
out-interface-list=WAN
/system clock
set time-zone-name=America/Los_Angeles
/system identity
set name=router
/system routerboard settings
set boot-os=router-os
/16:
# sep/02/2023 15:38:10 by RouterOS 7.6
# software id = KI2X-PHFS
#
# model = CRS326-24G-2S+
# serial number = XXX
/interface bridge
add admin-mac=aa:bb:cc:dd:ee:ff auto-mac=no comment=defconf name=BR1 \
vlan-filtering=yes
/interface vlan
add interface=BR1 name=CAMERA_VLAN vlan-id=30
add interface=BR1 name=GUEST_VLAN vlan-id=20
add interface=BR1 name=IOT_VLAN vlan-id=40
add interface=BR1 name=MGMT_VLAN vlan-id=99
add interface=BR1 name=TRUST_VLAN vlan-id=10
/interface list
add name=WAN
add name=VLAN
add name=MGMT
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip hotspot profile
set [ find default=yes ] html-directory=hotspot
/ip pool
add name=TRUST_POOL ranges=172.20.0.2-172.20.255.254
add name=GUEST_POOL ranges=172.21.0.2-172.21.255.254
add name=CAMERA_POOL ranges=172.22.0.2-172.22.255.254
add name=IOT_POOL ranges=172.23.0.2-172.23.255.254
add name=MGMT_POOL ranges=172.30.0.2-172.30.255.254
/ip dhcp-server
add address-pool=TRUST_POOL interface=TRUST_VLAN name=TRUST_DHCP
add address-pool=GUEST_POOL interface=GUEST_VLAN name=GUEST_DHCP
add address-pool=CAMERA_POOL interface=CAMERA_VLAN name=CAMERA_DHCP
add address-pool=IOT_POOL interface=IOT_VLAN name=IOT_DHCP
add address-pool=MGMT_POOL interface=MGMT_VLAN name=MGMT_DHCP
/port
set 0 name=serial0
/interface bridge port
add bridge=BR1 comment=defconf interface=ether1
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether2
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether3
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether4
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether5
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether6
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether7
add bridge=BR1 comment=defconf interface=ether8
add bridge=BR1 comment=defconf interface=ether9
add bridge=BR1 comment=defconf interface=ether10
add bridge=BR1 comment=defconf interface=ether11
add bridge=BR1 comment=defconf interface=ether12
add bridge=BR1 comment=defconf interface=ether13
add bridge=BR1 comment=defconf interface=ether14
add bridge=BR1 comment=defconf interface=ether15
add bridge=BR1 comment=defconf interface=ether16
add bridge=BR1 comment=defconf interface=ether17
add bridge=BR1 comment=defconf interface=ether18
add bridge=BR1 comment=defconf interface=ether19
add bridge=BR1 comment=defconf interface=ether20
add bridge=BR1 comment=defconf interface=ether21
add bridge=BR1 comment=defconf interface=ether22
add bridge=BR1 comment=defconf interface=ether23
add bridge=BR1 comment=defconf interface=ether24
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
sfp-sfpplus1
add bridge=BR1 comment=defconf interface=sfp-sfpplus2
/interface bridge vlan
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=10
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=20
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=30
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=40
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=99
/interface list member
add interface=ether1 list=WAN
add interface=MGMT_VLAN list=VLAN
add interface=TRUST_VLAN list=VLAN
add interface=GUEST_VLAN list=VLAN
add interface=CAMERA_VLAN list=VLAN
add interface=IOT_VLAN list=VLAN
add interface=MGMT_VLAN list=MGMT
/ip address
add address=172.30.0.1/16 interface=MGMT_VLAN network=172.30.0.0
add address=172.20.0.1/16 interface=TRUST_VLAN network=172.20.0.0
add address=172.21.0.1/16 interface=GUEST_VLAN network=172.21.0.0
add address=172.22.0.1/16 interface=CAMERA_VLAN network=172.22.0.0
add address=172.23.0.1/16 interface=IOT_VLAN network=172.23.0.0
/ip dhcp-client
add comment="to connect isp modem+router" interface=BR1
/ip dhcp-server network
add address=172.20.0.0/16 dns-server=172.20.0.1 gateway=172.20.0.1
add address=172.21.0.0/16 dns-server=172.21.0.1 gateway=172.21.0.1
add address=172.22.0.0/16 dns-server=172.22.0.1 gateway=172.22.0.1
add address=172.23.0.0/16 dns-server=172.23.0.1 gateway=172.23.0.1
add address=172.30.0.0/16 dns-server=172.30.0.1 gateway=172.30.0.1
/ip dns
set allow-remote-requests=yes servers=9.9.9.9
/ip firewall filter
add action=accept chain=input comment="Allow Estab & Related Input" \
connection-state=established,related
add action=accept chain=input comment="Allow VLAN" in-interface-list=VLAN
add action=accept chain=input comment="Allow MGMT_VLAN Full Access" \
in-interface=MGMT_VLAN
add action=drop chain=input comment=Drop
add action=log chain=forward comment="Log traffic from WAN back to VLAN" \
in-interface-list=WAN out-interface-list=VLAN
add action=log chain=forward comment="Log traffic from BR1 to WAN" \
in-interface=BR1 out-interface-list=WAN
add action=log chain=forward comment="Log traffic from BR1 to VLAN" \
in-interface=BR1 out-interface-list=VLAN
add action=accept chain=forward comment="Allow Estab & Related Forward" \
connection-state=established,related
add action=drop chain=forward comment="Drop Camera from Internet" \
in-interface=CAMERA_VLAN out-interface-list=WAN
add action=log chain=forward comment="VLAN -> WAN HTTPS log" \
connection-state=new dst-port=443 in-interface-list=VLAN \
out-interface-list=WAN protocol=tcp
add action=log chain=forward comment="VLAN -> BR1 HTTPS log" \
connection-state=new disabled=yes dst-port=443 in-interface-list=VLAN \
out-interface=BR1 protocol=tcp
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 comment=Drop
/ip firewall nat
add action=masquerade chain=srcnat comment="Default masquerade" \
out-interface-list=WAN
/system clock
set time-zone-name=America/Los_Angeles
/system identity
set name=router
/system routerboard settings
set boot-os=router-os
No DHCP/static:
# sep/02/2023 15:56:32 by RouterOS 7.6
# software id = KI2X-PHFS
#
# model = CRS326-24G-2S+
# serial number = XXX
/interface bridge
add admin-mac=aa:bb:cc:dd:ee:ff auto-mac=no comment=defconf name=BR1 \
vlan-filtering=yes
/interface vlan
add interface=BR1 name=CAMERA_VLAN vlan-id=30
add interface=BR1 name=GUEST_VLAN vlan-id=20
add interface=BR1 name=IOT_VLAN vlan-id=40
add interface=BR1 name=MGMT_VLAN vlan-id=99
add interface=BR1 name=TRUST_VLAN vlan-id=10
/interface list
add name=WAN
add name=VLAN
add name=MGMT
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip hotspot profile
set [ find default=yes ] html-directory=hotspot
/ip pool
add name=TRUST_POOL ranges=172.20.0.2-172.20.255.254
add name=GUEST_POOL ranges=172.21.0.2-172.21.255.254
add name=CAMERA_POOL ranges=172.22.0.2-172.22.255.254
add name=IOT_POOL ranges=172.23.0.2-172.23.255.254
add name=MGMT_POOL ranges=172.30.0.2-172.30.255.254
/ip dhcp-server
add address-pool=GUEST_POOL interface=GUEST_VLAN name=GUEST_DHCP
add address-pool=CAMERA_POOL interface=CAMERA_VLAN name=CAMERA_DHCP
add address-pool=IOT_POOL interface=IOT_VLAN name=IOT_DHCP
add address-pool=MGMT_POOL interface=MGMT_VLAN name=MGMT_DHCP
/port
set 0 name=serial0
/interface bridge port
add bridge=BR1 comment=defconf interface=ether1
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether2
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether3
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether4
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether5
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether6
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
ether7
add bridge=BR1 comment=defconf interface=ether8
add bridge=BR1 comment=defconf interface=ether9
add bridge=BR1 comment=defconf interface=ether10
add bridge=BR1 comment=defconf interface=ether11
add bridge=BR1 comment=defconf interface=ether12
add bridge=BR1 comment=defconf interface=ether13
add bridge=BR1 comment=defconf interface=ether14
add bridge=BR1 comment=defconf interface=ether15
add bridge=BR1 comment=defconf interface=ether16
add bridge=BR1 comment=defconf interface=ether17
add bridge=BR1 comment=defconf interface=ether18
add bridge=BR1 comment=defconf interface=ether19
add bridge=BR1 comment=defconf interface=ether20
add bridge=BR1 comment=defconf interface=ether21
add bridge=BR1 comment=defconf interface=ether22
add bridge=BR1 comment=defconf interface=ether23
add bridge=BR1 comment=defconf interface=ether24
add bridge=BR1 comment=defconf frame-types=admit-only-vlan-tagged interface=\
sfp-sfpplus1
add bridge=BR1 comment=defconf interface=sfp-sfpplus2
/interface bridge vlan
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=10
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=20
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=30
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=40
add bridge=BR1 tagged=\
BR1,ether2,ether3,ether4,ether5,ether6,ether7,sfp-sfpplus1 vlan-ids=99
/interface list member
add interface=ether1 list=WAN
add interface=MGMT_VLAN list=VLAN
add interface=TRUST_VLAN list=VLAN
add interface=GUEST_VLAN list=VLAN
add interface=CAMERA_VLAN list=VLAN
add interface=IOT_VLAN list=VLAN
add interface=MGMT_VLAN list=MGMT
/ip address
add address=172.30.0.1/16 interface=MGMT_VLAN network=172.30.0.0
add address=172.20.0.1/16 interface=TRUST_VLAN network=172.20.0.0
add address=172.21.0.1/16 interface=GUEST_VLAN network=172.21.0.0
add address=172.22.0.1/16 interface=CAMERA_VLAN network=172.22.0.0
add address=172.23.0.1/16 interface=IOT_VLAN network=172.23.0.0
/ip dhcp-client
add comment="to connect isp modem+router" interface=BR1
/ip dhcp-server network
add address=172.21.0.0/16 dns-server=172.21.0.1 gateway=172.21.0.1
add address=172.22.0.0/16 dns-server=172.22.0.1 gateway=172.22.0.1
add address=172.23.0.0/16 dns-server=172.23.0.1 gateway=172.23.0.1
add address=172.30.0.0/16 dns-server=172.30.0.1 gateway=172.30.0.1
/ip dns
set allow-remote-requests=yes servers=9.9.9.9
/ip firewall filter
add action=accept chain=input comment="Allow Estab & Related Input" \
connection-state=established,related
add action=accept chain=input comment="Allow VLAN" in-interface-list=VLAN
add action=accept chain=input comment="Allow MGMT_VLAN Full Access" \
in-interface=MGMT_VLAN
add action=drop chain=input comment=Drop
add action=log chain=forward comment="Log traffic from WAN back to VLAN" \
in-interface-list=WAN out-interface-list=VLAN
add action=log chain=forward comment="Log traffic from BR1 to WAN" \
in-interface=BR1 out-interface-list=WAN
add action=log chain=forward comment="Log traffic from BR1 to VLAN" \
in-interface=BR1 out-interface-list=VLAN
add action=accept chain=forward comment="Allow Estab & Related Forward" \
connection-state=established,related
add action=drop chain=forward comment="Drop Camera from Internet" \
in-interface=CAMERA_VLAN out-interface-list=WAN
add action=log chain=forward comment="VLAN -> WAN HTTPS log" \
connection-state=new dst-port=443 in-interface-list=VLAN \
out-interface-list=WAN protocol=tcp
add action=log chain=forward comment="VLAN -> BR1 HTTPS log" \
connection-state=new disabled=yes dst-port=443 in-interface-list=VLAN \
out-interface=BR1 protocol=tcp
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 comment=Drop
/ip firewall nat
add action=masquerade chain=srcnat comment="Default masquerade" \
out-interface-list=WAN
/system clock
set time-zone-name=America/Los_Angeles
/system identity
set name=router
/system routerboard settings
set boot-os=router-os
All three settings yield the same result:
- There has lots of traffic in “VLAN → BR1 HTTPS log”
- There has no traffic:
i) from WAN back to VLAN
ii) from BR1 to WAN
iii) BR1 to VLAN
- I can ping 8.8.8.8 from my router
- I CANNOT ping 8.8.8.8 from my host: 100% package lost
In addition, I’ve found something new when I desperately troubleshooting this problem. I can ping the IP(192.168.1.X) of my router’s WAN IP, which is from my ISP’s router+modem subnet, from my host, but I cannot ping the gateway IP(192.168.1.Y) of my ISP’s router+modem IP from my host(100% package lost). Of course, I can ping the gateway IP(192.168.1.Y) of my ISP’s router+modem IP from my router.
So it seems something drop the package from VLAN to WAN or not routing from VLAN to WAN. I don’t see any packages in my log from VLAN to WAN.
Any ideas please?
PS:
- I 100% agree I should try a basic setup first before moving to a more complicated setup.
- I won’t say the metalLB(https://github.com/metallb/metallb) is battle tested, but the metalLB’s setup is working well for lots of people. At least it works fine with opnsense without VLAN. (I want to try out mikrotik’s VLAN first if possible)