Database Migration
  • Dark
  • PDF

Database Migration

  • Dark
  • PDF

Run DB Migration

A migration script must be manually run to import properties.json configuration into the MongoDB database. After the migration script is run once, the properties.json file will only be referenced by IAP for the MongoDB connection properties, with IAP referencing the database for all other configuration properties.

Note: Any desired changes to properties.json should be made before proceeding.

  1. Enter the directory containing the IAP migration script.

    cd /opt/pronghorn/current/node_modules/@itential/pronghorn-core/migration_scripts
  2. Run the migration script. Key/value pairs after --userInputs can be changed to match the RabbitMQ deployment.

    Example Options

    # Option 1) RabbitMQ installed on IAP server with default port.
    node migratePropertiesToDatabase.js --userInputs protocol=amqp port=5672 hosts="localhost"
    # Option 2) RabbitMQ installed on standalone server.
    node migratePropertiesToDatabase.js --userInputs protocol=amqp port=5672 hosts=""

The properties.json file will be updated during the migration script run to only contain the MongoDB connection properties, with all other configuration parameters stored within the default MongoDB database named pronghorn. The migration script creates a backup of the original properties.json file that will look similar to properties_b4b03d30-ad00-4f61-bd9e-7953968ef8c4.json.

Migration Script Help Options

The migratePropertiesToDatabase.js script has a --help option that allows you to use the script in unattended mode with the --userInputs option. The following example depicts the various help options available and briefly explains how they are used.

Figure 1: Help Options


Option to Ignore Schema Errors

The migration script also has an option that will ignore schema validation errors during migration. Run the migratePropertiesToDatabase.js script, but this time add -i to the parameters.

node migratePropertiesToDatabase.js -i

Start IAP

After running the migration script:

  1. Start IAP and set to auto-start on server reboot.

    systemctl enable --now pronghorn
  2. Confirm IAP has started successfully.

    $ systemctl status pronghorn
    pronghorn.service - Itential Automation Platform Service
      Loaded: loaded (/etc/systemd/system/pronghorn.service; enabled; vendor preset: disabled)
      Active: active (running) since Thu 2020-01-02 20:37:43 UTC; 4min 29s ago
    Main PID: 30774 (Pronghorn core)

Note: The journalctl -u pronghorn -f command may be run to monitor IAP logs during startup or general usage.

Access IAP Web UI

IAP may be accessed by browsing to http://<SERVER_HOSTNAME>:3000/login with <SERVER_HOSTNAME> being either the hostname or IP address of the server that IAP is installed on. The default user is admin@pronghorn with password admin.

Note: To access applications, be sure to give admin@pronghorn user access to all roles from the IAPAdmin EssentialsAuthorization interface.

Figure 2: Admin Essentials → Authorization


Changing your password will log you out immediately. Use the new password to log back in.
First name must have atleast 2 characters. Numbers and special characters are not allowed.
Last name must have atleast 1 characters. Numbers and special characters are not allowed.
Enter a valid email
Enter a valid password
Your profile has been successfully updated.