Migrator syntax example 2

Here, the Niagara console window has been left at the default N4.0 directory (say when you open it from the Niagara 4 Console Start menu shortcut), and absolute source and target directories are specified.

C:\Niagara\Niagara-4.1.xx.xx>n4mig -t:2 -log:finer C:\niagara\niagara-3.8.111\backups\backup_BigSup_150210_1730.dist F:\migratedStations\BigSupN4

The migration tool processes the station BigSup backup .dist file from the absolute source path given, as a Supervisor station, and the target output goes to the absolute “F: drive” location given (perhaps a removable USB drive) in folder migratedStations\BigSupN4. The log file (migration report) is also created there, but with finer level detail than the default.

So in this case, migration produces these items:

  • F:\migratedStations\BigSupN4 (complete station folder)
  • F:\migratedStations\BigSupN4_miglog_150212_0835.txt (log file with finer detail)

The folder F:\migratedStations must already exist, or else the command fails. The specified target station folder BigSupN4 must not already exist, or else the command fails—it never overwrites an existing station folder (unless the -o option switch is included in the command).

The target station folder determines the migrated station’s name, unlike when not specifying a target station folder. In this example, the output station folder (and N4 station name), will be BigSupN4, which is different than the one in the source backup .dist file. Generally this is not recommended when migrating stations, especially if they are part of a NiagaraNetwork of stations, as other stations store remote station names (in configurations of NiagaraStation and StationRecipient components, as two examples).

Therefore, when a migrating a station from an AX-3.8 station backup .dist file, it is typically best to specify only the source .dist file name, and not specify any target. An example of this is described in Migrator syntax example 1. After the migration tool completes, if needed, you can then manually copy or move the migrated station folder to another location. For example, you could copy the migrated station folder under a previously created “F:drive” location, say F:\migratedStations.