APM

Upgrade or Update APM to V5.2.1.0.0

Upgrading or updating and configuring APM includes completing multiple steps, which are outlined in the tables in this section. This section of the documentation provides all the information that you need to upgrade or update and configure the basic system architecture to V5.2.1.0.0.

After you have completed these steps, you will need to perform additional steps required to upgrade any modules that were deployed on your previous version. If you have purchased additional modules for use with APM, then you will also need to consult the first-time deployment documentation for each of those modules and features.

The person responsible for completing each task may vary within in your organization. We recommend, however, that the steps be performed in relatively the same order in which they are listed in the table.

Note: We do not recommend upgrading from V4.6.2.0.0 through V4.6.4.0.0 to V5.0.0.0.0.
The following table provides you the reference to procedures to upgrade from an earlier APM version to the latest version.
Important: With APM V5.2.0.0.0, a new utility, BinaryToJSONConvertor, is provided to serialize and deserialize data into JSON format. If you are upgrading the database to version V5.2.0.0.0, you must first run the utility prior to upgrading your database. For more information, see Run the BinaryToJSONConvertor Utility.
Upgrade fromUpgrade toProcedure
V5.2.xV5.2.1.0.0Upgrade from any version V5.2.0.0.0 through V5.2.0.1.0
V5.1.xV5.2.1.0.0Upgrade from any version V5.1.0.0.0 through V5.1.3.1.0
V5.0.xV5.2.1.0.0Upgrade from any version V5.0.1.0.0 through V5.0.6.0.0
V4.6.2 or a later V4.6.x releaseV5.2.1.0.0Upgrading or updating to the V5.2.1.0.0 is a two-step process. You need to first upgrade to APM V5.0.x and then follow the steps to upgrade to V5.2.1.0.0.
Note: For more information on upgrading to APM V5.0.x, refer to the Upgrade documentation for the corresponding version. You can view version specific documentation here.
V4.6.1.x or earlierV5.2.1.0.0Upgrading or updating to the V5.2.1.0.0 is a two-step process. You need to first upgrade to APM V5.0.x and then follow the steps to upgrade to V5.2.1.0.0.
Note: For more information on upgrading to APM V5.0.x, refer to the Upgrade documentation for the corresponding version. You can view version specific documentation here.

Upgrade from any version V5.2.0.0.0 through V5.2.0.1.0

To apply this release, complete the following steps:

Procedure

  1. On each APM Server, including both dedicated and supporting instances, uninstall the APM Server Components..
  2. Login to the GE Vernova Redis server.
  3. Connect to Redis using the redis-cli.
  4. Run flushall to clear Redis across the cluster.
  5. On each APM Server, including both dedicated and supporting instances, install the APM Server Components..
  6. Upgrade the APM Database.
  7. Install this release to mobile devices using an iOS, Android, or Windows operating system by following the standard documentation for installing the GE Digital APM mobile application.

Upgrade from any version V5.1.0.0.0 through V5.1.3.1.0

To apply this release, complete the following steps:

Procedure

  1. On each APM Server, including both dedicated and supporting instances, uninstall the APM Server Components..
  2. Login to the GE Vernova Redis server.
  3. Connect to Redis using the redis-cli.
  4. Run flushall to clear Redis across the cluster.
  5. On each APM Server, including both dedicated and supporting instances, install the APM Server Components..
  6. Upgrade the APM Database.
  7. Install this release to mobile devices using an iOS, Android, or Windows operating system by following the standard documentation for installing the GE Digital APM mobile application.

Upgrade from any version V5.0.1.0.0 through V5.0.6.0.0

To apply this release, complete the following steps:

Procedure

  1. On each APM Server, including both dedicated and supporting instances, uninstall the APM Server Components..
  2. Login to the GE Vernova Redis server.
  3. Connect to Redis using the redis-cli.
  4. Run flushall to clear Redis across the cluster.
  5. On each APM Server, including both dedicated and supporting instances, install the APM Server Components..
  6. Upgrade the APM Database.
  7. Install this release to mobile devices using an iOS, Android, or Windows operating system by following the standard documentation for installing the GE Digital APM mobile application.

Upgrade or Update the APM Server to V5.2.1.0.0

About This Task

The following instructions provide details on upgrading or updating the APM Server and Add-ons software on a 64-bit APM Server machine.

Procedure

  1. Create a backup of the data contained in the following directories:
    • C:\Program Files\Meridium
    • C:\ProgramData\Meridium
  2. Uninstall the APM Server and Add-ons component.
  3. Ensure that WebDAV Publishing is deactivated. To verify this, in the Server Manager, in the Local Server workspace, in the Roles and Features section, ensure that WebDAV Publishing is not present in the list.
  4. Install and configure the APM Server software and Add-ons.
    • If you are upgrading from any version prior to V4.3.0.0.0, then you have successfully upgraded the APM Server to V5.2.1.0.0, and you should proceed to the next step in the upgrade section of the Upgrade or Update APM to V5.2.1.0.0 topic.
    • If you are updating from version V4.3.0.0.0 through V4.4.0.0.4, then complete the following steps to update your data sources:
      Important: After updating the APM Server to V5.2.1.0.0, you must also update the data sources to which you want to connect to APM. This action can be completed via the Meridium Package Deployer window, which should have appeared automatically after completing step g. If you need to access this window manually, then navigate to the folder C:\Program Files\Meridium\Upgrade\DBUpgrade\Meridium.Package.Deployer, and then open the file Meridium.Package.Deployer.exe.

