But how can I sync only some of the rules?
I was thinking one way to go would be to prefix the comment of all the rules that I want to sync with the text "sync". So on the source router the script could be
Code: Select all
/ip firewall filter export file="EXPORT.FW_filters" [find comment ~"^sync.*"]
Code: Select all
/tool fetch mode=tftp address=MAIN_ROUTER_IP src-path=EXPORT.FW_filter.rsc
#TODO: do some errorcheck here. Abort script if file not downloaded ok
/ip firewall filter remove [find comment ~"^sync.*"]
/import file=EXPORT.FW_Lists.rsc
/file remove EXPORT.FW_Lists.rsc
I found some examples that were 10 years old where they used
Code: Select all
export from=1,4