Oracle Database 12c : Some Backup and Recovery Stuff

In a previous post, I had already listed an article on backup and recovery when using the Oracle 12c multitentant option.

In that article I made reference to a restriction when using flashback database against a CDB with a PDB that has had a point in time recovery. I finally got my head round this and posted a note about it here.

As well as this stuff, I’ve also had a play around with table recovery. It’s pretty cool! In previous versions you had to do a manual point in time clone to recover a table in this way. In Oracle 12c it still does this, but it has wrapped it up and hidden it behind a nice RMAN command, making it feel a lot simpler. Definitely a neat feature when you need to recover old versions data that pre-date the level of undo available.

I word of advice before you launch into playing with any of this. TAKE A SNAPSHOT OF YOUR VM!

I’ve been playing about with this stuff using Oracle 12c on Oracle Linux, running on an Oracle VirtualBox VM. You would not believe the number of times I’ve totally screwed up my databases while figuring this stuff out. I’ve recreated PDBs and CDBs a number of times. I’ve had to recover databases that I broke by accident. I’ve even had to restore a previous snapshot of the VM a couple of times to get myself back to a stable state. All this messing about is great for getting to grips with the tech, but it can be frustrating if you are only trying to investigate one specific feature. For this reason, I would say avoid trying to learn this stuff on a physical machine. Especially when learning backup and recovery, it can be a time consuming pain in the ass when you screw things up.You want to be able to get back to the start and try again as quickly as possible. This is where VM snapshots rule! Of course, if you’ve got the time to spare, you can come across some interesting things when you accidentally break things and try to fix them! 🙂

One of things I’ve noticed specifically about RMAN and PDBs is the error handling of some commands is not what it could be. Sometimes you perform a relative simple RMAN command while the PDB is closed and it gives you a “sky is falling in” type message, including the odd ORA-00600, which leads you to believe things are really screwed. You notice the PDB is closed, so you open it and hey presto, the RMAN command works just fine. Now admittedly, I was attempting to do something stupid, but a “You can’t do that when the PDB is closed dumb-ass!” message would have been a lot less scary than an ORA-00600. 🙂 I’m going to try and recreate the specific scenarios and log them on MOS so future versions can handle people doing stupid stuff a bit better. 🙂

Cheers

Tim…

RMAN Enhancements in 11g…

My trip through the 11g new features continues with RMAN Ehancements. These combined with the Data Recovery Advisor and Flashback and LogMiner Enhancements I wrote about previously show that Oracle are really putting a lot of effort into getting this area right. I guess the Data Recovery Advisor will be the most outstanding new feature for most people, but there are loads of tweaks all round that all help to make life easier for us guys on the coal face.

Cheers

Tim…

Data Recovery Advisor…

When I first saw the name Data Recovery Advisor, I thought I was going to have a really dull time figuring how this new 11g functionality worked, but it is really quite cool!

I don’t care if you are a beginner or a battle-scarred DBA, every time you have to recovery a database, you get a little twinge of doubt about whether it’s going to work. Sure, if your backups are good and you’ve practiced your recovery scenarios it should work, but what if…

The Data Recovery Advisor goes some way towards calming those jitters by automatically identifying, diagnosing and optionally repairing the problem for you. I think this is totally cool and a great move by Oracle.

Cheers

Tim…

PS. This article got on the front page before it was actually finished. I apologize if you caught the half-done version. 🙂