weird behavior using Netwatch commands & scripts

If I modify my script to disable more than 4 NAT rules it stops working and says “no such item (4)”

This is what works:


/ip firewall nat disable 1,2,3,4
/ip dns set servers=9.9.9.11,149.112.112.11
/tool e-mail send to="address@gmail.com" subject="Pi-hole is down on $[/system clock get time]."

If I use /ip firewall nat disable 1,2,3,4**,5,6** it stops working and gives the error, even though I have 7 NAT rules, the command works from terminal.

http://forum.mikrotik.com/t/read-before-creating-yet-another-new-my-script-does-not-work-topic/122693/1

Try another way of using your pi-hole. No need to disable the NAT rule

http://forum.mikrotik.com/t/how-do-i-allow-dns-traffic-from-one-vlan-to-another/131382/10

I use unbound on my Pihole, and only these NAT rules works when there’s a hard coded DNS on a client:

/ip firewall nat add chain=dstnat action=accept src-address=192.168.1.250
/ip firewall nat add action=dst-nat chain=dstnat dst-port=53 in-interface=bridge protocol=tcp to-addresses=192.168.1.1
/ip firewall nat add action=dst-nat chain=dstnat dst-port=53 in-interface=bridge protocol=udp to-addresses=192.168.1.1

But you are right, I don’t have to disable NAT rules when my Pihole goes down, thanks!