Sunday, November 13, 2022

SQLNET.ORA file got modified by OCI VM DB System upgrade

 In my last post https://samappsdba.blogspot.com/2022/11/upgrade-oracle-db-to-1916-on-oci-vm-db.html, i explaained the steps on how we did the patchset upgrade from 19.7 to 19.6 for OCI VM DB System. The activity was performed through Console. All the steps were done seamlessly but what we observed after the upgrade was that the SQLNET.ORA file was being modified. Now the SQLNET.ORA contains the DB wallet location.




As the wallet location were modifed, we had issues on querying the DBA tables.




The wallet information stord in controlfile and the wallet information stored in ewallet.p12 file was not matching. And because of this mismatch, we were getting the issue.

We had one backup taken before the upgrade from the console. We used the same backup to create a separate a new VM DB System and then copied the correct wallets. Once the correct wallets were placed in the desinated directory, the SQLNET.ORA file was modified so that it points to correct wallet location. At last bounced the database and we then were able to query the DBA tables. From this post, i just want to emphasize some points which are not mentioned clearly in the documentations from oracle.

1. Have a full backup of the database taken before the upgrade

2. Take the full backup of the files placed under $ORACLE_HOME/network/admin, especially the sqlnet.ora file

3. Once the upgrade is complete, validate the files under $ORACLE_HOME/network/admin and take a full backup of the database.


I hope this post will help someone. Till then, happy learning Cloud



Monday, November 7, 2022

upgrade oracle db to 19.16 on OCI VM DB Systems

 This post describes the steps on how we can upgrade the Oracle Database release 19.7 to 19.16  running on Oracle Cloud Infrastructure VM DB Systems. At the time of writing this post, 19.6 was the latest patchset available on the console. It is always advisable to go through the official documentations Upgrade your database from console. Also this note is not applicable for database running on ExaCS.

Prerequisites

The following are required in order to upgrade a database on a bare metal or virtual machine DB system:

The DB system must use Oracle Linux 7 (OL7)

If your DB System uses ASM storage management software, the system must use Oracle Grid Infrastructure 19c


Your Oracle database must be configured with the following settings in order to upgrade:

The database must be in archivelog mode.

The database must have flashback enabled. Your DB Recovery Dest should point to +RECO Diskgroup.


Before you proceed with the next steps, it is always advisable to take the full backup of the database. We had faced one major issue related to wallets which is not documented anywhere and this fullbackup helped us. I will blog this in my future posts.

 



Precheck

The Precheck gives you an option to upgrade the component for Grid Infrastructure as well as for the Database running on DB System. 

First, we did the upgrade for Grid Infrastructure and then we did it for Db System.




The Precheck ran for 10 mins.





Once the precheck is complete, we will click on "Apply".


Once the GI is moved to latest patchset, we will go the DB system and follow the same process






Post Upgrade Activity:-

1.     Verify if there are any errors in alert log.

2.     Verify the dba_registry

3.     In my case, this was the patchset upgrade but if you are doing a major upgrade, you need to decide when can you change the Compatible parameter. I normally do it after 1 week of upgrade. 

4.     Update the .bashrc to reflect the new Oracle Home. The tooling doesn't update it

5.     Take the manual backup and enable automatic backups if required

6.     Remove the Old Oracle home using DBCLI

 

 References:- https://docs.oracle.com/en-us/iaas/dbcs/doc/upgrade-database1.html

                     Daniel has published a wonderful blog on the major upgrade in this blog VM DB System DB upgrade