This recipe is about planning, so we'll provide discussion points rather than portions of code. We'll cover the main points that should be addressed, and also provide a list of points as food for thought, around which the actual implementation should be built:
- Let's break a rule: If you don't have a backup, take one now. I mean now, go on, off you go! Then, let's talk some more about planning maintenance. If you already do, well done! It's hard to keep your job as a DBA if you lose data because of missing backups, especially today, when everybody's grandmother knows to keep her photos backed up.
- First, plan your time: Decide a regular date on which to perform certain actions. Don't allow yourself to be a puppet of your monitoring ...