Few days ago, My friend came in my office for checking mikrotik server. He opened terminal from winbox and added some rules using script of firewall , the he went at IP>firewall and said me that these are the rules of “filter rules” and “NAT” which I have added.
I notice that from that rules my mikrotik become v.fast and its performance become more improved.
My friend who had done it is now out of country.
Now I want to get that script which he had written on my terminal for further use. Is it possible to copy that script from my mikrotik by some way???
Yes. You write this in terminal, and you’ll see commands that could recreate the rules your friend wrote. The commands may not be “1:1” what he wrote, but they’re sure to have the exact same effect, if written into the terminal of this MikroTik router, or another one with the same RouterOS version.
If the rules are too much to just look at on screen, you can write the commands into a file instead, like for example:
/ip firewall export file="firewall_rules.txt"
After you have that, you can use either FTP to get your file, or with Winbox, go to “Files”, click the file, click the “Copy” button above the list, then paste the file wherever on your computer you wish it to be. You can then use any text editor (e.g. Notepad) to open the file, and see all commands. Don’t forget to read the fine manual to find out what is doing what.
You can export all configuration by just going to the root, i.e.
/export
Open a terminal, and type “?” to see all submenus from your current position. Type the menu and then press “?” to see all submenus of that menu, and so on. In addition to the menus, you’ll also notice the “export” command is always in the list there.