Uninstall APM Server Components After the Initial Installation

About This Task

If you need to uninstall APM Server on a machine after the initial installation is complete, you can run the APM Server installer again to uninstall the software.

Note: IIS will be reset automatically by the installer before the installation process begins.

Procedure

  1. On the APM Server machine, via the Control Panel, access the Programs and Features window.
  2. In the grid, select the APM Server item, and then select Uninstall.

    The APM-Server installer appears, displaying the Preparing Setup screen, which contains a progress bar. After completion, a message appears, asking if you want to remove the selected application and all of its features.



  3. Select Yes

    The Setup Status screen appears, displaying a progress bar. After the application and all of its features are removed, the Uninstall Complete screen appears.



  4. Select Finish

    The APM Server installer closes.

Upgrade the APM Adapter for SSRS to APM

About This Task

The following instructions assume that you were using the 64-bit APM Adapter for SSRS in your previous version. If you were using the 32-bit APM Adapter for SSRS, you will need to uninstall the older 32-bit version and install the new 64-bit version on a 64-bit SQL Server Report Server.

Procedure

  1. On the SQL Server Report Server, in the APM distribution package, navigate to the folder Setup\SSRS.
  2. Open the file setup.exe.

    A message appears, asking if you want to allow the installer to make changes to your machine.

  3. Select Yes.

    The Meridium APM SSRS installer appears, displaying the welcome screen.



  4. Select Next.
    The License Agreement screen appears.

  5. Read the License Agreement, and then, if you agree to the terms, select the I accept the terms of the license agreement check box. Then, select Next.
    The Select Installation Location screen appears, prompting you to select the location where the software will be installed. By default, the software will be installed in the following folder: C:\Program Files\Meridium.

  6. If you are satisfied with the default location where the software will be installed, select Next.

    -or-

    If you want to change the location where the software will be installed, select Change, and then navigate to the location where you want to install the software. The folder path that you select will be displayed in place of the default folder path. When you are satisfied with the installation location, select Next.

    The SQL Server Reporting Server Instances screen appears.



  7. Select the instance of SQL Server Reporting Services that you want to use, and then select Next.

    The Complete the Installation screen appears.

  8. Select Install.
    The Setup Status screen appears, which displays a progress bar that shows the progress of the installation process. After the progress bar reaches the end, a message appears, indicating that your server is being configured. After your server is configured, the Installation is Complete screen appears.

  9. Select Finish.

    The installer closes.

What To Do Next

Upgrade the APM Database to V5.2.1.0.0

Important: You need to first upgrade to APM V5.0.x. and then follow the steps to upgrade to V5.1.1.0.0. You can view the APM V5.0x documentation here.

To upgrade your APM database, you will use the APM Database Migrator.

During the database upgrade process, the APM Database Migrator will:

  1. Update the baseline database content in your database with the updated baseline APM database content.
  2. Compare your public database content to the baseline APM database content, and then:
    • Retain any customized database content.
    • Replace any database content that you have not customized in your database with the updated baseline database content.
  3. Record every event in the database upgrade to the console's standard output.
  4. Report errors as they occur to the console's standard error.
  5. Display a confirmation message, Migration complete, when the database upgrade process is complete.
The progress of this process will be displayed while it is running. When it is finished, a Migrations complete message will appear, otherwise, the migrator will exit early with any error information sent to the standard output/error.
Note: The information in this note applies only to SQL Server. Altering the database recovery mode to SIMPLE for the duration of the upgrade will limit disk space consumption on the APM Database Server and may be necessary to successfully upgrade larger databases. The database upgrade executes many transactions, all of which are logged by SQL Server. If the database is in FULL recovery mode, SQL Server must retain all of these transactions, causing the transaction log file to become very large. This could potentially cause the upgrade to fail by consuming all available disk space or exceeding the size limit for the file.

Upgrade failure of this kind can be safely avoided by temporarily modifying the database recovery mode to SIMPLE before running the upgrade and then resetting it to FULL after the upgrade. Your database administrator can use the following commands to modify the database recovery mode:

To put the database in SIMPLE recovery mode:

 USE [master] 

GO

ALTER DATABASE [mydb] SET RECOVERY SIMPLE WITH NO_WAIT
GO
                

To put the database in FULL recovery mode:


USE [master]
GO

ALTER DATABASE [mydb] SET RECOVERY FULL WITH NO_WAIT

GO

For more information about SQL Server database recovery modes, consult the Microsoft documentation.

Upgrade workflow

The table in this section lists the prerequisite tasks that must be completed before you initiate the database upgrade process. These instructions assume that yourAPM Server and APM Database Server machines meet the APM hardware and software requirements. You can use the Database Upgrade Manager to upgrade a database from any version V3.4.0 SP3 or later to your target version. Details on upgrading from a starting version that is earlier than V3.4.0 SP3 are not provided in this documentation. For more information on upgrading your database from a version earlier than V3.4.0 SP3, contact the APM Professional Services department.

