Upgrade an Infrastructure Management Dedicated database appliance
-
Create a temporary upgrade directory.
On the target appliance, create a temporary upgrade directory by running the following commands:
mkdir /tmp/upgrade cd /tmp/upgrade
-
Back up the current appliance database.
Important: All of these substeps in step 2 are only required if you are upgrading from Infrastructure Management 3.5.x and older.
These steps don't affect the operations of your appliance infrastructure. However, they help ensure that you are able to roll back if required and replicate the network settings.
-
Find the size of the databases by using the following command. Then, ensure that your volume has enough space for the backup file.
Important: This step is only required if you are upgrading from Infrastructure Management 3.5.x and older.
psql -d vmdb_production -c "SELECT pg_size_pretty(pg_database_size('vmdb_production'));"
-
If it’s a multi-region environment, make sure that you removed all subscriptions from the global database appliance.
Important: This step is only required if you are upgrading from Infrastructure Management 3.5.x and older.
-
Back up the databases of your appliances in the root directory. Take a snapshot if possible.
Important: This step is only required if you are upgrading from Infrastructure Management 3.5.x and older.
pg_dumpall -c --if-exists | gzip > vmdb.pg.gz
Notes:
- If you changed your postgresql database configuration files, such as the pg_hba.conf and postgresql.conf then update these files manually to include any changes you made previously.
- The
pg_dumpall
command creates a compressed text-based backup.pg_dumpall
is a utility for writing out (“dumping”) all PostgreSQL databases of a cluster into one script file. For more information, see pg_dumpall. - Running a
pg_dumpall
command thepg_replication_slots
doesn't get copied over causing the slots to become inactive. This action helps to reduce the size of the global database appliance and allows for quicker backup and restore. - Even a compressed database backup can be large so consider storing it on a file system with adequate space such as /var/tmp. Review your file system available space by using the
df
command.
-
-
Clear the data directory.
Important: This step is only required if you are upgrading from Infrastructure Management 3.5.x and older.
After the database and postgresql are safely backed up, clear the data directory by running the following commands:
systemctl stop postgresql rm -rf $APPLIANCE_PG_DATA
-
Download the IBM Cloud Pak for AIOps - Infrastructure Automation RPM updates image to the upgrade directory.
For more information, see Passport Advantage part numbers. Download the IBM Cloud Pak for AIOps 4.6.1 - Infrastructure Automation RPM updates image.
-
Extract the .tgz on the target appliance.
Run the following commands:
cd /tmp/upgrade tar -zxvf infrastructure-management-upgrade-15.y*.tgz
-
Enable new stream 8 modules.
Important: This step is only required if you are upgrading from Infrastructure Management 3.5.x and older.
Enable the stream 8 modules by running the following commands:
dnf -y module reset postgresql dnf -y module enable postgresql:13 dnf -y module reset ruby dnf -y module enable ruby:3.0
-
Upgrade the RPM packages.
Run the following commands:
dnf -y upgrade --allowerasing --refresh *.rpm dnf -y autoremove
-
Verify that the PostgreSQL version is 13.
Important: This step is required only if you are upgrading from Infrastructure Management 3.5.x and older.
Run the following command:
cat $APPLIANCE_PG_DATA/PG_VERSION
This command checks the PostgreSQL version and returns: 13
-
Complete the steps in Upgrading Non-VMDB appliances.
Complete the steps in Upgrade an Infrastructure Management non-VMDB appliance
-
Remove the temporary upgrade directory.
Remove the upgrade directory by running the following command:
rm -rf /tmp/upgrade
The upgrade process is now complete. After appliances are running again, you can configure database replication in your environment. For more information, see Configuring Database Replication and Centralized Administration in the General Configuration guide.