Use the MMG Schema Sync Utility

Before you use the MMG Schema Sync Utility, the following prerequisites must be met:
  • You must have shell access to the OFS MMG server.
  • You require the following information:
    • Workspace name, for example, WS123
    • Login user name, for example mmgadmin
    • Locale, for example, en_US
    • V_SERVICE_ID - This is the wallet alias that corresponds to the target schema and can be found in the tenant_connection_info table.
    • Optional, a space-separated list of tables in the required format for synchronizing specific tables.

Synchronize Tables with the MMG Schema Sync Utility

Use the following commands to synchronize the database schema meta data between a work space’s source and target environments in any of the following scenarios:
  • After manually creating or altering tables in the target schema outside OFS MMG.
  • Whenever you observe errors related to missing or duplicate objects while editing the workspace or data sourcing in OFS MMG.
  • As part of a scheduled reconciliation or maintenance process in environments with frequent manual DBA operations.
  1. To synchronize specific tables, run the following code:

    ./sync_source_target_schema_utility.sh WORKSPACE_NAME LOGIN_USER LOCALE V_SERVICE_ID -t \"<name of tables space separated>\"

    Or

    To synchronize all tables, run the following code:

    ./sync_source_target_schema_utility.sh MYWORKSPACE mmgadmin en_US MY_SERVICE_ID

    Note:

    The correct value for V_SERVICE_ID, the wallet alias, must be determined from your environment’s tenant_connection_info table. This might not always be your schema or data store name.
  2. After you accept the request, the utility returns a status: received message.
  3. Check the log file that can be found in mmg-service.logs for further details such as ensuring that the synchronization has completed and to diagnose errors.
  4. After running the utility, you will be able to add the newly synchronized tables in OFS MMG through the UI as part of data sourcing or workspace editing.

Limitations and Best Practices

  • The utility does not validate your parameters, workspace, service ID, etc.. Incorrect entries will not cause visible errors in the command line, but it will result in sync failure, hence it is recommended to view the log file in mmg-service.logs.
  • For best results, double-check all the inputs and consult your system administrator for the correct V_SERVICE_ID.
  • Large schema or multiple tables may take time to synchronize.

Troubleshooting

  • If your synchronization status displays the status: received message but your changes don’t appear in OFS MMG, you must check the log file in mmg-service.logs for details.
  • Verify that the provided V_SERVICE_ID matches your intended target schema connection.
  • When in doubt, consult the technical team or system administrator for reviewing the log file or further troubleshooting actions.