Step

Task

Notes

1

Complete all steps before Upgrade the Meridium Enterprise APM Database Server in the upgrade APM to APM workflow.

This step is required. For example, if you are upgrading your system to APM, you should upgrade your dedicated APM Server to APM before attempting to upgrade your database to the APM database version. Doing so ensures that your machine contains the latest database content file, which is a compressed folder containing the content of the baseline APM database for the target database version.

2

Read and understand how your customizations will be protected during the upgrade process.

You will need to understand how your content is protected to determine what, if any, content you should export from your pre-upgrade database before initiating the database upgrade process.

3

Create a backup of your database.

You should always back up the database before beginning any upgrade process. If any problems occur during the upgrade, the database can then be restored to its original state from the backup copy.

4Log in to Oracle Server 12.2 as a privileged user, and then run the following command: SQL> GRANT SELECT ANY DICTIONARY TO <user>;

...where <user> is the name of the user that you created when you created the APM Oracle Schema on the APM Database Server.

5

Using a backup copy of your database, perform the upgrade in a test environment.

We recommend that you perform the upgrade in a test environment so that you can assess any issues that you may encounter and correct them before upgrading your database in a production environment.

6Log in to SQL*Plus (or equivalent) as the schema owner, and then run the following command: SQL> EXEC MI_DDL.CRT_SIDX_SI_MI_GEOD_GD

This step is required only if both of the following are true:

  • You plan to use an Oracle Database Server.

    -and-

  • You are upgrading from a version of APM version V4.2.0.0 or later.
7Run the BinaryToJSON utility. This step is required only if:
  • You are upgrading from 4.x, run this utility after upgrading to 5.0.x and before upgrading the APM database server for 5.2.

    -or-

  • You are upgrading from 5.0.x or later, run this utility before upgrading the APM database server for 5.2.
8 Perform the upgrade in the production environment.

This step is required.

Note: Before you upgrade your database in a production environment, all the issues that were discovered during the test upgrade must be resolved. Otherwise, the resulting state of your database could be unstable.
9Log in to Oracle Server 12.2 as a privileged user, and then run the following command: SQL> REVOKE SELECT ANY DICTIONARY FROM <user>;

...where <user> is the name of the user that you created when you created the APM Oracle Schema on the APM Database Server.

10If your pre-upgrade database employed Enterprise Data Filtering and you want to convert your Enterprise Data Filtering values to Site Reference Keys, consult a member of the APM Professional Services department for more information.

This step is optional.

If your pre-upgrade database did not employ Enterprise Data Filtering or you do not want to convert your existing Enterprise Data Filtering values to Site Reference Keys, then skip this step.

11 Modify each custom family that you do not want to be enabled for site filtering.

During the upgrade, custom families are set to be enabled for site filtering. For each custom family that you do not want to be enabled for site filtering, you must modify the family by clearing the Enable Site Filtering check box in the Information section of the workspace for the family.

12Confirm that Site Reference Keys were populated correctly during the upgrade. Modify the site assignments for records as needed.

This step is required.

To support site filtering, a APM Default site was added to the Site Reference family during the database upgrade.

If the APM Default site is the only site in your Site Reference family, then records of families that are enabled for site filtering are assigned to it.

If there are two sites in your Site Reference family (i.e., the APM Default site and one other site), then records of families that are enabled for site filtering are assigned to the site that is not APM Default site.

During the upgrade, additional logic is used, based on a record’s specific relationships with other records, to assign a site for each record belonging to a family that is enabled for site filtering.

Note:

The manner in which Site Reference Keys are spread across families to assign sites to records can vary from module to module. If you have questions about how Site Reference Keys were populated during the upgrade, contact the APM Professional Services department.

If a record's site assignment could not be populated automatically during the upgrade, then the record is designated as a global record (i.e., it is not assigned to any specific site).

For some records, the site assignment may need to be modified by a Super User.

13 Verify that users' site assignments and default sites are correct . Assign default sites to any users who do not have one.

This step is required.

To support site filtering, a APM Default site was added to the Site Reference family.

If the APM Default site is the only site in your Site Reference family, then all users are assigned to it, and it is set as their default site.

If there are two sites in your Site Reference family (i.e., the APM Default site and one other site), then all users are assigned to the site that is not APM Default site, and the site that is not APM Default site is set as each user's default site.

If there are three or more sites in your Site Reference family (i.e., the APM Default site and two or more other sites), then no default site is set for users. If there are three or more sites in your Site Reference family, then you must verify site assignments and assign a default site for each user.

14If the system from which you upgraded utilized an Oracle Database Server, then configure the APM Server for Oracle components.This step is required only if the system from which you upgraded utilized an Oracle Database Server.
15 Remove database notification elements from the database.This step is not mandatory, but is recommended by APM.
16In APM, build the search index.This step is not mandatory, but is recommended by APM.

About Customized Database Content Protection

Illustration of content protection

