Upgrade to MySQL 8.4
Prerequisites Copied
Before performing the upgrade, ensure the following prerequisites are met:
- Your Opsview version is fully upgraded to 6.11.7 or newer. Older versions do not support MySQL 8.4 as the default database.
- Your database is running MySQL. Switching between database vendors (for example, from MariaDB to MySQL or vice versa) is not supported for existing local, remote, or RDS databases.
- Your operating system is compatible with MySQL 8.4. For more information, see Supported databases.
Back up Opsview databases and configuration Copied
Warning
This step is crucial to prevent data loss in your Opsview system.
It is important to back up your databases so you can recover your data and restore operations in case of issues during the upgrade process, such as system crashes or hardware failures.
To backup your Opsview data and system, refer to Back up your Opsview data and system for instructions on backing up all databases on the server. If you are using a remote database server, perform the backup on your database host. Otherwise, perform the backup on the orchestrator.
Upgrade to MySQL 8.4 Copied
On your orchestrator, do the following steps:
- Add the following configuration to the
user_vars.ymlfile.
opsview_database_package_vendor: 'mysql'
opsview_database_package_version: '8.4'
- Run the
check-deployandsetup-everythingplaybooks to upgrade the databases to MySQL 8.4.
cd /opt/opsview/deploy
./bin/opsview-deploy lib/playbooks/check-deploy.yml
./bin/opsview-deploy lib/playbooks/setup-everything.yml
Run setup-monitoring Copied
- On your orchestrator, run the
setup-monitoringplaybook.
cd /opt/opsview/deploy
./bin/opsview-deploy lib/playbooks/setup-monitoring.yml
- After completing the step, Apply Changes to submit your database modifications.
RDS Copied
MySQL 8.4 has a parameter, called restrict_fk_on_non_standard_key, which is set to ON by default. Opsview requires this parameter to be set to OFF.
Before running the playbooks to install or upgrade Opsview, ensure that the restrict_fk_on_non_standard_key parameter is set to OFF in your MySQL 8.4 DB instance on AWS RDS.
Upgrading Opsview with MySQL 8.4 Copied
Before running the playbooks to upgrade Opsview, make sure to set the restrict_fk_on_non_standard_key parameter to OFF in AWS RDS for your MySQL 8.4 DB instance.
- Stop Opsview processes.
# /opt/opsview/watchdog/bin/opsview-monit stop all
-
Upgrade your MySQL RDS DB instance to 8.4. Refer to the RDS documentation for instructions on upgrading your MySQL instance to 8.4.
-
Set the MySQL parameter
restrict_fk_on_non_standard_keytoOFF. See the RDS documentation for guidance on configuring this parameter on your DB instance. -
Start Opsview processes.
# /opt/opsview/watchdog/bin/opsview-monit start all
- Upgrade Opsview.
Troubleshooting Copied
To help resolve any issues you may encounter during the upgrade, refer to the Database issues troubleshooting documentation.