Backup and restore
Upcoming SlideShare
Loading in...5

Backup and restore



1. Script backup ...

1. Script backup
2. Recovery models
3. Backup type(Full,differential, transactional)
4. Transactional logs
5. Point in time restore
6. Transactional log shipping
7. Recovery of deleted data without any backup



Total Views
Views on SlideShare
Embed Views



0 Embeds 0

No embeds



Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
Post Comment
Edit your comment

Backup and restore Backup and restore Presentation Transcript

  • Backup And Restore Sql Server
  • Why database backup?  Is it possible to recover program?  Is it possible to recover data?  Large size of data.
  • Script Backup  Schema Only Backup  Good if database size is big  Data Only Backup  Good if database size is less  Schema and Data Backup  Useful in data migration  Auto schedule script backup
  • Transaction Log  Sql server keeps logs of every DML, DDL etc statements.  SELECT * FROM sys.fn_dblog(NULL,NULL)  If you do not back up the log frequently enough, the transactional log can expand until it runs out of disk space.  Recovery model control the transactional log backup.
  • How to create database backup  During the backup process sql server remains online.  Task which are not allowed:  Alter database with either the ADD FILE or REMOVE FILE option  Shrink database  Creation or deletion of database file.  Backup of File and File group
  • Recovery Models  Simple  Database Backup:Yes  Transactional Log Backup: No  Point InTime Restore: No  Full  Data Backup:Yes  Transactional Log Backup:Yes  Point InTime Restore:Yes  Bulk Logged  Data Backup:Yes  Transactional Log Backup:Yes  Point InTime Restore: No
  • Schedule database backup  Transaction Log Shipping  Create copy only backup  Maintenance Plan  By Sql Scrip And Agent Job  BACKUP DATABASE AdventureWorks2008 TO DISK = 'Z:SQLServerBackupsAdventureWorks2008.Bak‘
  • Point In Time Backup (Simple Recovery Model)
  • Point In Time Backup(Full Recovery Model)
  • Backup Types  Full Backup  Backs up the whole database.  As a database increases in size full it take more time to finish.  Differential Backup  First backup must be a full backup.  It captures only the data that has changed since that full backup.  Transactional Log Backup  Not possible in simple recovery model.
  • Restore Database  Restore database backup  Backup of recent version will not be restored in earlier version.  Backup of older version can be restored in recent version.  The whole database is offline for the duration of the restore  Recovery Mode:  WITH RECOVERY  WITH NORECOVERY  WITH STANDBY  Restore data file
  • Restore to Point of Failure
  • How to recover deleted data Without Any Backup?
  • Thank You