Difference between revisions of "Manual:Flashfig"

From MikroTik Wiki
Jump to: navigation, search
(Flashfig Description: Add Fix)
(Troubleshoot)
 
(28 intermediate revisions by 6 users not shown)
Line 1: Line 1:
 
{{Versions|v4}}
 
{{Versions|v4}}
  
== Flashfig Description ==
+
==Description==
  
Flashfig applies MikroTik RouterOS '''configuration''' to any RouterBOARD within '''3 seconds'''. You can "flashfig" batch of routers, the only thing you need - '''connect''' it to network and '''power''' RouterBOARD.
+
Flashfig is an application for mass router configuration. It can be used by MikroTik distributors, ISPs or any other companies who need to apply RouterOS configuration to many routers in the shortest possible time.  
  
 +
Flashfig applies MikroTik RouterOS '''configuration''' to any RouterBOARD within '''3 seconds'''. You can "flashfig" a batch of routers, the only thing you need is to '''connect''' RouterBOARD to a Layer 2 network running Netinstall and to '''power''' a Flashfig enabled RouterBOARD up.
  
Flashfig runs on a Windows computer, Flashfig is available from [http://www.mikrotik.com/download/netinstall-4.5b.zip Netinstall].
+
Running Netinstall in Flashfig mode only runs on a Windows computer and Netinstall is available from the [http://www.mikrotik.com/download downloads] page.
  
 +
Flashfig mode is supported by all [http://www.routerboard.com RouterBOARDs]. It works between a Windows computer running Netinstall with Flasfig mode enabled and a RouterBOARD in the same broadcast domain (direct Layer 2 Ethernet network connection is required).
  
Flashfig configuration is reloaded after reset-configuration was applied to a router.
+
Flashfig support is enabled on every new RouterBOARD manufactured since March 2010 by default from the factory. For older models, Flashfig can be enabled via RouterBOOT or from MikroTik RouterOS console (E.g. /system routerboard settings set boot-device=flash-boot-once-then-nand or /system routerboard settings set boot-device=flash-boot).
  
 +
After Flashfig is used once on a brand new RouterBOARD, it is disabled on further boots to avoid unwanted reconfiguration at a later time. To use Flashfig a second time on the same router, you need to enable '''flash-boot''' in Bootloader settings.
  
Flashfig is supported by all [http://www.routerboard.com RouterBOARDs]. It works between computer with Flashfig and RouterBOARD in the same broadcast domain (direct Ethernet network connection is required).  
+
If RouterOS ''reset-configuration'' command is used later, Flashfig configuration is not loaded, but the RouterOS default configuration. (To permanently overwrite factory default configuration, use Netinstall process not FlashFig). Therefore using Flashfig is normally a '''one time''' process.
  
 
+
Flashfig diagram shows the procedure of Flashfig,
Flashfig support is enabled on every RouterBOARD by default, which came from factory (RouterBOARD purchased recently). Alternatively Flashfig could be enabled via RouterBOOT or from MikroTik RouterOS console.
+
[[File:Flashfigdiagramm.png]]
  
 
==Flashfig Example==
 
==Flashfig Example==
 
   
 
   
This is a step by step example of how to use Flashfig to set typical MikroTik RouterOS configuration to RouterBOARD.  
+
This is a step by step example of how to use the Flashfig process to apply a chosen MikroTik RouterOS configuration to a 'factory fresh' RouterBOARD.  
  
 
====Introduction====
 
====Introduction====
  
Flashfig is available from Netinstall,
+
Flashfig is an option available from within the Netinstall program,
  
 
[[File:Flashfig.png]]
 
[[File:Flashfig.png]]
Line 31: Line 34:
 
The Windows computer must be equipped with the following ports and contain the following files:
 
The Windows computer must be equipped with the following ports and contain the following files:
  
* Ethernet port;  
+
* A working Ethernet port;  
* The .rsc file(s) with MikroTik RouterOS configuration (the same as export/import file);  
+
* Valid .rsc file(s) with MikroTik RouterOS configuration similar to an export/import file. (Be aware of the text editor's treatment of CR/LF characters and test that the config has no errors when normally applied onto an identical version of RouterOS before applying via Flashfig as run time errors will not be visible!);
* The latest NetInstall/Flashfig program available from the [http://www.mikrotik.com/download.html downloads] page;
+
* Always use the latest NetInstall/Flashfig program available from the [http://www.mikrotik.com/download.html downloads] page;
  
 
The RouterBOARD:
 
The RouterBOARD:
  
* Boot-device configured as '''flash-boot''' or '''flash-boot-once-then-nand''';  
+
* Flashfig is supported by the first time boot of RouterBOARD;
  
 
====Pre-Configuration====
 
====Pre-Configuration====
Line 44: Line 47:
  
 
* Run Flashfig;
 
* Run Flashfig;
* Prepare '''.rsc''' file, '''.rsc''' file is regular/import file, it accepts valid MikroTik RouterOS CLI commands. You can create .rsc file by any text-editor program (Notepad, Texteditor, TextEdit, Microsoft Word, OpenOffice Writer);
+
* Prepare '''.rsc''' file, '''.rsc''' file is regular/import file, it accepts valid MikroTik RouterOS CLI commands. You can create .rsc file with any text-editor program (Notepad, Notepad++, Texteditor, TextEdit, Microsoft Word, OpenOffice Writer);
  
 
[[File:Flashfig2.png]]
 
[[File:Flashfig2.png]]
  
* Assign '''Boot Client Address''', which should be address from the same subnet as configured on laptop Ethernet interface,
+
* Assign '''Boot Client Address''', which should be an address within the same subnet as that configured on the computer's Ethernet interface,
  
 
[[File:Flashfig3.png]]
 
[[File:Flashfig3.png]]
  
* '''Browse''' for '''.rsc''' MikroTik RouterOS configuration file to apply to RouterBOARD, highlight the file and '''Select''' to approve it,
+
* '''Browse''' for '''.rsc''' MikroTik RouterOS configuration file to apply to the RouterBOARD, highlight the file and '''Select''' to approve it,
  
 
[[File:Flashfig4.png]]
 
[[File:Flashfig4.png]]
  
* Activate Flashfig server, now it is ready to Flashfig. Note, any RouterBOARD will be flashfiged within the network, which is powered on with boot-device configured to '''flash-boot''' or '''flash-boot-once-then-nand''',
+
* Activate Flashfig server, now it is ready to Flashfig. Note, any RouterBOARD will be flashfig'ed within the network, when they are powered on with boot-device configured to '''flash-boot''' or '''flash-boot-once-then-nand''',
 
 
  
 
[[File:Flashfig5.png]]
 
[[File:Flashfig5.png]]
Line 63: Line 65:
 
=====RouterBOARD=====
 
=====RouterBOARD=====
  
* Flashfig mode is enabled on every RouterBOARD from factory by default.
+
* Flashfig mode is enabled on every RouterBOARD from factory by default, which means '''no configuration''' is required on RouterBOARD.
  
 
* If Flashfig is not enabled on your router, access the RouterBOARD with Winbox/Console and set the configuration,
 
* If Flashfig is not enabled on your router, access the RouterBOARD with Winbox/Console and set the configuration,
Line 77: Line 79:
 
====Connect====
 
====Connect====
  
Connect RouterBOARD with enabled boot-device as '''flash-boot''' and Windows computer with '''activated''' Flashfig to the same network or switch.
+
Connect Ether1 of RouterBOARD and Flashfig computer to the same Local Area Network. (Exceptions are RB1xxx and CCR devices which support network booting from last ethernet port).
 
 
Make sure Windows firewall on computer is not blocking the communications.
 
  
 
====Run Flashfig====
 
====Run Flashfig====
  
* Plug power for RouterBOARD
+
* Plug in power for RouterBOARD
  
 
* Check the status on Flashfig program,
 
* Check the status on Flashfig program,
  
[[File:Flashfig5.png]]
+
[[File:Flashfig6.png]]
 +
 
 +
Messages log shows "Flashfigged" and RouterBOARD should repeatedly make the morse code sound for the character "/" ("_.._." and flash the LED - it is now safe to unplug / power down the router.
 +
 
 +
* Flashfig '''configuration''' was applied to the RouterBOARD and  it is '''ready''' to be used in production with this new config.
 +
 
 +
==Troubleshoot==
 +
 
 +
===Flashfig Configuration is not applied===
 +
If all procedures went successfully, but RouterOS configuration from .rsc file is not applied. Add :delay 20s to *.rsc configuration file. The reason might be, that configuration script is executed before RouterOS is booted successfully.
  
Log is showing that router is Flashfigged and RouterBOARD will make sound/LED signal.
+
===Flashfig can not find router is not applied===
Unplug the RouterBOARD.
+
Make sure that computer on which Flashfig is running has only one network interface active.
  
* Flashig applied configuration to the RouterBOARD and you can use it in production.
 
  
 +
===Not enough flash space, ignoring===
 +
Flashfig configuration maximum file size is up to 4000 bytes, otherwise program will return error as above.
 
[[Category:Manual]]
 
[[Category:Manual]]
 
[[Category:Routerboard]]
 
[[Category:Routerboard]]

Latest revision as of 14:50, 27 June 2018

Version.png

Applies to RouterOS: v4

Description

Flashfig is an application for mass router configuration. It can be used by MikroTik distributors, ISPs or any other companies who need to apply RouterOS configuration to many routers in the shortest possible time.

Flashfig applies MikroTik RouterOS configuration to any RouterBOARD within 3 seconds. You can "flashfig" a batch of routers, the only thing you need is to connect RouterBOARD to a Layer 2 network running Netinstall and to power a Flashfig enabled RouterBOARD up.

Running Netinstall in Flashfig mode only runs on a Windows computer and Netinstall is available from the downloads page.

Flashfig mode is supported by all RouterBOARDs. It works between a Windows computer running Netinstall with Flasfig mode enabled and a RouterBOARD in the same broadcast domain (direct Layer 2 Ethernet network connection is required).

Flashfig support is enabled on every new RouterBOARD manufactured since March 2010 by default from the factory. For older models, Flashfig can be enabled via RouterBOOT or from MikroTik RouterOS console (E.g. /system routerboard settings set boot-device=flash-boot-once-then-nand or /system routerboard settings set boot-device=flash-boot).

After Flashfig is used once on a brand new RouterBOARD, it is disabled on further boots to avoid unwanted reconfiguration at a later time. To use Flashfig a second time on the same router, you need to enable flash-boot in Bootloader settings.

If RouterOS reset-configuration command is used later, Flashfig configuration is not loaded, but the RouterOS default configuration. (To permanently overwrite factory default configuration, use Netinstall process not FlashFig). Therefore using Flashfig is normally a one time process.

Flashfig diagram shows the procedure of Flashfig, Flashfigdiagramm.png

Flashfig Example

This is a step by step example of how to use the Flashfig process to apply a chosen MikroTik RouterOS configuration to a 'factory fresh' RouterBOARD.

Introduction

Flashfig is an option available from within the Netinstall program,

Flashfig.png

Requirements

The Windows computer must be equipped with the following ports and contain the following files:

  • A working Ethernet port;
  • Valid .rsc file(s) with MikroTik RouterOS configuration similar to an export/import file. (Be aware of the text editor's treatment of CR/LF characters and test that the config has no errors when normally applied onto an identical version of RouterOS before applying via Flashfig as run time errors will not be visible!);
  • Always use the latest NetInstall/Flashfig program available from the downloads page;

The RouterBOARD:

  • Flashfig is supported by the first time boot of RouterBOARD;

Pre-Configuration

Windows Computer
  • Run Flashfig;
  • Prepare .rsc file, .rsc file is regular/import file, it accepts valid MikroTik RouterOS CLI commands. You can create .rsc file with any text-editor program (Notepad, Notepad++, Texteditor, TextEdit, Microsoft Word, OpenOffice Writer);

Flashfig2.png

  • Assign Boot Client Address, which should be an address within the same subnet as that configured on the computer's Ethernet interface,

Flashfig3.png

  • Browse for .rsc MikroTik RouterOS configuration file to apply to the RouterBOARD, highlight the file and Select to approve it,

Flashfig4.png

  • Activate Flashfig server, now it is ready to Flashfig. Note, any RouterBOARD will be flashfig'ed within the network, when they are powered on with boot-device configured to flash-boot or flash-boot-once-then-nand,

Flashfig5.png

RouterBOARD
  • Flashfig mode is enabled on every RouterBOARD from factory by default, which means no configuration is required on RouterBOARD.
  • If Flashfig is not enabled on your router, access the RouterBOARD with Winbox/Console and set the configuration,
/system routerboard settings set boot-device=flash-boot

or use more preferable option,

/system routerboard settigs set boot-device=flash-boot-once-then-nand

Your router is now ready for Flashfig.

Connect

Connect Ether1 of RouterBOARD and Flashfig computer to the same Local Area Network. (Exceptions are RB1xxx and CCR devices which support network booting from last ethernet port).

Run Flashfig

  • Plug in power for RouterBOARD
  • Check the status on Flashfig program,

Flashfig6.png

Messages log shows "Flashfigged" and RouterBOARD should repeatedly make the morse code sound for the character "/" ("_.._." and flash the LED - it is now safe to unplug / power down the router.

  • Flashfig configuration was applied to the RouterBOARD and it is ready to be used in production with this new config.

Troubleshoot

Flashfig Configuration is not applied

If all procedures went successfully, but RouterOS configuration from .rsc file is not applied. Add :delay 20s to *.rsc configuration file. The reason might be, that configuration script is executed before RouterOS is booted successfully.

Flashfig can not find router is not applied

Make sure that computer on which Flashfig is running has only one network interface active.


Not enough flash space, ignoring

Flashfig configuration maximum file size is up to 4000 bytes, otherwise program will return error as above.