Consider a scenario where Datasheet A exists in the baseline APM database and you want to upgrade a database in which Datasheet A has been customized (e.g., you added a new field). The following diagram illustrates what the two databases would contain in this case, where the squares represent the unchanged baseline datasheet and the hexagon indicates the same baseline datasheet with your customizations.

Note: Note: As indicated by this illustration, in the baseline APM database, the public and baseline versions of an item are always identical.

When this database is upgraded to the new database version, only the baseline version of Datasheet A will be replaced in your database, as illustrated in the following diagram.

In this way, all your custom changes are retained. Likewise, however, your database will not contain the baseline changes that APM delivers in a given release . For this reason, you will want to determine which database items will be retained in your database so that you can determine which baseline changes your database will not contain after you upgrade. With that information, you can determine whether you want to:

  • Continue to use your database content as is, without APM's changes

-or-

  • Apply APM's changes manually to your customized database content.

Database content replacement versus protection

In general, you can assume that all the custom changes you have made to your database content will be retained in your upgraded database. In addition, you can assume that for any custom change that is protected in your database, your database will not contain any baseline changes that APM delivers for that item in a given release. In other words, if APM delivers updated changes to the baseline version of an item that you have customized in your database, you will not receive those changes because your custom changes will take precedence over the baseline changes. As a result, you should evaluate each baseline change that is delivered to determine if you want to apply those changes to your database content.

Note: Note: In a given release, there may be exceptions to the content protection criteria. These exceptions will be communicated via the APM Release Notes for that version. For example, if APM changes a baseline field caption, it is possible that APM can choose to forcibly replace that field caption in your database even if you have customized that field caption already.

You can use the Database Comparison Tool (in pre-upgrade mode) to determine what content will be protected in your database. The output of this tool indicates:

  • The baseline APM database content that has been updated in the target version (i.e., content that includes new baseline changes from APM).

    -and-

  • Among the content that has been updated in the baseline APM database, that which you have customized in your pre-upgrade database.

Using a combination of the results from the Database Comparison Tool and your understanding of the content protection criteria, you can predict which baseline database content changes will not be available in your upgraded database. For example, consider the following scenario in which the Database Comparison Tool indicates that the baseline query Available Recommendations has been updated in the baseline APM database for your target version and that you have customized the Available Recommendations query in your pre-upgrade database.

In this case, you can assume that your upgraded database will contain:

  • Your public version of the Available Recommendations query with all your customizations (in the Public Catalog folder).

  • The updated baseline Available Recommendations query only in the Baseline folder.

Before you upgrade your database, you can use the Database Comparison Tool to view the specific differences between the Available Recommendations query in the baseline APM database for the target version and the same baseline query as it exists in your current version. For example, you could see that APM has added the Asset Description column to the baseline query. At this point, you can decide whether or not you want to either manually apply that change to your custom query after you upgrade or manually replace your public query with the baseline query in the Baseline folder.

Protected database content

The following table lists the types of content that exist in your database and indicates whether customizations to an existing baseline item of that type will be protected during the database upgrade process.

For items in which your customizations will not be protected during an upgrade, to maintain your customizations, you will need to export your customized items from your pre-upgrade database using the Import/Export tool, and then import them into the upgraded database. Alternatively, you can customize the items again, manually, in the upgraded database.

For some attributes of families and family fields, APM may make a change in the baseline database that will be applied to your database, regardless of whether you have customized that item or not. In these cases, the affected content will not be protected. APM will, however, communicate such changes via the release notes for that version (i.e., in the content changes section). For example, if a family caption changes in the baseline database, your database should contain this change. Therefore, if you have made changes to the same family's caption, your customization will be overwritten. You can, however, obtain the baseline content after you upgrade your database.

Baseline Database Content TypeProtected?Notes

Family attributes (Entity and Relationship)

Associated Pages

Yes

Associated Pages are considered one database item per family. This means that if you customize one Associated Page (of many), the database upgrade process will consider all the Associated Pages for that family as customized.

Family description

Yes

None

Family captions

Yes

None

ID Template

Yes

None

Family help text

Yes

None

Datasheets

 

Yes

A single datasheet is considered one database item. This means that if you customize any attribute of a datasheet, the database upgrade process will consider the entire datasheet as customized.

Field attributes

  • Caption

  • Description

  • Help text

  • Override parent flag

  • ID flag

  • UTC

Yes

The UTC property will be protected based on whether records exist for the family to which the field belongs. If records exist in a family, the field property will be protected. In other words, if APM sets the UTC property in a baseline field to True and you already have records in the family to which that field belongs, you will not receive the updated property setting automatically.

Catalog Items

Metric Views

No

Baseline Metric Views are always overwritten with the updated baseline Metric View.

Queries

Yes

None

Reports

Yes

None

Graphs

Yes

None

Security Groups

Security Group caption

Yes

None

Security Group ID

Yes

None

Security Group description

Yes

None

Security Group privileges

No

Baseline Security Group privileges are always overwritten with the updated baseline Security Group privileges.

Records and links between records

Records

Yes (with some exceptions)

