I have a MT connected with ppppoe. I have two networks on ether2 and ether3. I have a DNS server(Adguard Home) on ether2(10.20.50.X/24). Here's my Network diagram.
The problem is my DNS server is recieving DNS request from the gateway IP of the Network, not from the device/client connected to the network.
Here's my router config
Code: Select all
/interface pwr-line
set [ find default-name=pwr-line1 ] disabled=yes
/interface wireless
set [ find default-name=wlan1 ] band=2ghz-b/g/n country=bangladesh frequency=\
auto hide-ssid=yes installation=indoor mode=ap-bridge radio-name="" ssid=\
P2P wireless-protocol=802.11 wps-mode=disabled
/interface ethernet
set [ find default-name=ether3 ] arp=reply-only name=ether
set [ find default-name=ether2 ] arp=reply-only
set [ find default-name=ether4 ] arp=reply-only
/interface pppoe-client
add add-default-route=yes disabled=no interface=ether4 name=pppoe user=\
131
/interface list
add name=LAN
add name=WAN
add name=MGMT
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip pool
add name=dhcp_LAN ranges=10.20.51.60-10.20.51.70
add name=dhcp_SERVER ranges=10.20.50.10-10.20.50.15
/ip dhcp-server
add address-pool=dhcp_LAN disabled=no interface=ether lease-time=10h name=\
DHCP-AP
add address-pool=dhcp_SERVER disabled=no interface=ether2 lease-time=10h \
name=DHCP-SERVER
/routing bgp instance
set default as=100 disabled=yes
/snmp community
set [ find default=yes ] addresses=0.0.0.0/0 disabled=yes
/ip neighbor discovery-settings
set discover-interface-list=none
/interface detect-internet
set detect-interface-list=all
/interface list member
add interface=pppoe list=WAN
add interface=ether list=LAN
add interface=ether2 list=LAN
add interface=ether1 list=MGMT
add interface=ether1 list=LAN
/ip address
add address=10.20.50.70/24 interface=ether2 network=10.20.50.0
add address=10.20.51.30/24 interface=ether network=10.20.51.0
add address=10.10.10.1/30 network=10.10.10.0
/ip cloud
set update-time=no
/ip cloud advanced
set use-local-address=yes
/ip dhcp-server network
add address=10.20.50.0/24 dns-server=10.20.50.15 gateway=10.20.50.70 netmask=\
24
add address=10.20.51.0/24 dns-server=10.20.50.15 gateway=10.20.51.30 netmask=\
32
/ip dns
set servers=10.20.50.15,8.8.8.8
/ip firewall nat
add action=masquerade chain=srcnat src-address=\
10.20.50.0/24
add action=masquerade chain=srcnat src-address=\
10.20.51.0/24
I tried natting like this
everything works fine. but i can't reach my AP's(AP1, AP2) from RPi Network(ether2-10.20.50.X/24). The AP's are normal home router, I disabled the DHCP server in order to use them as AP Mode.add action=masquerade chain=srcnat src-address=10.20.0.0/16 out-interface=pppoe
I also need to reach my APs.