Hi Everyone,
Hoping someone can help me out here as been struggling and going rond in circles as i read up and try and figure it out, so any help would be much appreciated.
I use 4 WANs (eth5,6,7,8) and 1 LAN (eth1 - which has 4 pools 192.168.10.x, 11.x,12.x and 13.x)
Stations login via pppoe and get assigned an ip from 10,11,12 or 13 depending on the WAN they are assigned to. The problem I have is that only stations within the subnet
can contact each other, so 10.x cannot contact 11.x, 12.x etc I want to setup a NAS on 10.10 so everyone on 10,11,12 and 13 can access it. When i use ping from the router itself
i can ping all pools.
Most of my code below:
/interface bridge
add admin-mac=E4:8D:8=4C:0F:A1:A1 auto-mac=no comment=
“created from master port” name=bridge1 protocol-mode=none
/interface ethernet
set [ find default-name=ether1 ] name=ether1-lan speed=100Mbps
set [ find default-name=ether7 ] name=ether7-wan3 speed=100Mbps
set [ find default-name=ether8 ] name=ether8-wan4 speed=100Mbps
/interface pppoe-client
add add-default-route=yes disabled=no interface=ether5-wan1 name=pppoe-wan1 user=A7@XXX.com
add add-default-route=yes disabled=no interface=ether6-wan2 name=pppoe-wan2 user=A6@XXX.com
add add-default-route=yes disabled=no interface=ether7-wan3 name=pppoe-wan3 user=A4@XXX.com
add add-default-route=yes disabled=no interface=ether8-wan4 name=pppoe-wan4 user=A5@XXX.com
/interface vlan
add interface=bridge1 name=vlan10 vlan-id=10
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip hotspot profile
add hotspot-address=192.168.10.1 name=hsprof1
/ip pool
add name=pool1-wan1 ranges=192.168.10.30-192.168.10.254
add name=pool2-wan2 ranges=192.168.11.5-192.168.11.254
add name=pool3-wan3 ranges=192.168.12.5-192.168.12.254
add name=pool4-wan4 ranges=192.168.13.5-192.168.13.254
add name=pool5-wan5 ranges=192.168.14.5-192.168.14.254
/ip dhcp-server
add address-pool=pool1-wan1 authoritative=after-2sec-delay disabled=no
interface=bridge1 lease-time=23h59m59s name=dhcp1
/ppp profile
add dns-server=8.8.8.8 local-address=192.168.10.1 name=profile1-ppp remote-address=pool1-wan1
/interface bridge port
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether1-lan
/interface pppoe-server server
add authentication=chap default-profile=profile1-ppp disabled=no interface=
bridge1 max-mru=1400 max-mtu=1400 mrru=1600 service-name=service1
/interface pptp-server server
set default-profile=profile1-ppp enabled=yes
/ip address
add address=113.79.50.139 interface=ether5-wan1 network=113.79.120.139
add address=113.79.50.124 interface=ether6-wan2 network=113.79.120.124
add address=113.79.50.0 interface=ether7-wan3 network=113.79.120.0
add address=113.79.50.1 interface=ether8-wan4 network=113.79.120.1
add address=192.168.6.21 interface=ether4-wan5 network=192.168.6.0
add address=192.168.10.1/24 comment=lan interface=bridge1 network=192.168.10.0
/ip dhcp-server network
add address=192.168.10.0/24 gateway=192.168.10.1
/ip dns
set allow-remote-requests=yes cache-size=5000KiB servers=221.132.112.8,8.8.8.8
/ip firewall mangle
add action=mark-routing chain=prerouting comment=“wan 2 routing”
new-routing-mark=wan2 passthrough=yes src-address=192.168.11.0/24
add action=mark-routing chain=prerouting comment=“wan 3 routing”
new-routing-mark=wan3 passthrough=yes src-address=192.168.12.0/24
add action=mark-routing chain=prerouting comment=“wan 4 routing”
new-routing-mark=wan4 passthrough=yes src-address=192.168.13.0/24
add action=mark-routing chain=prerouting comment=“wan 5 routing”
new-routing-mark=wan5 passthrough=yes src-address=192.168.14.0/24
add action=mark-connection chain=input in-interface=ether5-wan1
new-connection-mark=WAN1_conn passthrough=yes
add action=mark-connection chain=input in-interface=ether6-wan2
new-connection-mark=WAN2_conn passthrough=yes
add action=mark-connection chain=input in-interface=ether7-wan3
new-connection-mark=WAN3_conn passthrough=yes
add action=mark-connection chain=input in-interface=ether8-wan4
new-connection-mark=WAN4_conn passthrough=yes
add action=mark-connection chain=input in-interface=ether4-wan5
new-connection-mark=WAN5_conn passthrough=yes
add action=mark-routing chain=output connection-mark=WAN1_conn
new-routing-mark=to_WAN1 passthrough=yes
add action=mark-routing chain=output connection-mark=WAN2_conn
new-routing-mark=to_WAN2 passthrough=yes
add action=mark-routing chain=output connection-mark=WAN3_conn
new-routing-mark=to_WAN3 passthrough=yes
add action=mark-routing chain=output connection-mark=WAN4_conn
new-routing-mark=to_WAN4 passthrough=yes
add action=mark-routing chain=output connection-mark=WAN5_conn
new-routing-mark=to_WAN5 passthrough=yes
add action=accept chain=prerouting dst-address=113.79.120.139 in-interface=bridge1
add action=accept chain=prerouting dst-address=113.79.120.124 in-interface=bridge1
add action=accept chain=prerouting dst-address=113.79.120.0 in-interface=bridge1
add action=accept chain=prerouting dst-address=113.79.120.1 in-interface=bridge1
add action=accept chain=prerouting dst-address=192.168.6.0/24 in-interface=bridge1
add action=mark-connection chain=prerouting dst-address-type=!local
in-interface=bridge1 new-connection-mark=WAN1_conn passthrough=yes
per-connection-classifier=both-addresses-and-ports:5/0
add action=mark-connection chain=prerouting dst-address-type=!local
in-interface=bridge1 new-connection-mark=WAN2_conn passthrough=yes
per-connection-classifier=both-addresses-and-ports:5/1
add action=mark-connection chain=prerouting dst-address-type=!local
in-interface=bridge1 new-connection-mark=WAN3_conn passthrough=yes
per-connection-classifier=both-addresses-and-ports:5/2
add action=mark-connection chain=prerouting dst-address-type=!local
in-interface=bridge1 new-connection-mark=WAN4_conn passthrough=yes
per-connection-classifier=both-addresses-and-ports:5/3
add action=mark-connection chain=prerouting dst-address-type=!local
in-interface=bridge1 new-connection-mark=WAN5_conn passthrough=yes
per-connection-classifier=both-addresses-and-ports:5/4
add action=mark-routing chain=prerouting connection-mark=WAN1_conn
in-interface=bridge1 new-routing-mark=to_WAN1 passthrough=yes
add action=mark-routing chain=prerouting connection-mark=WAN2_conn
in-interface=bridge1 new-routing-mark=to_WAN2 passthrough=yes
add action=mark-routing chain=prerouting connection-mark=WAN3_conn
in-interface=bridge1 new-routing-mark=to_WAN3 passthrough=yes
add action=mark-routing chain=prerouting connection-mark=WAN4_conn
in-interface=bridge1 new-routing-mark=to_WAN4 passthrough=yes
add action=mark-routing chain=prerouting connection-mark=WAN5_conn
in-interface=bridge1 new-routing-mark=to_WAN5 passthrough=yes
add action=change-mss chain=forward disabled=yes new-mss=clamp-to-pmtu
passthrough=yes protocol=tcp tcp-flags=syn
/ip firewall nat
add action=passthrough chain=unused-hs-chain comment=
“place hotspot rules here” disabled=yes
add action=masquerade chain=srcnat out-interface=ether5-wan1
add action=masquerade chain=srcnat out-interface=ether6-wan2
add action=masquerade chain=srcnat out-interface=ether7-wan3
add action=masquerade chain=srcnat out-interface=ether8-wan4
add action=masquerade chain=srcnat out-interface=ether4-wan5
add action=masquerade chain=srcnat comment=“masquerade wan 1” src-address=192.168.10.0/24
add action=masquerade chain=srcnat comment=“masquerade wan 2” src-address=192.168.13.0/24
add action=masquerade chain=srcnat comment=“masquerade wan 3” src-address=192.168.12.0/24
add action=masquerade chain=srcnat comment=“masquerade wan 4” src-address=192.168.11.0/24
add action=masquerade chain=srcnat comment=“masquerade wan 5” src-address=192.168.14.0/24
add action=masquerade chain=srcnat out-interface=pppoe-wan2
add action=masquerade chain=srcnat out-interface=pppoe-wan3
add action=masquerade chain=srcnat out-interface=pppoe-wan4
add action=masquerade chain=srcnat out-interface=pppoe-wan1
/ip route
add comment=“wan 2 ppp routing” distance=1 gateway=pppoe-wan2 routing-mark=wan2
add comment=“wan 3 ppp routing” distance=1 gateway=pppoe-wan3 routing-mark=wan3
add comment=“wan 4 ppp routing” distance=1 gateway=pppoe-wan4 routing-mark=wan4
add comment=“wan 5 ppp routing” distance=1 gateway=192.168.6.1 routing-mark=wan5
add check-gateway=ping distance=1 gateway=pppoe-wan1 routing-mark=to_WAN1
add check-gateway=ping distance=1 gateway=pppoe-wan2 routing-mark=to_WAN2
add check-gateway=ping distance=1 gateway=pppoe-wan3 routing-mark=to_WAN3
add check-gateway=ping distance=1 gateway=pppoe-wan4 routing-mark=to_WAN4
add check-gateway=ping distance=1 gateway=192.168.6.1 routing-mark=to_WAN5
add check-gateway=ping distance=1 gateway=pppoe-wan1
add check-gateway=ping distance=2 gateway=pppoe-wan2
add check-gateway=ping distance=3 gateway=pppoe-wan3
add check-gateway=ping distance=4 gateway=pppoe-wan4
add check-gateway=ping distance=5 gateway=192.168.6.1