After baseline records for a given family exist in your database, the records in that family will never be overwritten or updated during the database upgrade process, even if you have not customized them in any way. This means that if APM delivers updates to the existing baseline records or adds additional baseline records in a given family, you will not receive those changes by default. If this occurs, you can choose to perform an additional step to manually obtain the new records or revert your existing records to baseline.

There are, however, several families whose records are not protected in this way. The following baseline families are considered recurring exceptions to the rule that all records and links are protected. This means that the database upgrade process will overwrite the baseline records in these families. In other words, all the baseline records in the following families will always be overwritten in your database with the updated baseline records:

  • Analysis Services Cube

  • CMMS System

  • Device

  • Device Data Presentation

  • Device Mapping

  • Device Mapping Family

  • Device Mapping Field

  • Pipe Properties

  • Security Group

  • Calibration Template Defaults

This means that if you have customized any baseline record in one of the families in the preceding list, because all the baseline records are overwritten, your changes will be overwritten.

Links between records

Yes

When the records are protected, the relationships that link the records together are also maintained with that record.

Groups of records and links that make up a single entity (e.g., Baseline Risk Matrix)

Yes

A group of records and links that make up a single entity, also known as a composite entity, is treated as one entity for the purposes of the database upgrade process and content protection. After such an entity exists in your database, it will never be overwritten or updated during the database upgrade process, even if you have not customized the records and links in any way.

State Configuration

State Configuration Roles

No

Baseline State Configuration Roles are always overwritten with the updated baseline State Configuration Roles.

State Configuration Role Description

Yes

None

State Configuration Role Caption

Yes

None

State Role Security Group assignments

Yes

None

Strategy Rules and Strategies

Yes

None

Other content

System Codes and System Code Tables

Yes

None

Preferences

Yes

None

UOMs and UOM Conversion Sets

Yes

None

Scheduled Items

Yes

None

Rules Library Projects

Yes

None

Run the BinaryToJSONConvertor Utility

About This Task

Important: With APM V5.2.0.0.0, a new utility, BinaryToJSONConvertor, is provided to serialize and deserialize data into JSON format. If you are upgrading the database to version V5.2.0.0.0, you must first run the utility prior to upgrading your database. For more information, see

Procedure

  1. On the dedicated APM Server machine, access the following folder: <APM installation folder>\DbUpg.
  2. Extract the contents of the BinaryToJSONConvertor.zip file, and extract to a folder (for example, BinaryToJSONConvertor).
  3. Run the command prompt as an administrator and navigate to the BinaryToJSONConvertor folder.
  4. Run the ConvertBinaryToJson.dll and pass the following arguments:
    • Database type
    • Database connection string
    The following line of code shows a sample command for a SQL database, with encryption set as False:
    dotnet ConvertBinaryToJson.dll "sqlserver" "Data Source=localhost;Database=V5000000_BASE;Integrated Security=SSPI;Encrypt=False"
    The following line of code shows a sample command for a SQL database, with encryption set as True:
    dotnet ConvertBinaryToJson.dll "sqlserver" "Data Source=localhost;Database=V5000000_BASE;Integrated Security=SSPI;Encrypt=True" (if database is encrypted)
    The following line of code shows a sample command for an Oracle database:
    dotnet ConvertBinaryToJson.dll "oracle" "DATA SOURCE=ORCL;USER ID=V5020000_TEST;PASSWORD=V5020000_TEST"
    After the conversion is complete, the message Conversion Completed appears in the log files.
    Note: You may get a few warnings in the logs when you run the utility, as shown in the following image. These warnings pertain to outdated preferences that could not be converted and are no longer in use. The logs are for informational purposes only.

Initiate the Database Upgrade Process

About This Task

When you initiate the database upgrade process, the APM Database Migrator will begin upgrading your database through a process that consists of the following steps:
  1. Comparing available migrations against migrations already applied to your database.
  2. Applying any new migrations to your database in alpha-numeric order.

The most common migrations will load baseline database content into your database and apply that content to your database while protecting your customized items according to the content protection process.

The following instructions assume that your dedicated APM Server already contains the version of the APM software that corresponds to the database version to which you want to upgrade your database, and that you are ready to upgrade your database in either a test or production environment.

Important: The database upgrade process can take several hours to complete, depending on the size of the database, available memory, and other factors.

