• No results found

Backup, Restore and Options for SQL Server

N/A
N/A
Protected

Academic year: 2021

Share "Backup, Restore and Options for SQL Server"

Copied!
35
0
0

Loading.... (view fulltext now)

Full text

(1)
(2)

Housekeeping

• Please be sure to answer survey (above video window)

(3)

Viewing Tip – Enlarge Slides Now…

• You can enlarge the window with the slides – just click “Enlarge Slides” below.

(4)

Agenda

• Overview of Backup/Recovery Planning • Wizards Available

• Quick Overview of Jobs and Backups • Restores – how they work, how they’re

done

(5)

A Note About Versions

• Very similar

• Will try to outline differences

• “Look and feel” more than “Functionality”

(6)

Using Azure or AWS/Cloud Services?

• Still need backup.

• MUST understand differences and approaches • Trust, but verify, as with all backups

(7)

Backup and Restore Purposes

• Broad catastrophic • “Oops” corrections • Targeted restores

• Business Intelligence

(8)

Backup…Plan…Test…

(9)

Food for Thought

• Reliance on Wizards • Incomplete strategy

(10)

Key Questions

• How often do I need to backup?

• How many copies do I need to keep?

• How will they be restored/used?

• These determine your strategy and what you

(11)

Understanding Backup Models

• Full

• Simple

(12)

Recovery Model: Full

• Full transaction log restore

– Restore the baseline db

– Restore the transaction logs in order – Restored up to last tran. log backup – “Tail” backups

• Watch the transaction log physical devices • Beware total reliance on tran. log

(13)

Recovery Model: Simple

• Backup/restore at the database level

• Good for development environments

• Disaster recovery, but not

transaction recovery since the last backup

• “All or nothing” restore

(14)

Recovery Model: Bulk_logged

• Better for bulk operations

– Select into, etc.

• Good for a migrating database

– If the data exists elsewhere

– Can be rebuilt from other source

– Good for DTS move operations – control log size build-up

(15)

Setting Recovery Models

(16)

Best Practices – Development to Production

• Development – use a SIMPLE model

– Backup nightly/weekly depending on changes and

your needs

• Production – use a FULL model

– Backup nightly

– Determine interval for transaction log backups

• Be sure to remember to change when your

(17)

Planning Your System

• Disk space

• CPU utilization

• “Split” backup plans – Database-by-database – Filegroups

(18)

Overview of SQL Server Backups – How do they work?

• Define a destination (“Backup Device”)

– Disk, tape, URL/Azure (SQL 2014)

• Decide what you want to accomplish

– Backup only

– Reorganize/defragment, etc.

• Setup a schedule

(19)

Using the Wizards

• Wizard benefits – Scheduling

– Other maintenance options (defrag, etc.) – Backup vs. Maintenance Plan Wizards

– Great learning tool

• SQL Statements • Scheduling

(20)

Database Maintenance Plan – Wizard-Based

• Management, Maintenance Plans, Maint. Plan

Wizard

• Suggestion:

All user db’s

• Make sure you

setup system DBs

• Demo

(21)

Backup Considerations

• Keep in mind that verify integrity option = CPU stress

• Watch the retention values you provide – Disk space usage

(22)

Notification and Reporting Options

(23)

Understanding the Job System

• SQL Server Agent, Jobs

• You’ll see different jobs for each plan you set up. Descriptive titles are helpful.

• DB Backup, Tran log backup,

optimization, integrity checks • Double-click any to review

• Scheduling and other options

(24)

Setting Up Error Handling

• Don’t ignore this step – your backups are at stake • During the wizard, or after

the fact, set up operators to receive notifications

• Consider success AND

failure notifications to start, then move to exceptions

(25)

Establishing a Reporting Operator

• Set up operator • Reference in job

• Properties for the job…

• Consider writing “bread crumbs” to the event log as well

(26)

Backups – Manual Process

• If you backup the db directly (manually), you’ll be shown the options differently

(27)

Restores – The Process

• Restore the database • Restore the logs

– In order, oldest first

(28)

Restores – How-To

• Right-click db, tasks, restore

– Or

– Right-click Databases, Restore option

• Select the db to restore • Select the set to use for the

restore

• Consider restoring to a new database rather than the source if you have ANY question…

• Script button…

• Tail-log backups – full or bulk- logged only

(29)

Restore Notes

• Check the generated SQL if you’re having trouble

• Note that you can change the destination

(30)

Managed Backups

• SQL Server determines frequency

• You set up retention and it manages the rest

(31)

The Cloud

• CAN be very big differences in recoverability

Remember the types of objectives (next slide)

• Some recovery options don’t make sense in the

cloud (log shipping)

– Know the system recovery process, e.g. AWS

Stop/Start

• Know how a hybrid (cloud/on-premise) situation

(32)

Backup and Restore Purposes

Broad catastrophic

• “Oops” corrections • Targeted restores

• Business Intelligence

You may want/need a plan for each of these.

(33)

Disaster Planning…and Testing

• Test your restores on a development instance • Learn what happens to your applications after

a “cold” restore

(34)

Final Thoughts, Best Practices

• Document your plan, media passwords, recovery steps (and test them)

Don’t be the single point of failure just because it’s all in your head

• T-SQL for your systems (script it out)

• Encryption of backups

• Key management

• User accounts, jobs, other system-level items

• Test your restores, test the process of getting back online • Have multiple fall-back positions

(35)

Questions…

?

?

?

?

?

?

?

?

?

?

?

?

?

?

?

Please be sure to fill out the survey – and feel free to ask questions in the Q&A tool.

References

Related documents

Having a Backup and Disaster Recovery devices on the network that can backup all your critical data on all your computers and server, replicate a downed server and synchronize

When Universal Credit is introduced in October 2013 tenants in receipt of Housing Benefit will have the money paid into their bank account and will.. be expected to pay their

■ Recovery of the Microsoft SQL Server images that were backed up with Backup Exec, through the Backup, Archive, and Restore (NetBackup Client) interface.. ■ Support for SQL Server

■ Recovery of the Microsoft SQL Server images that were backed up with Backup Exec, through the Backup, Archive, and Restore (NetBackup Client) interface.. ■ Support for SQL Server

■ (SQL Server legacy policies) Backups of databases and database components, configuration of backup options, and monitoring NetBackup for SQL Server restore operations.. In this

5 - Security in SQL Server 2008 6 - SQL Server Backup and Recovery 7 - Automating Your SQL Server 8 - Miscellaneous Administration Topics 9 - SQL Server Monitoring and Performance 10

” “ 1 4 2 Drive Failure Media 3 5 Partition Backup Media SEP Backup Server Start Dissimilar Hardware Wizard Restore Backup to Boot-Ready File Select Data Recovery Saveset

Backup alone is not enough to restore a business, and you need to ensure the protection of your data by extending the scope of your plans beyond just disaster recovery.. To take