What do all the APM postgres install/upgrade error codes mean?

Document ID : KB000012286
Last Modified Date : 14/02/2018
Show Technical Document Details
Introduction:

 In APM 10.3 and later, new capabilities were added for handling postgres database upgrades. However, the upgrade error messages were not documented until now

Question:

  Looking at postgresupgrade.log, it ends with this

     Problem installing new postgres at "D:\CA\CA APM\PostgreSQL-9.2.15". Error Code: 11002 and Error Level: 1 

     exiting pginstall with exit code 11002  

 

 What should I do on seeing this?

 

Environment:
Upgrading to APM 10.3 and later with Postgres.
Answer:

    Here is the start of the error messages:

   1) File: pg_install.bat

Errors: 

- 11000 - "Not all the required parameters are provided."

  "Arguments required <PG_INSTALLER_BIN> <OLD_DB_INSTALL_DIR> <OLD_DB_DATA_DIR> <NEW_DB_INSTALL_DIR> <NEW_DB_DATA_DIR> <OLD_DB_INSTALL_PORT> <DB_USER> <DB_USER_PASSWD> <IS_MAJOR_UPGRADE> <DB_SERVICE_NAME> <PG_INSTALLER_LOCALE><PG_HBA_LOC>" 

 

  What to Do: Provide argument and try again

- 11001 - "Could not stop the old postgres server. The Postgres service name does not exist. Error Code:Error Code and Error Level: ErrorLevel

  What To Do: Check logs and see if service is running

 

- 11002   Problem installing new postgres at "%NEW_PG_INSTALLDIR%". Error Code: Error Code and Error Level: ErrorLevel

    What to do: Check install arguments and logs.

 

- 11003  Could not stop the postgres service %NEW_PG_SERVICE_NAME%. Error Code: Error Code and Error Level: ErrorLevel

      What To Do: Check logs and see if service is running

 

 2) File: pg_upgrade.bat

  -12000 Not all the required parameters are provided. Please reconfirm over the arguments passed"  

      What to Do: Provide arguments and try again

 

 -12001 Problem stopping the service Service_Name. Error Code: Error Code and Error Level: ErrorLevel

    What To Do: Check logs and see if service is running

 

-12002 echo Problem upgrading the postgres instance. Error Code: Error Code and Error Level: ErrorLevel

  What To Do: Check logs and upgrade arguments

 

 3) File: post_upgrade.bat/sh

- 13000 "Not all the required parameters are provided. Please reconfirm over the arguments passed" 

     What to Do: Provide arguments and try again

 

-13001  echo Could not start the postgres service Service_Name. Error Code: Error Code and Error Level: ErrorLevel

       What To Do: Check logs and see if service is running

 

-13002   echo Could not analyze the postgres server "Directory_name" with default_statistics_target=100. Error Code: Error Code and Error Level: ErrorLevel

       What To Do: Check logs, config files, and database

 

-13003  problem deleting the old cluster at "Directory_name". Error Code:  Error Code and Error Level: ErrorLevel. Manually delete the postgres cluster...

            What To Do: Delete old Cluster

 

-13003 No uninstaller found in old postgres install location for clean-up. Error Code: Error Code

             What to do: Look and see if database directory already deleted or has correct path.

 

-13004 problem vacuuming the new postgres cluster at "Directory_name". Problem deleting the old cluster at "%OLD_PG_INSTALLDIR%". Error Code: Error Code and Error Level: ErrorLevel. Manually run vacuum and then delete the old postgres cluster...

             What to do: Vacuum directory and delete database