Procedure

  1. On the dedicated APM Server machine, access the following folder: <APM installation folder>\DbUpg
  2. Extract the contents of the Production_XXXXXX.zip file, where, XXXXXX is the latest release number.
    The following subfolders appears:
    • _Setup
    • Migrations: Contains the new database content that you must apply to the database.
    • Migrator: Contains the Migrator tool to upgrade the database.
    Ensure that all the three folders are in the same folder.
  3. In the Migrator folder, access the appsettings.json file.
  4. Depending on whether you are using the SQL or the Oracle database, provide the database connection details in the corresponding section, and save the appsettings.json file.
    For SQL, the connection details appear as shown in the following image:

    Note: Because of an update in a third-party application, the SQL client uses encryption by default.
    If your database is not encrypted, change the DBConnStr parameter to:
    "Data Source=localhost;Database=V5000000_BASE;Integrated Security=SSPI;Encrypt=False;"
    If your database is encrypted, change the DBConnStr parameter from:
    "Data Source=localhost;Database=V5000000_BASE;Integrated Security=SSPI;Encrypt=False;"
    to:
    "DbConnStr": "Data Source=localhost;Database=V5000000_BASE;Integrated Security=SSPI;Encrypt=True;"
    For Oracle, the connection details appear as shown in the following image:

    Important: For Oracle, the datasource must point to the TNS alias.
  5. Open command prompt as an administrator, and navigate to the Migrator folder.
  6. Run the Migrator.dll file by entering the following command:
    dotnet Migrator.dll
    The upgrade process begins. After the upgrade is successful, a message appears in the command prompt, stating that the migration is complete.
  7. After you have successfully upgraded your database and sent the upgrade logs to the GE Vernova Support Team https://digitalsupport.ge.com/, restart the APM Server.

What To Do Next

The next step in the APM Database Server upgrade workflow varies, depending on whether you initiated the upgrade in a test or production environment.

Configure the APM Server for Oracle Components

About This Task

When installing versions of Meridium APM prior to V4.0.0.0, you were instructed to modify the following files on the dedicated APM Server machine to bind the 64-bit .Net Framework to the Oracle.DataAccess component:

  • C:\WINDOWS\Microsoft.NET\Framework64\V2.0.50727\CONFIG\machine.config
  • C:\Windows\Microsoft.NET\Framework64\V4.0.30319\CONFIG\machine.config

The modifications from previous releases are no longer necessary with ODAC version 11.2.0.3 and must be removed. The following instructions provide details on removing the modifications from these files.

Procedure

  1. On the APM Server machine, open two Windows explorer windows.
  2. In one window, navigate to the folder C:\WINDOWS\Microsoft.NET\Framework64\V2.0.50727\CONFIG.

    -and-

    In the other window, navigate to the folder C:\Windows\Microsoft.NET\Framework64\V4.0.30319\CONFIG.

  3. In each folder, using a text editor (for example, Notepad), open the file machine.config.
  4. In each file, between the opening and closing <configuration> tags, delete the following content:


  5. Save the files, and then close them.

What To Do Next

Remove Database Notification Elements from the Database

About This Task

After upgrading your APM Database Server, we recommend that a Database Administrator manually remove database notification elements from the database.

Procedure

For an Oracle server, the Database Administrator should run the command REVOKE CHANGE NOTIFICATION FROM mi_connect_role. Alternatively, for an SQL server, the Database Administrator should run the command ALTER DATABASE <db_name> DISABLE BROKER.

What To Do Next

Tips to Improve Performance

Although pagination helps improve the performance of queries, it cannot help while exporting data, using crosstab queries created from Select queries with plenty of rows, returning character large objects (CLOBs) to the client, and so on. This impacts the server-side memory, client-side memory, and the network bandwidth.

This topic provides suggestions to improve the performance of queries in other possible ways.

Avoid Full Table Scans

Full table scans can impact performance. Therefore, use indexes wherever possible. In addition, consider the following scenarios:
Database Indexes
The database team profiles the database performance periodically and maintains indexes as needed. However, if there is a need for a new index, reach out to the database team.
Outer Joins
Outer joins result in full table scans. Therefore, you must avoid them wherever possible.
Example:
SELECT d.name, d.deptno, e.name, e.mgr, d.loc
FROM dept d
LEFT OUTER JOIN emp e
ON  d.deptno = e.deptno
OR Conditions
OR conditions can slow down the query performance in large tables. Consider using a UNION instead of OR to avoid a full table scan.
For example, the following code sample...
SELECT [MI_EQUIP000].[MI_EQUIP000_EQUIP_ID_C] "Equipment ID"
, [MI_EQUIP000].[MI_EQUIP000_EQUIP_SHRT_DESC_C] "Equipment Short Description"
, [MI_EQUIP000].[MI_EQUIP000_SITE_C] "Site"
, [MI_EQUIP000].MI_SITE_KEY "MI_SITE_KEY"
FROM [MI_EQUIP000]
WHERE [MI_EQUIP000].MI_SITE_KEY = 64262809275
OR [MI_EQUIP000].MI_ENTY_ID = 'My ID'
can be rewritten as follows:
SELECT [MI_EQUIP000].[MI_EQUIP000_EQUIP_ID_C] "Equipment ID"
, [MI_EQUIP000].[MI_EQUIP000_EQUIP_SHRT_DESC_C] "Equipment Short Description"
, [MI_EQUIP000].[MI_EQUIP000_SITE_C] "Site"
, [MI_EQUIP000].MI_SITE_KEY "MI_SITE_KEY"
FROM [MI_EQUIP000]
WHERE [MI_EQUIP000].MI_SITE_KEY = 64262809275

UNION ALL

