Friday, March 27, 2020

Oracle Data Guard - How to rebuild PRIMARY after a Failover

If the primary database is not available for a long duration or suffered a permanent failure, then we have to consider a failover (not switchover) to the standby database to make it as the new primary database. Later, we also have to rebuild the old primary database and make it the new standby database.

Assumptions : 

a) The FLASHBACK database feature is turned on.
b) Oracle database version is Oracle 12c R1 (12.1.0.2)

Note: The last full backup on primary server must be successful and available. This will help in having at least a traditional backup/restore alternative in case the failover to the standby database is not successful.

Failover

Run the below steps on the standby server 

a) alter database recover managed standby database cancel; (Must return "Database altered" message quickly.)
b) alter database recover managed standby database finish; (Must return "Database altered" message quickly.)
c) alter database activate standby database; (Must return "Database altered" message quickly.)

At this stage, the database role must be turned as PRIMARY

d) shutdown immediate;
e) startup;

f) select to_char(standby_became_primary_scn) from v$database;  (NOTE THIS SCN value)

Now, it is strongly recommended to take a full database backup.


Rebuild OLD primary database

Run the below steps on the old primary server (which had a permanent problem that made you to do the failover in the first place).


1) shutdown immediate; (If it is already in running status)
2) startup mount;
3) flashback database to SCN nnnnn (Replace nnnnn with the actual SCN value noted in #f above)

4)  alter database convert to physical standby;
5) alter database recover managed standby database disconnect from session; (This will start the managed recovery process - MRP0 in the background)

6) select database_role from v$database; (Must show PHYSICAL STANDBY)

7) select switchover_status from v$database; It can show either "SWITCHOVER PENDING" or "NOT ALLOWED". Both are valid values.

Oracle database 8i to 12c R1 upgrade

This blog post provides the overall approach to upgrade from Oracle 8i (specifically 8.1.7.4) to Oracle 12c R1 (specifically 12.1.0.2)

Is your current version 8.1.7.4 (8i R3) ?

If so, this is the approach. You have to perform two upgrades. The first one is called an intermediate upgrade.

We recommend you to use dbua tool (database upgrade assistant GUI tool) instead of export and import tools.

1) Oracle 8.1.7.4 (8i R3) to Oracle 10.2.0.5

Do you have access to Oracle support https://support.oracle.com ?

If so, request them to provide you Oracle 10.2.0.1 software (base edition) through a service request.  Install this 10.2.0.1 base software - Then download 8202632 which is the patch number for patchset 10.2.0.5 and apply to the 10.2.0.1 installed folder to bring it up to 10.2.0.5


Now do a direct upgrade from Oracle 8.1.7.4 to 10.2.0.5

https://docs.oracle.com/cd/B19306_01/server.102/b14238.pdf 


2) In a separate path, install Oracle 12.1.0.2

Then upgrade the 10.2.0.5 upgraded database to Oracle 12.1.0.2.

https://docs.oracle.com/database/121/UPGRD/E41397-13.pdf 

Monday, February 3, 2020

Best R Tutorial for beginners

If you are new to the R programming language (a beginner), then the best tutorial that we recommend is https://www.tutorialspoint.com/r/index.htm. It is free and very interactive. There are LIVE DEMOs for most examples and you can practice them using your web browser.

Saturday, February 1, 2020

VirtualBox Error in supR3HardenedWinReSpawn VBoxHardening

Problem

One of our students was getting the error VirtualBox Error in supR3HardenedWinReSpawn with log details in VBoxHardening.log while starting a virtual machine.

This issue happens even after uninstalling VirtualBox and reinstalling using a different version. It happens both with version 6.x and 5.x respectively.

Solution

This problem was resolved after uninstalling "Trusteer Endpoint Protection" offered by IBM in the student's Windows 10 operating system.

We tried other potential solutions described in https://superuser.com/questions/1307424/virtualbox-5-2-6-and-5-2-6-error-in-supr3hardenedwinrespawn but uninstalling "Trusteer Endpoint Protection" offered by IBM solved the problem.

Saturday, January 25, 2020

AWS certification training

Hello all,

DBA University has started Amazon Web Services (AWS) Training courses in 2020. We now have two courses that will help students gain rich practical skills and pass AWS certification exams.

Both the courses are live training courses and can be registered using the below links

1) AWS certified cloud practitioner

https://dbauniversity.com/course/aws-certified-cloud-practitioner

Duration: 24 hours in 4 weeks. 
Schedule: Wednesday, Thursday and Friday 7:30 pm to 9:30 pm central time.

2) AWS certified solutions architect associate

https://dbauniversity.com/course/aws-certified-solutions-architect-associate

Duration: 40 hours in 5 weeks.

Schedule:

Sunday  : 8:00 am to 12:30 pm central time (30 minute break).
Monday : 7:30 pm to 9:30 pm central time.
Tuesday : 7:30 pm to 9:30 pm central time.