Upgrade issue in build 3200

Upgrade issue in build 3200

Upgrade issue in build 3200

The below cases were identified in local system and couple of customer's system during 3200 upgrade.

Issue 1: PGSQL migration fails:

Since this upgrade will upgrade pgsql version, pgsql has its own upgrade prior to application upgrade. In some cases, it would thow error during data migration. The error could be related to shared memory used by pgsql during migration.

Identification:

After it failes, check <Aplus home>\logs\pgupgradelogs_XXXXXXXXXXXX\_pgupgrade\pg_upgrade_internal.log

It might have some failure information in it like below.

-----------------------------------------------------------------
  pg_upgrade run on Mon Aug 28 20:44:34 2017
-----------------------------------------------------------------


-----------------------------------------------------------------
  pg_upgrade run on Mon Aug 28 20:44:34 2017
-----------------------------------------------------------------

Performing Consistency Checks
-----------------------------
Checking cluster versions                                   ok
Checking database user is the install user                  ok
Checking database connection settings                       ok
Checking for prepared transactions                          ok
Checking for reg* system OID user data types                ok
Checking for contrib/isn with bigint-passing mismatch       ok
Checking for roles starting with 'pg_'                      ok
Creating dump of global objects                             ok
Creating dump of database schemas

*failure*
Consult the last few lines of "pg_upgrade_dump_16384.log" for
the probable cause of the failure.

*failure*
Consult the last few lines of "pg_upgrade_dump_24668.log" for
the probable cause of the failure.
Check the mentioned log file under the same folder mentioned above.
pg_upgrade_dump_16384.log
pg_dump: WARNING: out of shared memory
pg_dump: [archiver (db)] query failed: ERROR:  out of shared memory
HINT: You might need to increase max_locks_per_transaction.
pg_dump: [archiver (db)] query was: SELECT (SELECT amname FROM pg_catalog.pg_am WHERE oid = opfmethod) AS amname FROM pg_catalog.pg_opfamily WHERE oid = '16454'::pg_catalog.oid
command: "D:\ManageEngine\AnalyticsPlus\.\pgsql\bin/pg_dump" --port 50432 --username ^"postgres^" --schema-only --quote-all-identifiers --binary-upgrade --format=custom  --file="pg_upgrade_dump_16384.custom" ^"dbname^=sldb^" >> "pg_upgrade_dump_16384.log" 2>&1


Solution:

  1. Edit file postgresql.conf present under D:\ManageEngine\AnalyticsPlus\pgsql\data
  2. Look for "#max_locks_per_transaction = 64"
  3. Uncomment it and change the value to 128 (ex: max_locks_per_transaction = 128)
  4. Save the file and restart the upgrade

Note: If still fails at the same location, increase it to 256


================================================

Issue 2: APM integrated old instances.: Throws error in Application upgrade. Accounts module will not start.

Identification:

We just need to check if it is initially integrated before 3050. Simply run this query under zreportsdb to check if any empty values seen.

select * from apmdbinfo;

Table: apmdbinfo under zreportdb

In this table if any entry is having empty values for buildnumber then it is an issue.

Solution:
  1. Revert back the failure
  2. Update the apmdbinfo table with some old APM build number in the empty columns
  3. Restart the 3200 Upgrade

                    New to ADSelfService Plus?

                      • Related Articles

                      • Failed to upgrade to build 5300/5301

                        Issue: Upgrade fails while attempting to upgrade to the build 5300/5301. Cause: Upgrade fails due to a necessary system property required for logging slow queries is missing. This issue will arise while attempting to upgrade to the ...
                      • Slowness in accessing dashboards after an upgrade to 4000

                        Analysis: CPU spikes to 100% and the pgsql.exe processes consuming more memory. The phantom server which used to generate the snapshots for all the reports is enabled by default after the upgrade. This process creates load and causes the performance ...
                      • Upgrade failure

                        Issue: Upgrade fails with error - "Error occurred :: Irrevertable exception occurred" Analysis: Tried to start database manually, but it fails to start. Antivirus has been disabled/uninstalled. Log Traces: Aug 10, 2016 4:02:37 PM ...
                      • Unable to Connect to the Postgres SQL Database from Command Prompt

                        Issue : Unable to Connect to the Postgres SQL Database from Command Prompt Error : Analysis : IPv6 local connections are commented in <AnalyticsPlus home>\pgsql\data\pg_hba.conf file Solution : Open the file using notepad or wordpad as administrator ...
                      • Upgrade Key steps

                        Key steps that must be followed without which the upgrade may fail.  All Analytics Plus Services must be stopped. AnalyticsPlus folder must be given "Everyone" folder permission with "Full Control" before upgrade (Can be revoked after upgrade) ...