SELECT [MI_EQUIP000].[MI_EQUIP000_EQUIP_ID_C] "Equipment ID"
, [MI_EQUIP000].[MI_EQUIP000_EQUIP_SHRT_DESC_C] "Equipment Short Description"
, [MI_EQUIP000].[MI_EQUIP000_SITE_C] "Site"
, [MI_EQUIP000].MI_SITE_KEY "MI_SITE_KEY"
FROM [MI_EQUIP000]
WHERE [MI_EQUIP000].MI_ENTY_ID = 'My ID'
The Asset Hierarchy Home Parameter
When Asset Hierarchy was created, there was no constant to represent the hierarchy home. Since the data type has changed over time and -1 is not intuitive, a new MetaSQL constant has been added. To make the queries more readable and protect you from future changes, use the new constant. (# :ahhome)
Example:
SELECT [MI_EQUIP000].[MI_EQUIP000_EQUIP_ID_C] "Equipment ID"
, [MI_EQUIP000].[MI_EQUIP000_EQUIP_SHRT_DESC_C] "Equipment Short Description"
, [MI_EQUIP000].[MI_EQUIP000_SITE_C] "Site"
, [MI_EQUIP000].ENTY_KEY "ENTY_KEY"
FROM [MI_EQUIP000]
WHERE (? :ah :id=ctx) = (# :ahhome)
OR [MI_EQUIP000].ENTY_KEY IN (? :ah :id=ctx)
Query Caching
Queries are cached to improve performance. However, non-parameterized queries can slow down the performance. Therefore, consider using parameters to narrow down query results.
For example, consider the following query that does not use any parameters to filter the query results:
string sql = string.Format("SELECT MI_EQUIP000.MI_EQUIP000_SITE_C FROM MI_EQUIP000 WHERE MI_EQUIP000.MI_EQUIP000_EQUIP_ID_C = {0}", equip_id);
cmd.CommandText = sql;
cmd.ExecuteReader();
MetaSQL:
var qrymgr = new QueryManager();

string sql = string.Format("SELECT MI_EQUIP000.MI_EQUIP000_SITE_C FROM MI_EQUIP000 WHERE MI_EQUIP000.MI_EQUIP000_EQUIP_ID_C = {0}", equip_id);

var result = qrymgr.ExecuteQuerySync(sessionId, sql);
In this case, every equip_id value creates a new query to the list of cached queries resulting in a slower performance.
Therefore, consider rewriting the query such that 10,000 equipment records are queried in each iteration, as follows:
// Build the sql
string sql = "SELECT MI_EQUIP000.MI_EQUIP000_SITE_C FROM MI_EQUIP000 WHERE MI_EQUIP000.MI_EQUIP000_EQUIP_ID_C = @equip_id";

// Set up the command
cmd.CommandText = sql;
cmd.Parameters.Add("@equip_id", equip_id);

// Execute the query
var reader = cmd.ExecuteReader();
MetaSQL:
var qrymgr = new QueryManager();

// Build the sql
string sql = "SELECT MI_EQUIP000.MI_EQUIP000_SITE_C FROM MI_EQUIP000 WHERE MI_EQUIP000.MI_EQUIP000_EQUIP_ID_C = (? :s id=equip_id)";

// Set up the query container.
QueryContainer qc = qrymgr.RetrieveQueryContainer(sessionId, sql);
qc.ParmContainer.ParmDesigns[0].ParmPrompts.Add(equip_id);

// Execute the query
var result = qrymgr.ExecuteQuerySync(sessionId, qc);
Parameter Size Declaration
In addition to setting up parameters (as described in the preceding example), if you want to improve performance further, consider setting the parameter size.
For example, equip_id is of the NVARCHAR data type, and hence, the size of the MIEQUIP000EQUIPIDC field is 255 characters. Therefore, you can set the size of this parameter in the query, as follows:
// Build the sql
string sql = "SELECT MI_EQUIP000.MI_EQUIP000_SITE_C FROM MI_EQUIP000 WHERE MI_EQUIP000.MI_EQUIP000_EQUIP_ID_C = @equip_id";

// Build the parameter
var param = cmd.CreateParameter();
param.ParameterName = "@equip_id";
param.SqlDbType = SqlDbType.NVarChar;
param.Size = 255;
param.Value = equip_id;

// Set up the command
cmd.CommandText = sql;
cmd.params.add(param);

// Execute the query
var reader = cmd.ExecuteReader();
Note: You cannot specify the parameter size in MetaSQL.

Reduce the Number of Relationship Families

Entity families with more than 10 relationship families can slow down the loading of predecessor and successor families because of the number of joins involved in retrieving data.

The following query retrieves a list of all the entity families that contain more than 10 relationship families. Evaluate which relationship families are needed.
select fmly_id, fmly_caption_tx, count(*) rldf_count
from MI_FAMILIES fmly
join MI_REL_DEFINITIONS rlfa on ENFA_PRED_FMLY_KEY = fmly.FMLY_KEY or ENFA_SUCC_FMLY_KEY = fmly.FMLY_KEY
group by fmly_id, fmly_caption_tx
having count(*) > 10
order by rldf_count
In addition, use a relationship definition to retrieve a relationship family. Avoid retrieving all the relationship families.

Use Advanced MetaSQL Features

Use the following MetaSQL features to rewrite complex queries using simple syntax, thus improving the query performance:
Analytic Functions
Using analytic functions, you can achieve aggregation of data over multiple groups in a single query.
Example:
SELECT DISTINCT [MI_MRBIANAL].[MI_CRITANAL_RSK_CAT_C] "Risk Category"
, Min([MI_MRBIANAL].[MI_CRITANAL_PROB_OF_FAIL_UP_C])OVER ( PARTITION BY [MI_MRBIANAL].[MI_CRITANAL_RSK_CAT_C] ) "Min Prob of Fail"
, Max([MI_MRBIANAL].[MI_CRITANAL_PROB_OF_FAIL_UP_C])OVER ( PARTITION BY [MI_MRBIANAL].[MI_CRITANAL_RSK_CAT_C] ) "Max Prob of Fail"
, Avg([MI_MRBIANAL].[MI_CRITANAL_INSPE_PRIOR_UP_N])OVER ( PARTITION BY [MI_MRBIANAL].[MI_CRITANAL_RSK_CAT_C] ) "Avg Insp Priority"
, Count([MI_EQUIP000].ENTY_ID)OVER ( PARTITION BY [MI_MRBIANAL].[MI_CRITANAL_RSK_CAT_C] ) "# Assets"
FROM {MIR_HSRBICMP} 
 JOIN [MI_CCRBICOM] ON {MIR_HSRBICMP}.SUCC_ENTY_KEY = [MI_CCRBICOM].ENTY_KEY 
 JOIN {MIR_HSRBICMP} Has_RBI_Components1 ON [MI_CCRBICOM].ENTY_KEY = Has_RBI_Components1.SUCC_ENTY_KEY 
 JOIN {MIR_RBICRAN} ON [MI_CCRBICOM].ENTY_KEY = {MIR_RBICRAN}.PRED_ENTY_KEY 
 JOIN [MI_EQUIP000] ON Has_RBI_Components1.PRED_ENTY_KEY = [MI_EQUIP000].ENTY_KEY 
 JOIN [MI_MRBIANAL] ON {MIR_RBICRAN}.SUCC_ENTY_KEY = [MI_MRBIANAL].ENTY_KEY
ORDER BY [MI_MRBIANAL].[MI_CRITANAL_RSK_CAT_C] Asc
We support the following analytic functions:
  • SUM
  • MAX / MIN
  • AVG
  • LEAD / LAG
  • COUNT
  • ROW_NUMBER
  • CUME_DIST
  • PERCENTRANK, PERCENTILEDISC, PERCENTILE_CONT
  • NTILE
For more information, refer to Analytic Functions.
Case Statements
Simple:
SELECT [MI_ACTION].[MI_ACTION_ID_C] "Action ID"
, [MI_ACTION].[MI_ACTION_SHORT_DESC_C] "Name"
, CASE YEAR([MI_ACTION].[MI_ACTION_TARGE_COMPL_DATE_CHR]) 
     WHEN '2020' THEN 'Next Year'
     WHEN '2019' THEN 'This Year'
     WHEN '2018' THEN 'Last Year'
     WHEN '2017' THEN '2 Years Ago'
  ELSE 'Other' END "Year Due"
, [MI_ACTION].[MI_ACTION_RESOURCE_COST_N] "Cost"
, [MI_ACTION].[MI_ACTION_ANNUAL_COST_N] "Annual Cost"
, [MI_ACTION].[MI_ACTION_SHUTDOWN_L] "Shutdown Required"
, [MI_ACTION].[MI_ACTION_STATUS_C] "Status"
FROM [MI_ACTION]
ORDER BY [MI_ACTION].[MI_ACTION_TARGE_COMPL_DATE_CHR] Desc
Standard:
SELECT [MI_ACTION].[MI_ACTION_ID_C] "Action ID"
, [MI_ACTION].[MI_ACTION_SHORT_DESC_C] "Name"
, CASE
     WHEN YEAR([MI_ACTION].[MI_ACTION_TARGE_COMPL_DATE_CHR]) = '2020' THEN 'Next Year'
     WHEN YEAR([MI_ACTION].[MI_ACTION_TARGE_COMPL_DATE_CHR]) = '2019' THEN 'This Year'
     WHEN YEAR([MI_ACTION].[MI_ACTION_TARGE_COMPL_DATE_CHR]) = '2018' THEN 'Last Year'
     WHEN YEAR([MI_ACTION].[MI_ACTION_TARGE_COMPL_DATE_CHR]) = '2017' THEN '2 Years Ago'
  ELSE 'Other' END "Year Due"
, [MI_ACTION].[MI_ACTION_RESOURCE_COST_N] "Cost"
, [MI_ACTION].[MI_ACTION_ANNUAL_COST_N] "Annual Cost"
, [MI_ACTION].[MI_ACTION_SHUTDOWN_L] "Shutdown Required"
, [MI_ACTION].[MI_ACTION_STATUS_C] "Status"
FROM [MI_ACTION]
ORDER BY [MI_ACTION].[MI_ACTION_TARGE_COMPL_DATE_CHR] Desc
Correlated Subqueries
Correlated subqueries allow you to write a child query that retrieves fields from a parent query. For more information, refer to Correlated Subqueries.