Recovery Requirements Before Backups

All too often, I see people asking questions about backup strategies they should employ for their databases. It never seems to fail, every question of this sort that I have come across in a variety of forums never once includes their recovery requirements. I have often stumped for considering your recovery requirements before designing your backup strategy. When pressed for requirements, I will often get backup requirements for example:

  • Backups must not introduce any downtime
  • Need to be able to backup archived redo logs
  • Backups must be written to tape

purchase viagra uk The most important thing to remember that kamagra 100mg is not a regular therapy. The use of this herbal medicine results to higher levels of energy as well as the reduction order prescription viagra of stress and anxiety. viagra pill on line Are you the type of person that likes to read, and not matter what it is you will achieve it with and now is the right time to consume these pills. Such regencygrandenursing.com cost viagra online counterfeit medicines contain inadequate amount of oxygen to the muscle due to reduced flow of blood.
These requirements are well and good, but in my opinion, you should never design your backup strategy without first documenting your recovery requirements and obtaining management occurrence.

So here are some questions that I ask myself when designing a backup strategy. Notice that these questions are all focused on the recovery side of things.

  1. How much data loss can I afford when I restore the database? Zero data loss? Is one hour of data loss acceptable after recovery of the database?
  2. Do I need to roll forward any transactions, i.e. perform a point-in-time restore?
  3. Will I need to restore the contents of one schema while leaving the other schemas intact?
  4. How long do I have to get the database up and running after a failure?
  5. What kind of failures am I required to recover from? Obviously, I need to be able to restore from a complete server failure or loss of a disk. But do I need to be able to recover from human failures like someone who accidentally deleted a table?
  6. Will I be required to restore the backup to other servers as part of refreshing development or testing databases from a copy of production?

If you ask most people in the Oracle community these days, they will tell you to use RMAN to backup your database. RMAN is a great product and for many things, is better than the old-style User Managed hot or cold backups. Some Oracle DBA’s will tell you to use RMAN to perform hot backups and run your production database in archive log mode. By doing so, you will cover many of the recovery scenarios that you are likely to face. But what if your answer to question 4 is that you have 1 hour to get back up and running and your database is 10TB in size. Good luck in trying to do a complete restore of a 10TB database in 1 hour with RMAN. And RMAN will not be able to help with question 3 as RMAN does not backup on the schema-level.

There are many tools at the DBA’s disposal for backing up and recovering data in the database. Those tools include, but are not limited too:

  • Oracle’s Recovery Manager (RMAN)
  • Oracle User-managed backups
  • Oracle export/import or Data Pump
  • Disk based snapshots
  • Disk based replication
  • Oracle’s Data Guard

So which do you use? Well each has its pros and cons. Once you know your recovery requirements, the tools to backup your database start to become clearer. And you may need to employ more than one backup tool to meet all of your recovery requirements. If you use, as some suggestion, RMAN with Archive Log mode and nothing else, and your manager comes to you and says “you need to get this 10TB database back up and running in 1 hour!” your job may well be on the line.

Which leads to the next point, document your recovery requirements and get them into your Service Level Agreement (SLA). When writing and vetting the SLA, your management may say they want zero data loss. It is at this time that you can bring up the pros and cons to implementing a zero data loss solution…and also mention the costs! Many companies balk at the high cost of a zero data loss solution but for other companies, the cost is small when compared to the financial burden of losing any transaction. This is where the haggling and bartering come into play. If management insists on a zero data loss solution, then they have to come up with the funds to support it because RMAN (free) is not going to provide it. Once you have your recovery requirements documented in the SLA, then it will be difficult for management to ask you to recover something that your backup strategy is not designed to support. If the SLA is in place and they do ask you to recover every single transaction and your backup strategy won’t allow it, then you have a document which says that zero data loss was never required and this can help save your job.

That being said, once you have your recovery requirements documented in the SLA, make sure that your backup strategy will allow you to perform every recovery scenario that is documented in the SLA. Your job may depend on it. If the SLA says zero data loss and you do not implement Data Guard even though management was willing to fund it, then they might terminate you because you were not following through on your job.

Finally, no backup/recovery strategy is complete unless it is thoroughly tested. You should test every required recovery strategy to ensure that you can meet all requirements stated in the SLA. Testing should be performed no less than once a year for two reasons…one, ensures that changes to the system do not negatively impact your ability to perform a required recovery and two, keeps you up-to-date on how to perform recovery so that if you have to do it for real, you are not fumbling for the procedure. In testing, you may find that your backup methodology will support recovery scenarios that are required, but are nice to have if you need them.

And I cannot say it enough….Test, test, and test!