Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Backup and Restore of Oracle Database Point in Time

Ketan hotmailApr 4 2024

Hello, I am very new to Oracle from DBA point of view and just trying to learn the backup/restore from last 4 days so please excuse the lack of knowledge and appreciate your guidance.

I have a Linux VM (Server) running Oracle 19c hosted in Azure (IaaS workload). I wanted to know if it was possible to backup the Oracle Database and then do Point in Time Recovery.

So far what I have done:

Using Azure Backup took the VM (and all disks) snapshot (backup). Here my database has about 5 records in a table. The time for this backup is 3pm EST APR 04th.

Using RMAN did the BACKUP ARCHIVELOG ALL; and this is stored on a file share. And I note the time for e.g.3:30pm EST APR 04th.

Now I add 5 more records to the table and commit it.

Post this I run the RMAN:- BACKUP ARVCHIVELOG ALL; command again (lets say this was at 4pm EST APR 04th).

Now I delete the VM and restore it using the Azure Restore and this VM has the Oracle database upto 3pm EST APR04th backup and this is all good with 5 records.

Now I want to recover the data point in time (3:30pm EST APR 04th) so that my table shows 10 rows so I tried to run this command: run

`{
SET UNTIL TIME "TO_DATE('2024-04-04 04:00:00', 'YYYY-MM-DD HH24:MI:SS')";
RESTORE ARCHIVELOG ALL;
RECOVER DATABASE;
sql 'ALTER DATABASE OPEN RESETLOGS';
}`

But unfortunately this doesnt work and I get errors like missing archived log etc, so not sure if I am performing the restore operation correctly.

Anyone know how I can perform this Restore/Recovery properly and assuming you had disk snapshot (Really this is not Azure related here) and then performing the Restore/Recovery from Archivelog that are backedup.

Thank you.

I tried to Restore the database from a Full ARCHIVE LOG backup and DISK backup I had but it didnt restore to Point in Time as I wanted.

I expected to recover the Database to a particular point in time.

Comments
Post Details
Added on Apr 4 2024
5 comments
11,201 views