0% found this document useful (0 votes)
20 views

TSM Cli - TDP For SQL - Backing Up Microsoft SQL Server With IBM Tivoli Storage Manager - Sg246148

Uploaded by

GoyoICP
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

TSM Cli - TDP For SQL - Backing Up Microsoft SQL Server With IBM Tivoli Storage Manager - Sg246148

Uploaded by

GoyoICP
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 296

Front cover

Draft Document for Review April 30, 2008 1:21 pm SG24-6148-01

Backing up Microsoft
SQL Server with IBM
Tivoli Storage Manager
Strategic planning and implementation
considerations for effective backup

Tivoli Data Protection for SQL


Server V5.5 VSS backups

SQL Server overview for


TSM administrators

Marcia Kubo
Carlos Eduardo Abramo Pinto

ibm.com/redbooks
Draft Document for Review April 30, 2008 1:21 pm 6148edno.fm

International Technical Support Organization

Backing up Microsoft SQL Server with IBM Tivoli


Storage Manager

May 2008

SG24-6148-01
6148edno.fm Draft Document for Review April 30, 2008 1:21 pm

Note: Before using this information and the product it supports, read the information in
“Notices” on page ix.

First Edition (May 2008)

This edition applies to IBM Tivoli Storage Manager, IBM Tivoli Storage Manager for Databases
Data Protection for SQL Server, and IBM Tivoli Storage Manager for Advanced Copy Services.

This document created or updated on April 30, 2008.

© Copyright International Business Machines Corporation 2008. All rights reserved.


Note to U.S. Government Users Restricted Rights -- Use, duplication or disclosure restricted by GSA ADP
Schedule Contract with IBM Corp.
Draft Document for Review April 30, 2008 1:21 pm 6148TOC.fm

Contents

Notices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ix
Trademarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . x

Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi
The team that wrote this book . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi
Become a published author . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xiii
Comments welcome. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xiii

Summary of changes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xv
May 2008, First Edition. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xv

Chapter 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.1 Tivoli Storage Manager overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.1 IBM Tivoli Storage Manager components . . . . . . . . . . . . . . . . . . . . . . 3
1.1.2 IBM Tivoli Storage Manager for Copy Services overview . . . . . . . . . . 6
1.1.3 Data Protection for SQL Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.2 Snapshots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
1.2.1 Snapshot overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
1.2.2 Copy-on-write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.2.3 Redirect-on-write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
1.2.4 Split mirror. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
1.2.5 Copy-on-write with background copy . . . . . . . . . . . . . . . . . . . . . . . . 12
1.2.6 IBM FlashCopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
1.3 Volume Shadow Copy Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
1.3.1 Methods for creating shadow copies. . . . . . . . . . . . . . . . . . . . . . . . . 13
1.3.2 The VSS model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
1.3.3 The VSS architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
1.3.4 How shadow copies are created . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
1.3.5 Shadow copy types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
1.4 The Microsoft Virtual Disk Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
1.5 VSS Service with Tivoli Storage Manager. . . . . . . . . . . . . . . . . . . . . . . . . 20
1.6 Integration between Data Protection and SQL Server . . . . . . . . . . . . . . . 22
1.6.1 Data Protection for SQL Server backup methods . . . . . . . . . . . . . . . 22
1.6.2 SQL Server backup types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
1.6.3 Data Protection for SQL Server restore methods . . . . . . . . . . . . . . . 28
1.6.4 SQL Server restore types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

Chapter 2. Planning considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31


2.1 Data Protection for SQL Server requirements. . . . . . . . . . . . . . . . . . . . . . 32

© Copyright IBM Corp. 2008. All rights reserved. iii


6148TOC.fm Draft Document for Review April 30, 2008 1:21 pm

2.1.1 Software and operating system requirements. . . . . . . . . . . . . . . . . . 32


2.1.2 Hardware requirements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
2.2 Tivoli Storage Manager backup options . . . . . . . . . . . . . . . . . . . . . . . . . . 36
2.3 Microsoft SQL Server backup planning. . . . . . . . . . . . . . . . . . . . . . . . . . . 40
2.3.1 Identify recovery requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
2.3.2 Backup strategy and database recovery model . . . . . . . . . . . . . . . . 41
2.3.3 SQL Server log chains . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
2.3.4 SQL Server backup strategies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
2.4 Additional SQL Server backup considerations . . . . . . . . . . . . . . . . . . . . . 50
2.4.1 System databases. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
2.4.2 Backup checksums and database integrity checks. . . . . . . . . . . . . . 50
2.4.3 SQL Server mirrored backup media sets . . . . . . . . . . . . . . . . . . . . . 51
2.4.4 Backup a transaction log without truncate the log. . . . . . . . . . . . . . . 51
2.4.5 SQL Server replication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
2.4.6 SQL Server log shipping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
2.4.7 SQL Server database mirroring . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
2.4.8 SQL Server database snapshot . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
2.4.9 Full-Text catalogs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
2.4.10 Back up SQL Server non-database components . . . . . . . . . . . . . . 54
2.5 IBM Tivoli Storage Manager and Data Protection for SQL backup strategies
considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
2.5.1 Backup policy considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
2.5.2 Client node name considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
2.5.3 Schedule considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
2.5.4 Data Protection for SQL Server security considerations . . . . . . . . . . 63
2.5.5 Data Protection for SQL Server performance considerations . . . . . . 64
2.5.6 Clustering considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
2.5.7 Multiple SQL Servers on same machine . . . . . . . . . . . . . . . . . . . . . . 67
2.5.8 SQL Server listening on a non default port . . . . . . . . . . . . . . . . . . . . 67

Chapter 3. Installation and configuration . . . . . . . . . . . . . . . . . . . . . . . . . . 69


3.1 Installation and configuration overview . . . . . . . . . . . . . . . . . . . . . . . . . . . 70
3.1.1 IBM Tivoli Storage Manager components requirements . . . . . . . . . . 72
3.1.2 SQL Server machine configuration . . . . . . . . . . . . . . . . . . . . . . . . . . 72
3.1.3 VSS off-loaded backup configuration . . . . . . . . . . . . . . . . . . . . . . . . 74
3.1.4 Our environment overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
3.2 Detailed installation and configuration procedure . . . . . . . . . . . . . . . . . . . 77
3.2.1 Verify name resolution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
3.2.2 Configure storage pools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
3.2.3 Configure policy settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78
3.2.4 Configure node names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
3.2.5 Install the backup-archive client code . . . . . . . . . . . . . . . . . . . . . . . . 81
3.2.6 Install the Data Protection for SQL code . . . . . . . . . . . . . . . . . . . . . . 87

iv Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148TOC.fm

3.2.7 Install Copy Services code and Hardware integration module . . . . . 90


3.2.8 Specifying backup-archive client options . . . . . . . . . . . . . . . . . . . . . 95
3.2.9 Specifying Data Protection for SQL options . . . . . . . . . . . . . . . . . . . 99
3.2.10 Specifying Data Protection for SQL preferences . . . . . . . . . . . . . 103
3.2.11 Configuration on the machine running the Offloaded backups (VSS
Only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110
3.2.12 Summary of configuration files . . . . . . . . . . . . . . . . . . . . . . . . . . . 111
3.2.13 Configure the CAD and remote agent services. . . . . . . . . . . . . . . 112
3.2.14 Configure the proxy node definitions. . . . . . . . . . . . . . . . . . . . . . . 118
3.2.15 The Hardware Provider . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119

Chapter 4. Data Protection for SQL Server backup . . . . . . . . . . . . . . . . . 121


4.1 GUI overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 122
4.1.1 Menu bar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
4.1.2 Toolbar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132
4.1.3 Launching the GUI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
4.1.4 Backup and restore windows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
4.2 Legacy GUI backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135
4.2.1 Full database backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135
4.2.2 Transaction log backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137
4.2.3 Differential backups. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138
4.2.4 Group backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139
4.2.5 File backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141
4.2.6 Set backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142
4.2.7 Tail-log backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
4.3 VSS GUI backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
4.3.1 VSS GUI full backup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
4.3.2 VSS GUI off-loaded backup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 147
4.4 Working with existing backups with GUI . . . . . . . . . . . . . . . . . . . . . . . . . 148
4.4.1 Displaying existing backups using GUI . . . . . . . . . . . . . . . . . . . . . . 148
4.4.2 Inactivating backups using GUI (Legacy only) . . . . . . . . . . . . . . . . 150
4.5 CLI overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153
4.5.1 Data Protection for SQL Server 5.5 CLI new features . . . . . . . . . . 154
4.6 Legacy CLI backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155
4.6.1 Full database backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155
4.6.2 Transaction log backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158
4.6.3 Differential backups. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 159
4.6.4 Group backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
4.6.5 File backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162
4.6.6 Set backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 163
4.6.7 Tail-log backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164
4.7 VSS CLI backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165
4.7.1 VSS CLI full backup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165

Contents v
6148TOC.fm Draft Document for Review April 30, 2008 1:21 pm

4.7.2 VSS CLI off-loaded backup. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166


4.8 Working with existing backups with CLI . . . . . . . . . . . . . . . . . . . . . . . . . 167
4.8.1 Displaying existing backups using CLI . . . . . . . . . . . . . . . . . . . . . . 167
4.8.2 Inactivating backups using CLI (Legacy only) . . . . . . . . . . . . . . . . . 168

Chapter 5. Data Protection for SQL Server restore . . . . . . . . . . . . . . . . . 171


5.1 Considerations for restore operations . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
5.1.1 Display list of backups. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
5.1.2 VSS considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173
5.2 Data Protection for SQL Server GUI restore . . . . . . . . . . . . . . . . . . . . . . 173
5.2.1 Perform full database restore . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 174
5.2.2 Perform partial restores. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175
5.2.3 Restore options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175
5.3 Data Protection for SQL Server CLI restore . . . . . . . . . . . . . . . . . . . . . . 178
5.4 Restore examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179
5.4.1 Considerations for restore operations . . . . . . . . . . . . . . . . . . . . . . . 179
5.4.2 Disaster recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
5.4.3 Restore SQL Server system databases . . . . . . . . . . . . . . . . . . . . . 181
5.4.4 Complete restore. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
5.4.5 Transaction log and differential restore . . . . . . . . . . . . . . . . . . . . . . 186
5.4.6 Point in time restore . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187
5.4.7 Named point restore . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190
5.4.8 Relocate files during a restore . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
5.4.9 Partial restore . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192
5.4.10 Group and file restore . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
5.4.11 Restore into another database . . . . . . . . . . . . . . . . . . . . . . . . . . . 194
5.4.12 Restore to another machine - Legacy only . . . . . . . . . . . . . . . . . . 196
5.4.13 Restore SQL Server 2000 backup to SQL Server 2005 database 197
5.5 Standby server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197

Chapter 6. Daily operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201


6.1 Automating backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
6.1.1 IBM Tivoli Storage Manager scheduler considerations to backup SQL
Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
6.1.2 Install IBM Tivoli Storage Manager scheduler client . . . . . . . . . . . . 204
6.1.3 Configure the scripts to backup your SQL Server . . . . . . . . . . . . . . 210
6.1.4 Configure schedules on the IBM Tivoli Storage Manager server . . 215
6.2 Verifying and monitoring your backups . . . . . . . . . . . . . . . . . . . . . . . . . . 216
6.2.1 Log management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
6.2.2 Configure monitoring on IBM Tivoli Storage Manager server . . . . . 225
6.2.3 Troubleshooting tips . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227

Appendix A. Tivoli Storage Manager family of products . . . . . . . . . . . . . 233


Tivoli Storage Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234

vi Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148TOC.fm

IBM Tivoli Storage Manager Express. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235


IBM Tivoli Storage Manager Basic Edition . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
IBM Tivoli Storage Manager Extended Edition. . . . . . . . . . . . . . . . . . . . . . . . 238
Optional additional products. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239
IBM Tivoli Storage Manager for Space Management . . . . . . . . . . . . . . . . 240
IBM Tivoli Storage Manager for HSM for Windows. . . . . . . . . . . . . . . . . . 240
IBM Tivoli Storage Manager for Storage Area Networks . . . . . . . . . . . . . 240
IBM Tivoli Continuous Data Protection for Files . . . . . . . . . . . . . . . . . . . . 241
IBM Tivoli Storage Manager for System Backup and Recovery . . . . . . . . 241
IBM System Storage Archive Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . 242
Data Protection product family . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244
IBM Tivoli Storage Manager for Databases . . . . . . . . . . . . . . . . . . . . . . . 244
IBM Tivoli Storage Manager for Enterprise Resource Planning . . . . . . . . 246
IBM Tivoli Storage Manager for Mail . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
IBM Tivoli Storage Manager for Microsoft SharePoint . . . . . . . . . . . . . . . 249
IBM Tivoli Storage Manager for Advanced Copy Services . . . . . . . . . . . . 249
IBM Tivoli Storage Manager for Copy Services . . . . . . . . . . . . . . . . . . . . 250

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager


administrators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 251
SQL Server 2005 components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252
SQL Server Database Engine (RDBMS) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253
SQL Server instance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253
SQL Server database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253
Database files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255
Database filegroups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 256
Database recovery model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 258
Simple recovery model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260
Full recovery model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261
Bulk-logged recovery model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261
SQL Server security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261
SQL Server 2000 and earlier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262
SQL Server 2005 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263
Principals. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263
Securables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264
Permissions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264
SQL Server services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264
SQL Server administrative tools. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266

Abbreviations and acronyms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267

Related publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269


IBM Redbooks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
Other publications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269

Contents vii
6148TOC.fm Draft Document for Review April 30, 2008 1:21 pm

Online resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270


How to get Redbooks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
Help from IBM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270

Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271

viii Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148spec.fm

Notices

This information was developed for products and services offered in the U.S.A.

IBM may not offer the products, services, or features discussed in this document in other countries. Consult
your local IBM representative for information on the products and services currently available in your area.
Any reference to an IBM product, program, or service is not intended to state or imply that only that IBM
product, program, or service may be used. Any functionally equivalent product, program, or service that
does not infringe any IBM intellectual property right may be used instead. However, it is the user's
responsibility to evaluate and verify the operation of any non-IBM product, program, or service.

IBM may have patents or pending patent applications covering subject matter described in this document.
The furnishing of this document does not give you any license to these patents. You can send license
inquiries, in writing, to:
IBM Director of Licensing, IBM Corporation, North Castle Drive, Armonk, NY 10504-1785 U.S.A.

The following paragraph does not apply to the United Kingdom or any other country where such
provisions are inconsistent with local law: INTERNATIONAL BUSINESS MACHINES CORPORATION
PROVIDES THIS PUBLICATION "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR
IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF NON-INFRINGEMENT,
MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Some states do not allow disclaimer
of express or implied warranties in certain transactions, therefore, this statement may not apply to you.

This information could include technical inaccuracies or typographical errors. Changes are periodically made
to the information herein; these changes will be incorporated in new editions of the publication. IBM may
make improvements and/or changes in the product(s) and/or the program(s) described in this publication at
any time without notice.

Any references in this information to non-IBM Web sites are provided for convenience only and do not in any
manner serve as an endorsement of those Web sites. The materials at those Web sites are not part of the
materials for this IBM product and use of those Web sites is at your own risk.

IBM may use or distribute any of the information you supply in any way it believes appropriate without
incurring any obligation to you.

Information concerning non-IBM products was obtained from the suppliers of those products, their published
announcements or other publicly available sources. IBM has not tested those products and cannot confirm
the accuracy of performance, compatibility or any other claims related to non-IBM products. Questions on
the capabilities of non-IBM products should be addressed to the suppliers of those products.

This information contains examples of data and reports used in daily business operations. To illustrate them
as completely as possible, the examples include the names of individuals, companies, brands, and products.
All of these names are fictitious and any similarity to the names and addresses used by an actual business
enterprise is entirely coincidental.

COPYRIGHT LICENSE:

This information contains sample application programs in source language, which illustrate programming
techniques on various operating platforms. You may copy, modify, and distribute these sample programs in
any form without payment to IBM, for the purposes of developing, using, marketing or distributing application
programs conforming to the application programming interface for the operating platform for which the
sample programs are written. These examples have not been thoroughly tested under all conditions. IBM,
therefore, cannot guarantee or imply reliability, serviceability, or function of these programs.

© Copyright IBM Corp. 2008. All rights reserved. ix


6148spec.fm Draft Document for Review April 30, 2008 1:21 pm

Trademarks
IBM, the IBM logo, and ibm.com are trademarks or registered trademarks of International Business
Machines Corporation in the United States, other countries, or both. These and other IBM trademarked
terms are marked on their first occurrence in this information with the appropriate symbol (® or ™),
indicating US registered or common law trademarks owned by IBM at the time this information was
published. Such trademarks may also be registered or common law trademarks in other countries. A current
list of IBM trademarks is available on the Web at http://www.ibm.com/legal/copytrade.shtml

The following terms are trademarks of the International Business Machines Corporation in the United States,
other countries, or both:

Redbooks (logo) ® Enterprise Storage Server® System p™


AIX® FlashCopy® System Storage™
Domino® General Parallel File System™ SysBack™
DB2 Universal Database™ Informix® Tivoli Enterprise Console®
DB2® IBM® Tivoli®
DS6000™ Lotus® TotalStorage®
DS8000™ Redbooks®

The following terms are trademarks of other companies:

mySAP, SAP, and SAP logos are trademarks or registered trademarks of SAP AG in Germany and in several
other countries.

Oracle, JD Edwards, PeopleSoft, Siebel, and TopLink are registered trademarks of Oracle Corporation
and/or its affiliates.

Snapshot, Network Appliance, WAFL, SnapDrive, Data ONTAP, NetApp, and the Network Appliance logo are
trademarks or registered trademarks of Network Appliance, Inc. in the U.S. and other countries.

ITIL is a registered trademark, and a registered community trademark of the Office of Government
Commerce, and is registered in the U.S. Patent and Trademark Office.

AMD, the AMD Arrow logo, and combinations thereof, are trademarks of Advanced Micro Devices, Inc.

Solaris, and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other
countries, or both.

Active Directory, Microsoft, SharePoint, SQL Server, Windows NT, Windows Server, Windows, and the
Windows logo are trademarks of Microsoft Corporation in the United States, other countries, or both.

Intel, Pentium, Intel logo, Intel Inside logo, and Intel Centrino logo are trademarks or registered trademarks
of Intel Corporation or its subsidiaries in the United States, other countries, or both.

UNIX is a registered trademark of The Open Group in the United States and other countries.

Linux is a trademark of Linus Torvalds in the United States, other countries, or both.

Other company, product, or service names may be trademarks or service marks of others.

x Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148pref.fm

Preface

This IBM® Redbooks® publication describes how to plan, install, and implement
backup and restore for Microsoft® SQL Server® using Tivoli® Storage Manager
products. The book is aimed for Tivoli Storage Manager professionals who are
responsible for the backup and restore of an Microsoft SQL Server installation
using Tivoli Storage Manager.

We discuss planning, installation and operation of Tivoli Storage Manager with


Microsoft SQL Server. We also provide an overview of Tivoli Storage Manager
family of product. We describe some essential information regarding Microsoft
SQL Server aimed to assist Tivoli Storage Manager administrator to understand
the database middleware platform.

The team that wrote this book


This book was produced by a team of specialists from around the world working
at the International Technical Support Organization, Austin Center.

Figure 1 Marcia and Carlos

© Copyright IBM Corp. 2008. All rights reserved. xi


6148pref.fm Draft Document for Review April 30, 2008 1:21 pm

Marcia Kubo is an IT Presales Support Specialist, in Brazil. She has more than
nine years of experience in the IT field and Tivoli Storage Manager product
portifolio, starting with ADSM 3.1. Her expertise includes AIX®, IBM System p™,
IBM disk and tape. She has been working for IBM since 2004. She is an ITIL®
Certified, TotalStorage® Productivity Center V3.1 Certified, IBM Certified
Deployment Professional: Tivoli Storage Manager V5.3 and 5.4, and an IBM
Certified Advanced Technical Expert for AIX version V4. She has a degree in
System Analysis from FATEC-SP, São Paulo. She was an author of Deployment
Guide Series: Tivoli Continuous Data Protection for Files V3.1, SG24-7423 and
Deployment Guide Series: IBM Tivoli Storage Manager Version 5.4, SG24-7379

Carlos Eduardo Abramo Pinto is an IT Specialist for Database Administration


in IBM Global Services in Brazil, supporting IBM local and international
customers. He is an IBM Certified IT Specialist, with more than 12 years of IT
experience in a wide range of client and server platforms, including technical and
system support of the Windows® operating system, Oracle®, DB2®, and
Microsoft SQL Server databases in UNIX®, Linux® and Windows platforms. He
is also specialized in Oracle Real Application Clusters implementation and
support. Carlos is an IBM DB2 Certified Database Administrator on DB2 UDB
V8.1 for Linux, UNIX and Windows, an Oracle Certified Professional on Oracle
8i, 9i and 10g databases, a Microsoft Certified IT Professional Database
Administrator and Database Developer for Microsoft SQL Server 2005, a
Microsoft Certified Database Administrator for Microsoft SQL Server 7 and 2000,
and a Microsoft Certified System Engineer on Windows NT® 4 and 2000. He is
an author of Oracle to DB2 Conversion Guide for Linux, UNIX, and Windows,
SG24-7048.

Thanks to the following people for their contributions to this project:

Charlotte Brooks, Budi Darmawan


International Technical Support Organization

Del Hoobler, Mark Yakushev


Tivoli Storage Manager development

Thanks to the authors of the previous editions of this book.


򐂰 Authors of the first edition, Using Tivoli Data Protection for Microsoft SQL
Server, SG24-6148, published in May 2001, were:
Pat Randall, Ivanka Kabranova, Jan Sternberg, Marcus Thordal

xii Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148pref.fm

Become a published author


Join us for a two- to six-week residency program! Help write a book dealing with
specific products or solutions, while getting hands-on experience with
leading-edge technologies. You will have the opportunity to team with IBM
technical professionals, Business Partners, and Clients.

Your efforts will help increase product acceptance and customer satisfaction. As
a bonus, you will develop a network of contacts in IBM development labs, and
increase your productivity and marketability.

Find out more about the residency program, browse the residency index, and
apply online at:
ibm.com/redbooks/residencies.html

Comments welcome
Your comments are important to us!

We want our books to be as helpful as possible. Send us your comments about


this book or other IBM Redbooks in one of the following ways:
򐂰 Use the online Contact us review Redbooks form found at:
ibm.com/redbooks
򐂰 Send your comments in an e-mail to:
[email protected]
򐂰 Mail your comments to:
IBM Corporation, International Technical Support Organization
Dept. HYTD Mail Station P099
2455 South Road
Poughkeepsie, NY 12601-5400

Preface xiii
6148pref.fm Draft Document for Review April 30, 2008 1:21 pm

xiv Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148chang.fm

Summary of changes

This section describes the technical changes made in this edition of the book and
in previous editions. This edition may also include minor corrections and editorial
changes that are not identified.

Summary of Changes
for SG24-6148-01
for Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
as created or updated on April 30, 2008.

May 2008, First Edition


This revision reflects a new write up of the Tivoli Storage Manager for Databases,
Microsoft SQL Server Data Protection on the current level of the product.
Replacing the existing book regarding Tivoli Data Protection for Microsoft SQL
Server.

© Copyright IBM Corp. 2008. All rights reserved. xv


6148chang.fm Draft Document for Review April 30, 2008 1:21 pm

xvi Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

Chapter 1. Introduction
In this chapter we provide you with an overview of IBM Tivoli Storage Manager
Data Protection for SQL Server, as well as the associated technologies such as
the Volume Shadow Copy Service (VSS), Virtual Disk Services (VDS), and
snapshot techniques.

By integrating VSS-based snapshot capabilities with IBM Tivoli Storage Manager


and its data protection component for Microsoft SQL Server, IBM Tivoli Storage
Manager for Copy Services provides enhanced backup and recovery features
that are integrated with existing Microsoft SQL backup and restore capabilities.

The following topics are discussed:


򐂰 1.1, “Tivoli Storage Manager overview” on page 2
򐂰 1.2, “Snapshots” on page 9
򐂰 1.3, “Volume Shadow Copy Service” on page 13
򐂰 1.4, “The Microsoft Virtual Disk Service” on page 19
򐂰 1.5, “VSS Service with Tivoli Storage Manager” on page 20
򐂰 1.6, “Integration between Data Protection and SQL Server” on page 22

© Copyright IBM Corp. 2008. All rights reserved. 1


6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

1.1 Tivoli Storage Manager overview


IBM Tivoli Storage Manager is a powerful storage management software suite
that addresses the challenges of complex storage management in distributed
heterogeneous environments. It protects and manages a broad range of data,
from workstations to corporate environments. Heterogeneous platforms
coverage for 13 different operating system environments, scalable from PC
servers to UNIX and mid-range servers to zOS mainframe servers. It is the
premier choice for complete storage management in mixed platform
environments.

IBM Tivoli Storage Manager protects an organization’s data against failures and
other errors by storing backup and archive copies of data in offline storage.

IBM Tivoli Storage Manager provides:


򐂰 Centralized Web-based management
򐂰 Fully automated data protection
򐂰 Efficient automated data protection
򐂰 High-speed automated server recovery
򐂰 Support over 500 devices (including disk, tape and optical)
򐂰 Smart data-movement and storage techniques and comprehensive
policy-based automation which work together to minimize data protection
administration costs and the impact to both computers and networks
򐂰 Manage costs and address compliance with regulatory data retention
requirements
򐂰 Optional modules enables business-critical applications that must run
24x7x365 to protect their data without interruption.

IBM Tivoli Storage Manager enables you to protect your organization’s data from
failures and other errors by storing backup, archive, space management and
bare-metal restore data, as well as compliance and disaster data in a hierarchy
offline storage. IBM Tivoli Storage Manager is available in three editions;
Express, Basic Edition, and Extended Edition and there are other optional
modules to enhance the backup solution.

You can see a briefly description of IBM Tivoli Storage Manager family products
in Appendix A, “Tivoli Storage Manager family of products” on page 233. More
detailed information on Tivoli Storage Management and other additional products
can be found in IBM Tivoli Storage Management Concepts, SG24-4877.

Figure 1-1 shows the Tivoli Storage Manager family of products.

2 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

Server Products
Entry-level backup and recovery

IBM Tivoli Storage Large Libraries NDMP Backups


Manager Express

+
IBM Tivoli Storage IBM System
Manager Extended Edition Storage Archive
IBM Tivoli Storage Manager
Manager Disaster Recovery Planning and Recovery Compliance with
regulatory requirements

Client Products
Basic Business
Basic Protection Real Time File Protection LAN-Free Backup application protection
IBM IBM
Standard
Continuous Tivoli Storage
Backup-archive DB2 and Informix
Data Protection Manager
client
for Files for SAN

Complete
Business Application Protection Advanced Replication HSM
system recovery
IBM Tivoli Storage IBM Tivoli Storage IBM Tivoli Storage
IBM Tivoli Storage IBM Tivoli Storage
Manager for Manager for Manager for
Manager for Manager for
Mail (MS Exchange Databases (Oracle / System Backup and
Copy Services Space Management
/ Notes) MS SQL) Recovery
IBM Tivoli Storage
IBM Tivoli Storage IBM Tivoli Storage IBM Tivoli Storage
Manager for Cristie Bare
Manager for Manager for Manager HSM for
Advanced Copy Machine Recovery
ERP MS Share Point Windows
Services

Figure 1-1 IBM Tivoli Storage Manager product family

You can use IBM Tivoli Storage Manager products family to perform an online,
consistent and centralized backups of your SQL Server database, avoiding
downtime, protect vital enterprise data infrastructure and minimize operation
costs.

Today, beyond maintain availability of application, it is necessary to attend


requirements as zero-impact backups and instant recovery. To take care of of
these demands on your SQL Server environment you can integrate Data
Protection for SQL and IBM Tivoli Storage Manager for Copy Services, products
of IBM Tivoli Storage Manager family.

1.1.1 IBM Tivoli Storage Manager components


The IBM Tivoli Storage Manager server component is installed on the computer
that manages storage devices. The IBM Tivoli Storage Manager provides the
following functions:
򐂰 Data management
򐂰 Storage device and media management
򐂰 Reporting and monitoring functions

Chapter 1. Introduction 3
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 System security

IBM Tivoli Storage Manager server applications is supported by a relational


database that is specifically designed to manage a data storage environment.
The server database operates transparently, requiring minimal administrative
oversight. The server relies on the database to maintain an inventory of metadata
associated with stored data objects. The database is not used to storage actual
client data, which is maintained in server-managed storage. Server operations
are configured, controlled, and monitored using graphical or command-line
interfaces. Some tasks can be performed several different ways, so the interface
you use depends on the type of task and your preferences. Support for SQL
SELECT statements and ODBC data transfer is also available for advanced
database management and reporting. Figure 1-2, shows the IBM Tivoli Storage
Manager components.

Policy Domain
Active Policy Set
Integrated Solution
TSM Web UI Console Managem ent
Class

Backup
Local Area Network Scheduler Copy
10
9
11
12
1
2
3
Group
8 4
7 5

Log
6

Archive
10
11
12
1
2
3
Copy
Group
9
8 4
7 5
6

Scheduler
Database

Servers, Clients,
Application systems
Storage Area Network

Storage
Repository

Client Nodes TSM Server

Figure 1-2 IBM Tivoli Storage Manager architecture

IBM Tivoli Storage Manager client overview


The IBM Tivoli Storage Manager client component sends data to, and retrieves
data from, a IBM Tivoli Storage Manager server. IBM Tivoli Storage Manager
client must be installed on every machine that will transfer data to
server-managed storage. The IBM Tivoli Storage Manager server uses a unique
node name to identify each IBM Tivoli Storage Manager client instance. A
password can be used to authenticate communications between the IBM Tivoli

4 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

Storage Manager client and server. Data can be recovered to the same client
machine that initially transferred it, or to another client with a compatible file
system format.

The IBM Tivoli Storage Manager client basically consists of the software
component and a customization file. The customization file, called the client
options file, specifies client/server communications parameters and other IBM
Tivoli Storage Manager client settings. Client communications parameters must
agree with those specified in the server options file. The client options is located
in the client directory and can be modified using a text editor. The client graphical
interface also provides a wizard for editing this file. IBM Tivoli Storage Manager
provides the following types of clients:
򐂰 Backup-archive client
The backup-archive client provides standard IBM Tivoli Storage Manager
client function, which includes four operations: backup, restore, archive and
retrieve. These operations can be performed manually from the client
machine or remotely using a web-based interface. Backup and archive
operations can also be scheduled to run automatically.
򐂰 Data Protection client
Data Protection client, also called and application client, allows for the backup
and restoration of data used by various business applications. Data
Protection receives backup and restore requests from the business
application and translates them for IBM Tivoli Storage Manager server
processing. Backup and restore processing can be done while the business
application is online.
򐂰 Space Manager client
The Tivoli Space Manager client, also called Hierarchical Storage Manager
(HSM), transparently migrates data from the client hard drive to IBM Tivoli
Storage Manager server-managed storage. When the migrated data is
accessed through the client file system, it it transparently recalled back onto
the local disk. The migration and management of files is controlled by policy
defined to the IBM Tivoli Storage Manager server. End users can also
explicitly migrate and recall data. HSM client functions is fully integrated with
IBM Tivoli Storage Manager operational backup and client functions.
򐂰 Application Programming Interface client
The Application Programming Interface (API) client allows you to create
custom IBM Tivoli Storage Manager implementations. The API client can be
used to integrate business applications, such as databases or groupware, into
a IBM Tivoli Storage Manager environment.

Chapter 1. Introduction 5
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

1.1.2 IBM Tivoli Storage Manager for Copy Services overview


IBM Tivoli Storage Manager for Copy Services helps you to back up and restore
critical data so that it remains available 24 x 7.

Implement high efficiency backup and restore processess for your critical
business applications with little impact on production performance.IBM Tivoli
Storage Manager for Copy Services provides:
򐂰 Enhanced backup and recovery features that are integrated with existing
Microsoft SQL Server backup and restore capabilities
򐂰 Delivers fast backup with minimal impact on your prodution SQL Server with a
variety of snapshot providers
򐂰 Provides near instant restoration of SQL Server databases from a shadow
copy image to the production volumes
򐂰 Features policy-based management of multiple local backup versions so that
recovery for multiple versions is easy
򐂰 Improves availability and performance of production database servers with
offloaded moviment
򐂰 Integrates snapshot capabilities with IBM Tivoli Storage Manager and its data
protection component for Microsoft SQL Server
򐂰 The only operating supported is Windows

There are two installable modules included in the package IBM Tivoli Storage
Manager for Copy Services. Once installed, these modules enable certain menu
options in the Data Protection for SQL GUI which are otherwise unavailable.
These modules, Microsoft SQL VSS Integration Module and Hardware Devices
Snapshot™ Integration Module.

Microsoft SQL Server VSS Integration Module


This component is used with IBM Tivoli Storage Manager for Databases for SQL,
and enables the use of Microsoft VSS technology to produce an online snapshot
of the SQL data that can be stored on local shadow volumes or on IBM Tivoli
Storage Manager server storage. A license file (ascsql.lic) is installed in the
installation directory of Data Protection for SQL Server which allows you to use
IBM Tivoli Storage Manager for Copy Services. This module is required for all
VSS operations with Data Protection for SQL.

Hardware Devices Snapshot Integration Module


This component is used with IBM Tivoli Storage Manager for Databases for SQL
Server. It contains two .dll files (pisnaphdw.dll and pihdw.dll) and two license files
(aschdw.lic and acssnp.lic), which are installed in the installation directory of IBM

6 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

Tivoli Storage Manager backup-archive client. This module is only required to


perform a VSS Instant Restore.

1.1.3 Data Protection for SQL Server


Data Protection for SQL Server allows you to perform online backups and
restores of Microsoft SQL Server Databases to IBM Tivoli Storage Manager
Server storage using either command-line or graphical user interfaces (GUI) on
Windows 2000 and Windows 2003, in a standalone or clustered environment.

Data Protection for SQL Server helps protect and manage SQL Server data by
making it easy to:
򐂰 Back up any SQL database to any Tivoli Storage Manager Server.
򐂰 Perform full and transaction log backups and restores of SQL databases.
򐂰 Perform backups with an expanded range of options such as differential, file,
and group operations.
򐂰 Perform operations from multiple SQL Server instances on the same machine
as Data Protection for SQL. You can access only one SQL Server per
execution of Data Protection for SQL Server from either the command line or
GUI.
򐂰 Automated scheduled backups.
򐂰 Perform expanded restore operations on backup objects such as relocating,
restoring to named marks, and partially restoring full backups.
򐂰 Restore database backups to a different SQL Server. Data Protection for SQL
Server can restore database backups that were performed on either 32-bit or
64-bit versions of SQL Server. Refer to Microsoft documentation on what
combinations are supported by Microsoft.
򐂰 Retain with a backup the information needed to recreate or move SQL
databases or files, such as sort order, code page, and Unicode information, or
file group and file logical and physical names. The meta object information is
retained on the IBM Tivoli Storage Manager separately from the backup data
objects.
򐂰 Inactivate all active Legacy objects, all objects of a particular backup type, or
specific objects.
򐂰 Inactivate Legacy backup objects older than a specified number of days.
򐂰 Set automatic expiration of backup objects based on version limit and
retention period.
򐂰 Query any local SQL Server or any connected Tivoli Storage Manager Server
for database, status, and configuration information.

Chapter 1. Introduction 7
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Monitor results through the Data Protection for SQL Server activity log and
automatically prune the activity log.
򐂰 Set Tivoli Storage Manager connection information options to IBM Tivoli
Storage Manager Servers.
򐂰 Set IBM Tivoli Storage Manager security and performance options.
򐂰 Participate in MSCS and fail-over clusters and VCS failover clusters.
򐂰 Set Tivoli Storage Manager security and performance options.
򐂰 Apply fail-over clustering (for maintenance or restoring the master database)
without unclustering.
򐂰 Apply fail-over clustering (for maintenance or restoring the master database)
without unclustering.
򐂰 Globalization support.

Data Protection for SQL operations use the IBM Tivoli Storage Manager API to
communicate with the IBM Tivoli Storage Manager server, and use the SQL
Server API to communicate with the SQL Server.

When IBM Tivoli Storage Manager for Copy Services is installed together with
Data Protection for SQL, you can also perfom online snapshot backups to local
shadow volumes, using VSS. These snapshot backups can be retained on the
local shadow volumes, and also backed up to IBM Tivoli Storage Manager server
storage.

To reduce the overhead of backup operations on the SQL Server, you can
choose to have the backup to IBM Tivoli Storage Manager performed by another
server with access to the shadow volumes from either local snapshots volumes,
or from IBM Tivoli Storage Manager server storage.

What’s new in Data Protection for SQL Server Version 5.5


The following features and functions have been added to Data Protection for SQL
Server Version 5.5.
򐂰 VSS backup
Backup SQL Server 2000 and SQL Server 2005 databases (running on
Windows Server® 2003) using Microsoft Volume Shadow Copy Services
(VSS) technology.
A VSS Backup uses Microsoft Volume Shadow Copy Service technology to
produce online snapshot (point-in-time consistent copy) of SQL data that can
be stored on local shadow volumes or on Tivoli Storage Manager server
storage.
򐂰 Microsoft SQL version support

8 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

Data Protection for SQL Server supports Microsoft SQL 2000 and 2005 on
Windows 32-bit and 64-bit environments.
򐂰 Veritas Cluster Server (VCS) support
Data Protection for SQL Server supports SQL Server running in a VCS
environment. For Windows 2003, Data Protection for SQL Server uses the
Active Directory® to support fail-over clustering.
򐂰 Off-loaded backup
Perform a VSS Backup to IBM Tivoli Storage Manager server using an
alternate machine instead of a production machine.
򐂰 Restore VSS
Restore VSS Backups that reside on IBM Tivoli Storage Manager server
storage to their original location.
򐂰 VSS fast restore
Restore VSS backups that reside on local shadow volumes using file-level
copy mechanisms.
򐂰 VSS instant restore
Restore VSS backups that reside on local shadow volumes using
hardware-assisted volume-level copy mechanisms.
򐂰 Server policy
IBM Tivoli Storage Manager policy-based management of VSS snapshot
backups.

1.2 Snapshots
Snapshot is a common industry term which means the ability to record the data
stored on a storage device at any given moment and preserve that snapshot as a
way to perform backup, restore, data mining or even testing.

1.2.1 Snapshot overview


A snapshot creates a point-in-time copy of data on a disk volume. Typically, a
snapshot copy is done instantly and made available for use by other applications
such as data protection, data replication, data analysis and reporting. The
original copy of the data continues to be available to the applications without
interruption, while the snapshot copy is used to perform other functions on the
data.

Chapter 1. Introduction 9
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

Snapshots provide an excellent means of data protection, and their use is


increasing because of the way the technology addresses many of the issues that
businesses face. Snapshots can do the following:
򐂰 Enable better application availability, faster recovery, and easier backup
management of large volumes of data
򐂰 Reduce exposure to data loss while virtually eliminating backup windows

Snapshots come in many different flavors depending on how a particular vendor


chooses to implement the technique. A snapshot method may be
hardware-specific (that is, implemented for a particular type of storage system),
or it may be implemented in software, so that it can be used with different types
of storage hardware. In the following sections we describe principal
implementations that are commonly found, along with some examples.

1.2.2 Copy-on-write
In the copy-on-write method, a snapshot of a storage volume is created using
pre-designated space for the snapshot. When the snapshot is first created, only
the metadata about where the original data is stored is copied. No physical copy
of the data is done at the time the snapshot is created. Therefore, the creation of
the snapshot is almost instantaneous.

The snapshot copy then tracks the changing blocks on the original volume as
writes to the original volume are performed. The original data that is being written
to is copied into the designated volume that is set aside for the snapshot before
original data is overwritten, hence the name copy-on-write.

Before a source block can be written to, the copy-on-write method copies the
original data block to the snapshot storage. This keeps the snapshot data
consistent with the exact time the snapshot was taken. Read requests to the
snapshot volume of unchanged data blocks are redirected to the original volume,
while read requests to data blocks that have been changed are directed to the
“copied” blocks in the snapshot. The snapshot contains the metadata that
describes the data blocks that have changed since the snapshot was first
created. Note that original data blocks are copied only once into the snapshot
storage, when the first write request is received.

Copy-on-write snapshot may initially impact performance on the original (source)


volume while it exists, because write requests to the original volume must wait
while the original data is being “copied out” to the snapshot. The read requests to
snapshot are satisfied from the original volumes if data being read has not
changed. Additionally, the snapshot requires that original copy of the data is still
valid.

10 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

However, this method is highly space-efficient, because the storage required to


create a snapshot is minimal to hold only the data that is changing.

IBM FlashCopy® (NOCOPY), AIX JFS2 snapshot, IBM General Parallel File
System™ snapshot, Linux Logical Volume Manager, and IBM Tivoli Storage
Manager Logical Volume Snapshot Agent (LVSA) are all based on copy-on-write.

1.2.3 Redirect-on-write
The redirect-on-write method is quite similar to copy-on-write, without the double
write penalty. With redirect-on-write, new writes to the original volume are
redirected to another location set aside for snapshot.

The advantage of redirecting the write is that only one write takes place, while
with copy-on-write, two writes occur (one to copy the original data onto the
storage space, and the other to copy the changed data). However, with
redirect-on-write, the original copy contains the point-in-time data (that is,
snapshot), and the changed data reside on the snapshot storage. When a
snapshot is deleted, the data from the snapshot storage must be reconciled back
into the original volume.

Furthermore, as multiple snapshots are created, access to the original data,


tracking of the data in snapshots and original volume, and reconciliation upon
snapshot deletion is further complicated. The snapshot relies on the presence of
the original copy of the data, and the original data set can quickly become
fragmented. IBM N series and the NetApp® Filer snapshot implementation are
based on redirect-on-write.

1.2.4 Split mirror


Split mirror creates a physical clone of the storage entity (such as the file system,
volume, or LUN for which the snapshot is being created) onto another entity of
the same kind and the exact same size. The entire contents of the original
volume are copied onto a separate volume. Clone copies are highly available,
since they are exact duplicates of the original volume that reside on a separate
storage space. However, due to the data copy, such snapshots cannot be created
instantaneously.

Alternatively, a clone can also be made available instantaneously by splitting a


pre-existing mirror of the volume into two, with the side effect that the original
volume has one fewer synchronized mirror. This snapshot method requires as
much storage space as the original data for each snapshot, and has the
performance overhead of writing synchronously to the mirror copy.

Chapter 1. Introduction 11
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

1.2.5 Copy-on-write with background copy


Some vendors offer an implementation where a full copy of the snapshot data is
created using copy-on-write and a background process that copies data from the
original location to snapshot storage space. This approach combines the benefits
of the copy-on-write and split mirror methods and is seen in IBM FlashCopy and
EMC TimeFinder/Clone.

It uses copy-on-write to create an instant snapshot and then optionally starts a


background copy process to perform a block-level copy of the data from the
original volume (source volume) to the snapshot storage (target volume) in order
to create an additional mirror of the original volume.

1.2.6 IBM FlashCopy


By doing a FlashCopy, a relationship is established between a source and a
target. Both are considered to form a FlashCopy pair.

As a result of the FlashCopy, either all physical blocks from the source volumes
are copied (full copy) or, when using the nocopy option, only those parts which
change in the source data since the FlashCopy has been established. Currently,
the target volumes needs to ve the same size or bigger that the source volume
whenever FlashCopy is used to flash a whole volume.

Typically, large applications such as databases have their data spread across
serveral volumes and their volumes should all be FlashCopied at exactly the
same point-in-time. FlashCopy offers Consistency Groups, which allows multiple
volumes to be FlashCopied at exactly the same instance.

Incremental FlashCopy tracks changes made to the source and target volumes
when the FlashCopy relationships are established. This provides the capability to
refresh a logical unit (LUN) or volume to the source or target's point-in-time
content using only the changed data. The refresh can occur in either direction,
and it offers improved flexibility and faster FlashCopy completion times.

This incremental FlashCopy option can be used to efficiently create frequent and
faster backups and restore without the penalty of having to copy entire content of
the volume. This is shown in Figure 1-3 on page 13.

12 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

FlashCopy provides a point-in-time copy

Source Target
FlashCopy command issued

Copy immediately available

Write Read Read


Write
Time Read and write to both source
and copy possible
T0

When copy is complete,


relationship between
source and target ends

Figure 1-3 FlashCopy Concepts

1.3 Volume Shadow Copy Service


The Volume Shadow Copy Service (VSS) provided with Microsoft Windows
Server 2003 is an enhanced Storage Management feature that provides a
framework and an API that enables the creation of consistent point-in-time
copies of data known as shadow copies. The VSS service enables the
interoperability of third-party storage management programs, business
programs, and hardware providers in order to create and manage shadow
copies.

Several features in Windows Server 2003 already use the Volume Shadow Copy
Service, such as Shadow Copies for Shared Folders and Backup.

1.3.1 Methods for creating shadow copies


The shadow copy creation can be performed using two distinct snapshot
methods:
򐂰 Full copy
򐂰 Differential copy (copy-on-write)

Chapter 1. Introduction 13
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

The full copy is usually achieved using a hardware provider (see “Provider” on
page 16).

1.3.2 The VSS model


VSS is designed to address problems associated with traditional backup
methods (such as inaccessible files during a backup and inconsistent file state
during backup), and minimize interruptions to production servers during backup,
as described here.

The shadow mechanism


The following are the mechanism for VSS:
򐂰 VSS provides fast volume capture of the state of a disk at a particular point in
time (a shadow copy of the volume).
򐂰 This volume copy exists side by side with the live volume, and contains copies
of all files on disk.
򐂰 The volume is effectively saved and available as a separate device.
򐂰 VSS provides a stable source for backup operations since it is read-only, while
allowing ongoing applications to update the original volumes.

Coordination with applications for consistent file state


VSS integrates with participating applications (such as Microsoft SQL Server) by
providing COM-based events. This means that the application itself determines
the system state for backup, restore, and shadow copy (volume capture)
operations, and communicates the state to VSS. An application which is writing
to the disk is also responsible for bringing all associated files into a consistent
state, before creating the shadow copy.

Minimizes application downtime


Creating a shadow copy typically takes about seconds or minutes, depending on
the VSS provider. The application is only paused between the so-called Freeze
and Thaw VSS events.

Unified interface to VSS


VSS abstracts the shadow copy mechanisms within a common API. This means
that any backup application (requestor) and any writer should be able to run on
any disk storage system that supports the VSS interface. It also gives the
opportunity for individual hardware vendors to add and manage unique features
for its own providers.

14 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

Multivolume backup
A shadow copy set is a collection of shadow copies. VSS supports these sets
across multiple types of disk volumes from different vendors. All shadow copies
in a shadow copy set will be created with the same time stamp and will present
the same disk state.

Native shadow copy support


Shadow copy support is available through VSS as a native part of the Windows
operating system (Windows XP, Windows 2003). Note that Tivoli Storage
Manager for Copy Services is supported only on Windows 2003, not XP. VSS
shadow copies can be made on any disk attached to the system, as long as there
is at least one NTFS disk present on the system.

1.3.3 The VSS architecture


The VSS framework coordinates the communication between VSS requestors,
VSS writers, and VSS providers. Figure 1-4 illustrates the VSS architecture.

Requestor

Volume Shadow
Writers
Copy Service
Apps

I/O
System Software Hardware
Provider Provider Provider

Volumes Volumes Volumes

Figure 1-4 VSS architecture

Chapter 1. Introduction 15
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

Requestor
The requestor is a management application that invokes VSS in order to create
and manage shadow copy sets of one or more volumes. This role is typically
used to implement other functionalities like backup, restore, and disk mirroring
operations.

A backup application is an example of a requestor.

Writer
The writer is an application or Windows Service that manages its I/O operations
with VSS shadow copy and shadow copy-related operations, ensuring the data
contained on the shadow copied volume is in a consistent state.

SQL Server 2005 is an example of a writer.

Provider
The VSS provider is a component that creates and maintains the shadow copies.
A VSS provider is provided either by a storage vendor for their particular storage
systems (hardware provider) or by a software vendor (software provider). A
special case of a software provider is the Microsoft Windows System Provider,
which is implemented in Windows 2003. This is known as the system software
provider.

When using a hardware provider, the snapshot is performed at the storage


system controller level - for example, using FlashCopy on IBM storage systems
like the DS6000/ DS8000/ SVC, or SnapDrive® on NetApp NAS systems.
Furthermore, if this provider supports transportable shadow copies, the backup
operations can be performed by another machine (offloaded backup).

A software provider, including the Windows native system software provider, can
be used with storage systems that do not have their own hardware provider.

If you have a hardware provider available for your disk system, we recommend
that you use this, since the work of actually making the snapshot is performed by
the disk system itself. A software provider (including the system software
provider), by comparison, must do all the work in software on the actual SQL
server. If you are using the Windows system software provider, this uses
copy-on-write. Therefore, there is significant performance overhead to using a
software provider.

However, you should balance this against the ease of setup - using a hardware
provider requires more initial configuration than a software provider. We provide
additional guidance for selecting which provider to use in “VSS provider” on page
12.

16 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

The Volume Shadow Copy Service selects the provider using the following order:
򐂰 Hardware provider
򐂰 Software provider
򐂰 System software provider

That is, VSS looks first for a hardware provider that supports the disk system and
uses it. If no hardware provider is found, a software provider will be used, if
available. If there is no other provider, then the Microsoft system software
provider will be used.

The requester can override this order if desired.

Source volume
A source volume is a disk volume containing data to be shadow copied.

Storage or target volume


A storage or target volume is a disk volume holding data which has been shadow
copied from a source volume. Some VSS provider snapshot implementations
require that the target volume be the same size as the source volume, and some
do not.

1.3.4 How shadow copies are created


Figure 1-5 on page 18 illustrates the steps in creating a shadow copy.

Chapter 1. Introduction 17
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

1
4 2
Volume Copy Shadow
Requestor 5 Service 7 Writers
8 8
Apps
6

3 I/O

Software Hardware
Provider Provider

6 6

Figure 1-5 Shadow copy creation process

The process is as follows:


1. The requestor asks the VSS to list the writers, gather the writer metadata, and
prepare to create the shadow copy.
2. The writer creates an XML description of the backup components to the VSS,
and defines the restore method. The VSS notifies the application-specific
writer to prepare its data for making a shadow copy.
3. The writer prepares the data as appropriate, such as completing all open
transactions, rolling transaction logs, and flushing caches. When the data is
ready for shadow copy creation, the writer notifies the VSS.
4. The VSS initiates the “commit” shadow copy phase.
5. The VSS tells the writer to quiesce its data and temporarily freeze requestor
(application) I/O write requests (I/O read requests are still possible) for the
several seconds required to create the shadow copy of the volume(s). The
VSS flushes the file system buffer and then freezes the file system, to ensure
that file system metadata is written and that the data is written in a consistent
order.
6. The VSS tells the provider to create the shadow copy.
7. The VSS thaws the file system. After the shadow copy is created, the VSS
signals the writer it can now complete all queued write I/Os, since the
temporary inactive phase is over.

18 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

8. The VSS queries the writers to confirm that write I/Os were successfully
suspended while the shadow copy was created. If the writes were not
successfully suspended (meaning that the shadow copy data is potentially
inconsistent), the shadow copy is deleted and the requestor is notified. The
requestor can retry the process (go back to step 1) or notify the administrator
to retry at a later time. If the copy is successful, the VSS gives the location
information for the shadow copy back to the requestor.

1.3.5 Shadow copy types


There are three types of VSS shadow copy which can be made.
򐂰 Persistent shadow copy
A persistent shadow copy survives reboots. Persistent shadow copies cannot
be auto-released by VSS.
򐂰 Non-persistent shadow copy
A non-persistent shadow copy will be deleted after the backup operation is
complete. It is also known as an auto-release shadow copy. The default for
shadow copies is non-persistent.
򐂰 Transportable shadow copy
A transportable shadow copy can be moved from one server to another.
When a shadow copy is transported, the target volume(s) are dismounted
from the server which initiated the shadow copy, and mounted onto another
server. Transportable shadow copies require use of a VSS hardware provider
and enable the offloaded backup function.

1.4 The Microsoft Virtual Disk Service


Microsoft Virtual Disk Service (VDS) was introduced in the Windows 2003 Server
to provide a single interface for management and configuration of multivendor
direct attached and SAN-based storage.

VDS is a set of APIs that provides a single interface for multivendor storage
management. Each hardware vendor develops its own VDS hardware provider in
order to translate the general purpose VDS APIs into their specific hardware
instructions.

VDS is part of Microsoft’s Storage Services - the other two components are
Remote Storage and Removable Storage.

VDS uses two sets of providers to manage storage devices:

Chapter 1. Introduction 19
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 The built-in VDS software providers that manage disks and volumes at the
operating system level.
򐂰 Hardware providers supplied by the hardware vendor that manage their
specific hardware.

The Virtual Disk Service is used for managing LUNs on hardware storage
devices; managing disks and volumes; and managing end-to-end storage
operations

Figure 1-6 on page 20 illustrates the Virtual Disk Service architecture.

Storage
Command MMC / Disk Backoffice Management
line utilities Management applications Applications

Virtual Disk Service

Software
providers: Hardware
Basic
Basic disks
disks providers
Dynamic
Dynamic disks
disks

Figure 1-6 VDS architecture

Tivoli Storage Manager for Copy Services integrates with VSS and any
supported disk storage system in order to easily exploit the snapshot on the
hardware side and manage the LUN allocation.

1.5 VSS Service with Tivoli Storage Manager


Tivoli Storage Manager can perform VSS backup of SQL Server databases using
Tivoli Storage Manager for Databases Data Protection for SQL Server together
with Tivoli Storage Manager for Copy Services and the Tivoli Storage Manager
backup/archive client. We refer to this entire combined solution generically as

20 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

Data Protection for SQL, with the understanding that VSS backup requires the
additional module Tivoli Storage Manager for Copy Services.

The VSS Service manages and directs three VSS software applications that are
used during VSS operations.
򐂰 VSS Writer
The VSS Writer is the Microsoft SQL Server. It is installed with the SQL
Server 2005 software and requires no configuration.
򐂰 VSS Requestor
The VSS Requestor is the IBM Tivoli Storage Manager backup-archive client.
The requestor communicates with the VSS to access the SQL Server data.
Data Protection for SQL servers as the front end for VSS backup; that is, is
the user interface for initiating backup and restore operations; however it
communicates with the backup-archive client as VSS requestor to actually
perform the backup and restore
򐂰 VSS Provider
The VSS provider manages the volumes where the SQL data resides and
performs the actual snapshot copy. You can use either VSS software provider
(including the Windows system provider), or a hardware provider with Data
Protection for SQL. You will need to configure the provider according to the
vendor’s specific instructions.
Configuration requirements are based upon the type of VSS provider used.
Some VSS providers are more complex to set up initially, but subsequently
provide more powerfull funcionality and can also decrease the overhead on
the SQL Server.
Follow some guidelines to choose which VSS provider meets the needs for
SQL Server backup:
– If you are using the standard Windows System provider, very little initial
configuration is required. This is the quickest and simplest way to set up
Data Protection for SQL for VSS backups. However, the copy-on-write
snapshots are then maintained within the production SQL Server, which
will impose an additional overhead.
– If you are using a VSS software provider, consult the documentation
provided with your VSS software provider.
– If your SQL databases are configured on a disk storage subsystem and
you plan to perfom off-loaded backups or full-copy snapshot backups, you
must install a VSS hardware provider.
– VSS Instant Restores are only supported by IBM System Storage™ SAN
Volume Controller, DS6000™, and DS8000™ storage subsystems, in
association with the VSS hardware provider. Therefore, you must install

Chapter 1. Introduction 21
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

and configure IBM TotalStorage Support for Microsoft Virtual Disk and
Volume Shadow Copy Services as your VSS hardware provider in order to
perform VSS Instant Restores.

1.6 Integration between Data Protection and SQL Server


In this section we discuss how Data Protection for SQL Server integrates with
SQL Server, and what options are offered to backup and restore SQL Server
databases. Data Protection for SQL Server must be installed on the same server
as the SQL Server. If you are planning to have zero impact backup and instant
restore, considerer the installation of IBM Tivoli Storage Manager Copy Services
on the same machine.

Data Protection for SQL Server has both a GUI and command line interface
available.

1.6.1 Data Protection for SQL Server backup methods


Two types of backup are available: legacy backup and VSS backup.

Legacy backup
A legacy backup is a specialized API backup that functions with the SQL Server
storage engine, as show in Figure 1-7. This is the type of backup provided by
previous releases of Data Protection for SQL.

SQL Database and Data Protection for SQL

Tivoli
Data Storage
SQL API SQL API TSM
Protection Manager
Server
for SQL Server

Figure 1-7 Data Protection for SQL legacy backup communications

A legacy backup creates a copy of all or part of an SQL database onto Tivoli
Storage Manager storage media. Data Protection for SQL Server provides
selection mechanisms and the logic that are required to backup and restore SQL
data.

22 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

When you initiate a legacy backup operation, Data Protection for SQL executes
the following steps:
1. Starts a session with the server using the API IBM Tivoli Storage Managerand
information contained in a client options file.
2. Starts a sessions with the SQL Server using internal Microsoft interface,
known as SQL-DMO (Distributed Management Objects).
3. Instructs the SQL Server using the Microsoft SQL-VDI (Virtual Device
Interface) to begin a backup of the selected database objects.
4. Receives data from the SQL Server and sends it to the Tivoli Storage
Manager server.
5. Ends the TSM Server and SQL Server sessions.

Note: When a backup is performed, Data Protection for SQL Server records
information about the SQL Server and database. This information is available
for query and restore operations. The information about the names and sizes
of the database file groups and files is stored along with the database data, as
sub-object. This sub-object is referred to as meta data. You will need ths
sub-object when you need information about individual database file groups
and files.

The following characteristics are true of Legacy backup:


򐂰 Full, copy, incremental, differential, anda database copy types are supported
򐂰 Backup granularity is at the database level
򐂰 Backups are stored on IBM Tivoli Storage Manager server storage
򐂰 Backups are managed through IBM Tivoli Storage Manager server policy
򐂰 Backups can be performed in a Microsoft Cluster Server (MSCS) environment
򐂰 Backups provide SQL Server database integrity check funcionality

Chapter 1. Introduction 23
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

VSS backup
A VSS backup uses Microsoft Volume Shadow Copy Service technology to
produce an online snapshot (point-in-time consistent copy) of SQL data that can
be stored on local shadow volumes or on Tivoli Storage Manager server storage.
A VSS backup means the SQL server is not in “backup mode” for an extended
period of time because the length of time to perform the snapshot is usually
measured in seconds and not hours. In addition, a VSS backup allows a
snapshot of large amounts of data at the same time since the snapshot works at
the volume level. VSS backups requires IBM Tivoli Storage Manager for Copy
Services to be installed, in addition to Data Protection for SQL and the IBM Tivoli
Storage Manager backup/archive client. You can optionally have an alternate
machine to move the data to the IBM Tivoli Storage Manager server, an
off-loaded backup.

Primary application server Disk system Offload


backup server
(optional)
MIcrosoft
MIcrosoft
SQL
SQL Server
Server Source
volumes VSS/VDS
VSS/VDS

Tivoli
Tivoli Storage
Storage
Manager
Manager BABA client
client
Data
Data Protection
Protection for
for (remote)
(remote)
SQL
SQL
Snapshot
Snapshot
(Target
(Target
volumes)
volumes)
Tivoli
Tivoli Storage Manager
Manager
for
for Copy Services
Services

Local
Tivoli
Tivoli Storage
Storage Manager
Manager
DSMAgent
BA
BA client
client (local)
(local)

Tivoli Storage
Manager Server

Figure 1-8 General VSS architecture

Optionally, VSS backups can be stored locally on VSS shadow volumes that are
directly accessible by the SQL system, as long as sufficient space is available for
the snapshot. Local VSS shadow backups are fast because data is not
transferred to Tivoli Storage Manager server storage. Restoring these backups is
also fast because the SQL data is not transferred from Tivoli Storage Manager
server storage over the network.

After the snapshot is complete, it can be accessed directly through standard


operating system functions or other applications. One application of this is to

24 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

back up and manage the VSS snapshot on an external storage manager (for
example, IBM Tivoli Storage Manager). When this function is selected, then after
the snapshot is made, IBM Tivoli Storage Manager is automatically invoked to
store the snapshot. In this way, we can establish two uses for VSS backup: as a
backup in itself, so that multiple shadow copy generations can potencially be kept
online for rapid restore (backup to local), and as means for extra backups to an
external media (backup to IBM Tivoli Storage Manager), so that the database
can be restored even if the disk system containing the original database and the
shadow copies fails. When a Data Protection for SQL backup is started, you must
specify the backup destination: to local, IBM Tivoli Storage Manager, or both.

Note: VSS Backups are only available on SQL Server 2005 on Windows
Server 2003.

The following characteristics are true of VSS backup:


򐂰 Full VSS snapshot backups and full VSS off-loaded snapshot backups are
supported. Incremental, differential, and transaction log backup types are not
supported. (see 1.6.2, “SQL Server backup types” on page 25 for definitions
of the types of backups)
򐂰 Backup granularity is at the database level only.
򐂰 Backups are managed through Tivoli Storage Manager policy.
򐂰 Backups can be stored on local shadow volumes, Tivoli Storage Manager
server storage or both locations.
򐂰 Different policy settings can be defined for each storage location and backup
method.
򐂰 Backups to Tivoli Storage Manager server storage can be off-loaded to an
alternate machine, to reduce the workload on the production servers.
򐂰 Backups can be performed in a Microsoft Cluster Server (MSCS) or VERITAS
Cluster Server (VCS) environment.

1.6.2 SQL Server backup types


SQL Server supports a lot of types of backup, some of them are supported by
Data Protection for SQL legacy backup method, others are supported by Data
Protection legacy and VSS backup method and others are not supported by Data
Protection for SQL.

SQL Server supports the following backup types:


򐂰 Full database backup

Chapter 1. Introduction 25
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

A full database backup backs up an entire SQL Server database and the
portion of the transaction log necessary to provide a consistent database
state. With both full and differential backups, the copy includes enough
information from any associated transaction logs to make a backup consistent
with itself. The portion of the log included contains only the transactions that
occured from the beginning of the backup until its completion. This backup
type are supported by legacy and VSS backup method.

Note: You do not have to do an actual full backup to constitute the equivalent
of a full backup. Backing up all the groups or files in a database as well as its
log is recognized as a full backup by the SQL Server. A base backup may be
full, group, file or set backup

򐂰 Differential backup
A differential backup backs up only the data pages in a SQL Server database
changed since the last full backup, as well as a portion of the transaction log.
This is equivalent to an incremental backup on the Tivoli Storage Manager
Backup-Archive Client. This backup type are supported by legacy VSS
backup method only.
򐂰 Log backup
A log backup backs up only the contents of an SQL Server database
transaction log since the last successful log backup. Before doing the first log
backup, you must have done a full backup or its equivalent first. Log backups
normally follow full backups. The portion of the log included in full and
differential backups is not equivalent to a log backup. Additionally, in full and
differential backups, the log is not truncated as it is during a log backup.
However, a log backup following a full or differential backup will include the
same transactions as a full or differential. Log backups are not cumulative -
they must be applied in turn against a base backup and in the correct order.
This backup type are supported by legacy VSS backup method only.

Note: A log backup in SQL Server terms is not equivalent to an incremental


backup in Tivoli Storage Manager terms.

򐂰 Tail-log backup
A tail-log backup is a transaction log backup that includes the portion of the
log that has not previously been backed up. The tail-log backup is commonly
used when the database is damaged, or becomes inaccessible, but the
transaction log file is undamaged. This backup type is supported by Data
Protection for SQL Server.
򐂰 File backup

26 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

A file backup backs up only the contents of a specified SQL Server logical file.
This can ease the scheduling for backing up very large databases by allowing
you to back up different sets of files during different scheduled backups. File,
group, and set backups must be followed by a log backup, but a full is not
required. This backup type are supported by legacy VSS backup method only.
򐂰 Group backup
A group backup backs up only the contents of a specified SQL Server file
group. This allows you to back up just the set of database tables and indexes
within a specific group of files. This backup type are supported by legacy VSS
backup method only.
򐂰 Set backup
A set backup backs up the contents of specified SQL Server file groups and
files as a unit. This backup type are supported by legacy VSS backup method
only.
򐂰 Copy-only backup
Sometimes it is necessary to back up a SQL Server database without
affecting the sequence of conventional SQL Server backups, for example, to
transfer a database from production to development environments. To
address this scenario, SQL 2005 introduces the copy-only backup. A
copy-only backup is a backup that does not affect the overall backup and
recovery routines for the database. There are two types of copy-only backups:
– Copy-only full backups - available in all recovery models
– Copy-only log backups - available in full recovery and bulk-logged models
A copy-only full backup cannot be used as a base or differential backup, and
does not affect differential backups. A copy-only log backup does not change
the transaction log sequence, consequently it does not affect the database
transaction log chain. A copy-only backup never truncates the transaction log.
This backup type is not supported by Data Protection for SQL Server. If you
plan to use this feature, you must use SQL Server tools to perform the
backup.
򐂰 Offline backup
In some situations you may want to perform an offline copy of your SQL
Server database files. To do this, you can stop the SQL Server instance, and,
using operating system tools or backup tools, such as the Tivoli Storage
Manager Backup-Archive Client for Windows, copy all the related files to the
SQL Server database, and then re-start the SQL Server instance.
This type of backup is beyond the scope of this book. For more information,
see the SQL Server documentation.

Chapter 1. Introduction 27
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

Note: A discussion about backup strategies is included in 2.3.4, “SQL Server


backup strategies” on page 43.

1.6.3 Data Protection for SQL Server restore methods


Data Protection for SQL Server provides several restore methods.

Legacy restore
A Data Protection for SQL Server legacy restore obtains backup copies of all or
part of one or more SQL databases and returns them to the SQL Server.

A complete restore of a database involves restoring a full backup or the


equivalent thereof (from group, file, or set backups) and restoring all transaction
logs since the last full backup.

VSS restore
A VSS restore restores VSS backups (SQL database files and log files) that
reside on Tivoli Storage Manager server storage to their original location.

The following characteristics are true for VSS restores:


򐂰 Only full backup types can be restored. Differential, individual file groups,
individual files, and set backups are not supported by VSS and therefore,
cannot be restored.
򐂰 Restore granularity is at the database level.
򐂰 One (or more) databases can be restored from a VSS snapshot backup
located on Tivoli Storage manager storage.
򐂰 VSS requires that data must always be restored to the same drive letters and
paths as existed during the original backup.
򐂰 Restores can be performed in a Microsoft Cluster Server (MSCS) or VERITAS
Cluster server (VCS) environment.

VSS fast restore


A VSS fast restore restores VSS backups that reside on local shadow volumes.

In general, restore processing can conclude within minutes instead of hours in


this situation. The following characteristics are true of VSS fast restores:
򐂰 Full backup types only can be restored. Diffrential, individual file groups,
individual files, and set backups are not supported by VSS and therefore,
cannot be restored.

28 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-1-intro.fm

򐂰 Restore granularity is at the database level.


򐂰 The key component of completing a VSS fast restore is the speed at which
the application can become operational with the data that resides on local
shadow volumes. Be aware that even though the data is restored relatively
quickly, the transaction logs must still be replayed after the restore and
therefore, the time of recovery for the application will increase.

VSS instant restore


A VSS instant restore copies a set of target volumes (that contain a valid
snapshot) back to the original source volumes using hardware-assisted
volume-level copy mechanisms. The application can return to normal operations
as soon as the hardware-assisted volume-level copy has been started and the
log replay is complete.

The key component of completing a VSS instant restore is the speed with which
the application can become operational with the data that resides on local
shadow volumes. Be aware that even though the data is restored relatively
quickly, the transaction logs must still be replayed after the restore and therefore,
the time of recovery for the application can increase.

A VSS instant restore requires that all of the source data resides on a supported
storage subsystem supported by the VSS instant restore. If part of the data being
restored (including the log files) resides on a local disk, a VSS instant restore of
this data is not possible. In this situation, a VSS fast restore is performed. At the
time of writing, IBM System Storage SAN Volume Controller, DS8000, and
DS6000 support VSS instant restore.

1.6.4 SQL Server restore types


Data Protection for SQL Server provides the same range of object types as for
backups:
򐂰 Full database restore
A full database restore restores full database backup objects for specified
SQL databases.
򐂰 Differential restore
A differential restore restores only differential database backup objects for
specified SQL databases. Restore time is reduced as only the latest
differential backup is restored, after it is associated full backup is restored.
򐂰 Log restore
A log restore restores only log backup objects for specified SQL databases.
򐂰 File restore

Chapter 1. Introduction 29
6148ch-1-intro.fm Draft Document for Review April 30, 2008 1:21 pm

A file restore restores just the file backup objects needed from a full backup,
file group backup, a file backup, or a set for specified SQL databases.
򐂰 Group restore
A group restore restore just the group backup objects needed from a full
backup, file group, a file backup, or a set backup for specified SQL databases.
򐂰 Set restore
A set restore Data Protection for SQL Server restores only set backup objects
for specified SQL databases.

Depending on the backup strategy you choose, restoring an SQL Server


database might involve restoring multiple backup objects from the Tivoli Storage
Manager server. In support of current SQL Server restore capabilities, Data
Protection for SQL Server also provides the ability to relocate files during restore
and to perform point-in-time restores, named-marks restores, or partial restores:
򐂰 Point-in-time
A point-in-time restore allows you to restore a transaction log backup to a
specific SQL transaction date and time.
򐂰 Named-marks
A named-marks restore is a feature of SQL Server 2000 and 2005, which
allows you to restore a transaction log backup up to or before a named point,
possibly after a specified point-in-time, and recover multiple related
databases to the same named mark.
򐂰 Partial
For SQL Server 2000 and 2005, a partial restore allows you to restore just
enough of a database into a temporary location to copy a specific table to the
active database.

Further Data Protection for SQL Server restore functions include the following:
򐂰 Restore a backup using the same number of data stripes used to create the
backup, or fewer stripes for SQL Server 2000 and 2005.
򐂰 Restore with no recovery until the last restore with recovery.
򐂰 Restore from any available backup version created by Data Protection for
SQL Server V5.5.0, V5.2.1, V5.1.5, or V2.2.
򐂰 Replace an existing database with the restored database (or replace by
relocating the restored database).
򐂰 Restore to a different SQL Server or to a standby SQL Server.
򐂰 Automatically restore all backup objects needed to make a restore complete
by using smart selection in the GUI.

30 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Chapter 2. Planning considerations


This chapter provides the planning considerations for a successfull
implementation of Tivoli Storage Manager for Microsoft SQL Server Databases.

This chapter discusses the following topics:


򐂰 2.1, “Data Protection for SQL Server requirements” on page 32
򐂰 2.2, “Tivoli Storage Manager backup options” on page 36
򐂰 2.3, “Microsoft SQL Server backup planning” on page 40
򐂰 2.4, “Additional SQL Server backup considerations” on page 50
򐂰 2.5, “IBM Tivoli Storage Manager and Data Protection for SQL backup
strategies considerations” on page 57

© Copyright IBM Corp. 2008. All rights reserved. 31


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

2.1 Data Protection for SQL Server requirements


This section provides information on Data Protection for SQL Server
requirements and discusses some of the choices you will need to make during
installation. Data Protection for SQL Server is available in the following
packages:
򐂰 Paid in Full
This package contains a license component and is a complete stand-alone
release of the product.
򐂰 Program Temporary Fix (PTF)
This package does not contain a license component. It is created to install
over a previously installed version of Data Protection for SQL.

2.1.1 Software and operating system requirements


Data Protection for SQL requires the following levels of Tivoli Storage Manager
software:
򐂰 Tivoli Storage Manager backup-archive client Version 5.5.0 (or later).
򐂰 Tivoli Storage Manager API Version 5.5.0 (or later).
򐂰 Tivoli Storage Manager server Version 5.4.0 (or later)

Legacy backup and restore requirements


Table 2-1 shows the requirements for legacy backup and restore operations.

Table 2-1 Minimum requirements for Legacy backup and restore


Operating system SQL Server VSS Provider TSM for Copy Services
a
Windows 2003 x86 SQL Server 2000 None None
Windows 2003 x64b or 2005c
Windows 2003 ia64
a. Windows Server 2003 x86: Standard, Enterprise, or DataCenter Edition. All versions must be at
Service Pack 1 (or later). Windows Server 2003 R2: Standard, Enterprise, or DataCenter Edition
b. Windows Server 2003 x64 Standard, Enterprise, or DataCenter x64 Edition. Windows Server 2003
x64 R2: Standard, Enterprise, or DataCenter x64 Edition
c. SQL Server 2005 Standard or Enterprise Edition

Basic VSS software and operating system requirements


Table 2-2 shows the requirements for basic VSS operations.

32 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Table 2-2 Minimum requirements for basic VSS operations


Operating system SQL Server VSS Provider TSM for Copy Services

Windows 2003 x86a Any VSS provider that is Microsoft SQL VSS
Windows 2003 x64b SQL Server 2005c supported by Microsoft Integration Module
rules for VSS providers Version 5.5.0
a. Windows Server 2003 x86: Standard, Enterprise, or DataCenter Edition. All versions must be at
Service Pack 1 (or later). Windows Server 2003 R2: Standard, Enterprise, or DataCenter Edition
b. The Microsoft SQL VSS Integration Module is dependent upon the base Data Protection for SQL
product and must be installed to perform any VSS operations
c. SQL Server 2005 Standard or Enterprise Edition

VSS off-loaded backup requirements


Table 2-3 shows the requirements for VSS Off-loaded backups.

Table 2-3 Minimum software and operating system requirements for VSS Off-loaded Backup
Operating system SQL Server VSS Provider TSM for Copy Services

Windows 2003 x86a SQL Server 2005c Any VSS provider that Microsoft SQL VSS
Windows 2003 x64b supports transportable Integration Module Version
shadow copies d 5.5.0 e
a. Windows Server 2003 x86: Standard, Enterprise, or DataCenter Edition. All versions must be at
Service Pack 1 (or later). Windows Server 2003 R2: Standard, Enterprise, or DataCenter Edition
b. Windows Server 2003 x64 Standard, Enterprise, or DataCenter x64 Edition. Windows Server 2003
x64 R2: Standard, Enterprise, or DataCenter x64 Edition.
c. SQL Server 2005 Standard or Enterprise Edition
d. The VSS hardware provider must be installed on both machines that are involved in an Off-loaded
backup
e. The Microsoft SQL VSS Integration Module is dependent upon the base Data Protection for SQL
product and must be installed to perform any VSS operations.

VSS Instant Restore software and operating system requirements


Table 2-4 shows the requirements for VSS instant restore operations.

Chapter 2. Planning considerations 33


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

Table 2-4 Minimum software and operating system requirements for VSS Instant Restore operations
Operating system SQL Server VSS Provider TSM for Copy Services

Windows 2003 x86a SQL Server On DS storage On DS storage subsystems:


2005c subsystems: 򐂰 Microsoft SQL VSS
򐂰 IBM TotalStorage VSS Integration Module
Hardware Provider Version 5.5.0 (or later) e
2.4.2 (or later) 򐂰 Hardware Devices
Snapshot Integration
On SAN Volume Controller Module Version 5.5.0 (or
storage subsystems: later)
Windows 2003 x64b 򐂰 IBM TotalStorage SAN
Volume Controller On SAN Volume Controller
Version 2.1.x (or later) storage subsystems:
or Version 3.1.x d 򐂰 Microsoft SQL VSS
򐂰 IBM TotalStorage VSS Integration Module
Hardware Provider Version 5.5.0 (or later) f
2.4.3 (or later) 򐂰 Hardware Devices
Snapshot Integration
Module Version 5.5.0 (or
later) g
a. Windows Server 2003 x86: Standard, Enterprise, or DataCenter Edition. All versions must be at
Service Pack 1 (or later). Windows Server 2003 R2: Standard, Enterprise, or DataCenter Edition
b. Windows Server 2003 x64 Standard, Enterprise, or DataCenter x64 Edition. Windows Server 2003
x64 R2: Standard, Enterprise, or DataCenter x64 Edition.
c. SQL Server 2005 Standard or Enterprise Edition
d. IBM Subsystem Device Driver (SDD) 1.6.0.2 with Host Attachment Scripts 1.1.0.3. or (later) is
required.
e. The Microsoft SQL VSS Integration Module is dependent upon the base Data Protection for SQL
product and must be installed to perform any VSS operations.
f. The VSS hardware provider must be installed on both machines that are involved in an Off-loaded
backup.
g. The Hardware Devices Snapshot Integration Module is dependent upon the base Tivoli Storage
Manager backup-archive client product and must be installed to perform VSS Instant Restore
operations.

2.1.2 Hardware requirements


This section explains the hardware requirements for Data Protection for SQL
Server.

34 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Note: Data Protection for SQL VSS operations are available on any hardware
that supports Microsoft VSS requirements. Refer to your VSS provider
documentation for required levels. The following list identifies some hardware
storage subsystems that were tested with Data Protection for SQL VSS
operations:
򐂰 IBM TotalStorage DS6000 and a machine with a processor supported by
DS6000 with IBM Common Interface Model (CIM) Agent for DS Open API.
򐂰 IBM TotalStorage DS8000 and a machine with a processor supported by
DS8000 with IBM Common Interface Model (CIM) Agent for DS Open API.
򐂰 IBM TotalStorage N3700 with Network Appliance™ (NetApp) SnapDrive
Version 3.2 (or later).
򐂰 NetApp fabric-attached storage (NAS) system with NetApp SnapDrive
Version 3.2 (or later).
򐂰 IBM TotalStorage SAN Volume Controller Version 2.1.x (or later) or Version
3.1.x.

Contact your hardware storage subsystem vendor for exact details of their
support of VSS operations.

Legacy or VSS Backup and Restore hardware requirements


Table 2-5 shows the hardware requirements for Legacy or VSS backup and
restore operations.

Table 2-5 Hardware requirements for Legacy or VSS Backup and Restore operations
Architecture Hardware description Disk Space RAM

32-bit Intel® Pentium® 166 equivalent 20 MB 48 MB (96 MB or greater


(or later) processor recommended)

x64 One of the following:


򐂰 Processor that supports
Intel Extended Memory 64
Technology (Intel EM64T)
򐂰 AMD™ 64-bit processor
that supports AMD64
platform

VSS off-loaded backup hardware requirements


Table 2-6 shows the hardware requirements for VSS off-loaded backup
operations.

Chapter 2. Planning considerations 35


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

Table 2-6 Minimum hardware requirements for VSS off-loaded backup operations
Architecture Hardware description Disk Space RAM

32-bit or x64 A storage subsystem awith a See provider See provider


VSS hardware provider documentation documentation
a. You must have a hardware storage subsystem that supports transportable shadow copies and
delivers a VSS hardware provider for the hardware storage subsystem that adheres to Microsoft
VSS Provider API standards.

VSS Instant Restore hardware requirements


Table 2-7 shows the requirements for VSS Instant Restore operations.

Table 2-7 Minimum hardware requirements for VSS Instant Restore operations
Architecture Hardware description Disk Space RAM

32-bit or x64 One of the following: See disk storage See disk storage
򐂰 IBM TotalStorage DS6000 disk subsystem subsystem
storage subsystem3 a documentation documentation
򐂰 IBM TotalStorage DS8000 disk
storage subsystem3 a
򐂰 IBM TotalStorage SAN Volume
Controller Version 2.1.x (or later)
򐂰 IBM TotalStorage SAN Volume
Controller Version 3.1.x
a. IBM TotalStorage DS6000 and DS8000 disk storage subsystems require IBM TotalStorage VSS
Hardware Provider Version 2.4.2 (or later).

For detailed information regarding current hardware product compatibility


requirements, see the IBM TotalStorage Web site:

http://www-03.ibm.com/servers/storage

2.2 Tivoli Storage Manager backup options


When creating policy for your backups, consider these differences between
backing up data to Tivoli Storage Manager storage against VSS disks.

Tivoli Storage Manager storage


Backups to Tivoli Storage Manager server storage are usually dictated by time,
not versions.

A Tivoli Storage Manager backup operation stores the backed up data on Tivoli
Storage Manager server storage. Although this type of backup typically takes

36 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

longer to process than a backup to local shadow volumes, a Tivoli Storage


Manager backup is necessary when long term storage is needed such as saving
SQL data on tape for archival purposes. Tivoli Storage Manager backups are
also necessary for disaster recovery situations when the disks that are used for
local backups are unavailable. By maintaining multiple backup copies on Tivoli
Storage Manager server storage, a point in time copy is available should backups
on the local shadow volumes become corrupt or deleted.

Local shadow volumes


Backups to local shadow volumes are usually dictated by versions because of
space limitations and provisioning of VSS storage.

Sufficient local storage space must be available on local shadow volumes for a
VSS backup strategy to be successful. Make sure there is enough available
storage space assigned to the volumes to accommodate your Data Protection for
SQL backup operations. Environment and storage resources also impact how
many backup versions are maintained on local shadow volumes (for VSS Fast
Restore and VSS Instant Restore) and how many backup versions are
maintained on Tivoli Storage Manager server (VSS Restore and longer term
storage). It is recommended that different sets of policies be created for backups
to both local shadow volumes and to Tivoli Storage Manager server storage. If
you are using a VSS provider other than the Windows VSS System Provider,
make sure to review the documentation for that specific VSS provider.

VSS in DS and SAN volume controller environments


In order to determine how much storage space is required for each local backup,
be aware that the backup LUNs require the same amount of storage space as
the original LUNs. For example, if you have a 100GB database residing on a
200GB LUN, you will need a 200GB LUN for each backup version.

When performing a Data Protection for SQL VSS backup (non-offloaded) with
backup destination as Tivoli Storage Manager Server, and the SQL Server data
resides on SAN Volume Controller (SVC) disks, and the IBM System Storage
VSS Hardware Provider is being used, in some isolated cases the SVC LUNs
remain mapped to the Windows host even though the VSS backup is complete.
To work around this issue, you can use a backup destination other than TSM
(BOTH or LOCAL). You can also manually unmap the volumes attached to the
Windows host to work around this issue.

When performing two Data Protection for SQL VSS backups, back to back, and
the SQL Server data resides on SAN Volume Controller (SVC) disks, if the
volumes are large and/or the SVC background copy rate is set a low number, it
may appear that the second VSS backup is hanging. In fact, it is waiting for the
SVC background copy of the first backup to complete before proceeding with the

Chapter 2. Planning considerations 37


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

second backup. SVC will not allow two background copies of the same volume to
occur at the same time. There is no indication that the second backup is waiting
for the first SVC background copy to complete. You may also see timeouts errors
if the previous SVC background copy takes too long. To work around this issue,
schedule your VSS backups far enough apart to accommodate this situation. You
can also try increasing the copyrate of the SVC background copy.

VSS operations in IBM N-series and NetApp environments


Be aware that in environments that contain IBM N-series and NetApp systems,
snapshots created using the IBM N-series and NetApp snapshot provider are
stored on the same volume where the LUN resides. Disk space consumed by a
local backup consists only of the blocks that have changed since the last local
backup was created. The following formula can be used to help determine how
much space is required for each local backup: Amount of data changed per hour
* number of hours before a local backup expires In addition, Write Anywhere File
Layout (WAFL®) reserves blocks equal to two times the specified size of the LUN
to be used. This space reservation ensures writes for virtual disks. Example 2-1
demonstrates how to calculate the size of these volumes:

Example 2-1 IBM N-series and Netapp volume size calculation


SQL Database size: 100GB
Number of local backups to be kept: 3
Snapshot for TSM backup: 1
duration for TSM backup: 2hr
Backup frequency: 3hrs
The duration before a local backup is expired: 9 hrs
Amount of data changed/added/deleted per hr: 50MB
Space required for each local backup: 50*9= 450 MB
Space required for 3 local backups + 1 TSM backup: 450*3 + 50*2 = 1450
MB

The volume size required for the database:


100*2 (space reservation) + 1.5 = 201.5 GB

VSS limitations for NetApp NAS series or IBM N-series


Due to the limitations in SnapDrive 4.0 and any supported prior versions, the
VSS Provider for NetApp FAS series and IBM N-series, VSS based operations
using Data Protection for SQLData Protection for SQL with backup destination
set to LOCAL, must be performed in specific ways. Failure to comply with the
following configuration and operational recommendations can lead to serious
conditions such as premature deletion of snapshots representing VSS backups
to LOCAL, backup failure, and out of space conditions on the production

38 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

volumes. When the limitations in the SnapDrive are addressed by NetApp, Data
Protection for SQL VSS operations can be fully utilized.

SQL Server
N-series VSSstorage configuration for NetApp NAS series or IBM
operations
If you plan to perform VSS backups with backup destination set to LOCAL,
please check your setup to ensure that following requirements are met.
򐂰 The NAS filers LUNs used by a database must be fully dedicated to the
database. The Microsoft SQL Server databases can not share LUNs.
򐂰 A NAS filer LUN used by the SQL databases must be the only LUN on the
filer volume. For example, if SQL uses four LUNs, there must be four
corresponding filer volumes, each volume containing one LUN.

Guidelines
N-series for VSS Backup operations for NetApp NAS series or IBM
If you plan to perform VSS backups with backup destination set to LOCAL, these
backups must adhere to the following guidelines.
򐂰 VSS backups with backup destination set to Local must be bound to a
management class that has verExists=1.
򐂰 VSS backups with backup destination set to Local can either be of type full or
copy. You can not mix local backups of type full and copy.
򐂰 VSS backups with backup destination set to TSM can be full or copy. There
are no restrictions on Tivoli Storage Manager backups.
򐂰 When performing VSS backups, you must ensure that previous backup has
finished completely before starting a new backup. Any overlap of backups can
result in undesirable side-effects on the Microsoft SQL Server, the VSS
service, and, the NAS filer.

Sample
N-seriesVSS Backup procedure for NetApp FAS series or IBM
Taking above considerations into account, the following section describes a
sample backup procedure that could be used to perform VSS backups utilizing
both Tivoli Storage Manager and LOCAL backup destinations in an optimal
manner. Note that the following assumptions apply to this sample backup
procedure:
򐂰 The configuration requirements stated above are met.
򐂰 The VSS backup to Tivoli Storage Manager takes one hour to complete.
򐂰 The VSS backup to LOCAL takes five minutes to complete.

Your backup procedure could consist of the following backups:


򐂰 Daily VSS full backups to LOCAL every four hours - 12am, 4am, 8am, 12pm,
4pm, 8pm

Chapter 2. Planning considerations 39


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Daily VSS full backups to Tivoli Storage Manager storage by one of the
following two methods:
– Specify backupdestination set to BOTH at 12am. Note that this will create
a 12am backup to local. Therefore, no separate 12am backup to local is
required.
– Full offloaded-backup at 1am. Note that no VSS local backup will be
available to restore from between 1am and 4am when next VSS backup to
local will take place.
򐂰 Perform weekly VSS-copy backups to Tivoli Storage Manager (offloaded
backup) 5am
򐂰 Perform weekly legacy full backups (or as needed).

2.3 Microsoft SQL Server backup planning


Implementing a well-planned backup and recovery strategy provides an essential
safeguard for protecting SQL Server databases, and helps to protect database
against failures caused by a variety of failures, such as media failures, hardware
failures, human errors and natural disasters. Several factors must be considered
in order to develop the strategy to fulfill business requirements for data
protection, such as the resources required, work-loss exposure supported for the
environment and the benefits and tradeoffs for each scenario.

In this section we discuss technical aspects and considerations for SQL Server
backup. For a Tivoli Storage Manager administrator working with SQL Server
databases, it is crucial to understand what backup options SQL Server offers, the
requirements for each one, and how to implement these to satisfy the business
requirements for each environment.

Note: Remember that the prime focus of a backup strategy is to be able to


restore data in case of an SQL Server failure.

2.3.1 Identify recovery requirements


The most important factor in a backup and recovery strategy is to meet the
recovery business requirements. A database can be used for a variety of roles in
an organization, from a development database with a few megabytes of
information being accessed by a few developers to a non-stop production
database with several terabytes of information being accessed by thousands of
users around the world. Likewise, the recovery requirements for these particular
databases will differ significantly: for the first database, maybe a weekly

40 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

database backup will suffice, and, for the second database, a comprehensive
strategy should be designed to achieve the recovery requirements.

To identify the recovery requirements, you need to determine:


򐂰 How critical are your databases to your business ?
򐂰 Is it acceptable to lose any database activity? How much time and changes
are acceptable to lose?
򐂰 What is the maximum acceptable downtime for your database?
򐂰 Is it necessary to perform a restore right up to a point-of-failure?
򐂰 What is the backup window? How much resources are available for the
backup?
򐂰 Does your database need to be available only during commercial hours or
working days, or does it need to operate on a 24x7x365 basis ?
򐂰 Are there peak periods of database utilization? How frequently does the data
in the database change during peak and non peak periods ?
򐂰 Do you have two or more databases that must maintain a logical consistency?
򐂰 What are the legal requirements for your backup routines? Do you need to
retain backups for a long period of time, such as 5 or 10 years ?
򐂰 Are your staff trained in backup and recovery tasks?
򐂰 How often will recovery routines be tested?

The answers to these questions will help to determine the backup strategy.
Non-critical databases may have simple backups that can restore the database
to the night before, or might not even be backed up, if they can be easily
recreated from other sources. Critical databases will have more complex
backups in order to facilitate restore to a desired point in time, and minimize the
restore period.

In the next sections we discuss backup strategies and the options provided by
SQL Server and Data Protection for SQL Server to backup a database.

2.3.2 Backup strategy and database recovery model


According to the answers to the questions in 2.3.1, “Identify recovery
requirements” on page 40, you must define what database recovery model will
be used for your databases.

Chapter 2. Planning considerations 41


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

Note: A further discussion about SQL Server database recovery models can
be found in Appendix B, “Microsoft SQL Server overview for Tivoli Storage
Manager administrators” on page 251.

Simple recovery model


Use the simple recovery model when:
򐂰 You do not need to recover a database to a specific point-in-time.
򐂰 You do not want, or you do not have resources available to backup the
transaction log.

If the database is lost or damaged, you will either restore the database from a
previous backup and lose all updates since the backup, or recreate the database
from a different source.

Note: By default, the system databases master, msdb and tempdb use simple
recovery model. You cannot change the recovery model for the tempdb
database. For the master database, for backward compatibility with earlier
versions of SQL Server, you can change the recovery model to full or
bulk-logged; however, you cannot backup the transaction log for the master
database, so this change will have no pratical results.

Full recovery model


Use the full recovery model when:
򐂰 Your database has critical information, and you must be able to recover all the
data.
򐂰 You must be able to restore a database to a specific point-in-time in the past.
򐂰 You want to be able to restore individual pages.
򐂰 You have enough resources to support the administrative costs of transaction
log backups.

If your database is lost or damaged, you will restore the database from a
previous backup and then apply all transaction log backups generated since then
up to the point of failure.

Bulk-logged recovery model


Use the bulk-logged recovery model when:
򐂰 Your database runs in full recovery model and a large-scale bulk operation is
performed. During the bulk operation a point-in-time recovery is not needed.

42 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

It is recommended to use the bulk-logged recovery model in association with the


full recovery model. As soon as the bulk operation finishes, is it recommended to
switch back to full recovery model. It is recommended also to backup the
transaction log before and after switching between full recovery model and
bulk-logged recovery model.

2.3.3 SQL Server log chains


A log chain is a continuous sequence of SQL Server transaction log backups. A
log chain starts with a full backup of the database. To perform a database
point-in-time recovery, or to perform a full database recovery using the
transaction logs, it is mandatory that all transaction log backups be available from
the beginning of the log chain - the backup full operation - up to the time the
database will be recovered.

For databases using full recovery model or bulk-logged recovery model, you can
start backing up the database transaction log immediately after the first full
database backup. Then, regularly perform transaction log backups to not only
enable truncation of the transaction log files but also to minimize work-loss
exposure. The more frequently you back up the transaction log files, the smaller
will be your exposure to work-loss failures and your transaction log files.

Note: Certain commands in SQL Server, such as the BACKUP LOG with the
TRUNCATE_ONLY option, truncate the log and break the log chain sequence,
causing the database to stay vulnerable to media failure until the next
execution of a full or differential database backup. It is strongly recommended
to only use these commands if you fully understand the resulting impacts.

2.3.4 SQL Server backup strategies


A backup strategy is one of the most import parts of your planning
considerations, because every environment is unique.

The more simple backup strategy you use, the more simple is your restore
process. At the same time, the more simple backup strategy results in more
limitations, considering both storage utilization and the restore operation.

The more complex backup strategy you use, the more work must be done when
setting up the scheduled backups. At the same time, the more complex backup
strategy gives you more options, considering both storage utilization and the
restore operation.

Chapter 2. Planning considerations 43


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

You must balance business recovery requirements and available resources to


define the right backup strategy for you. We recommend you to clearly identify
and document business recovery requirements, the strategy being used to
backup the environment, the recovery routines to restore and recover the
environment, and also resources involved in the backup and restore procedures.

Different backup strategies are available depending on specific requirements for


network traffic, backup window and acceptable restore times.

Some commonly used strategies are discussed in next sections, as well the
restore steps for each of them. Pratical examples of backup and restore routines
can be found in Chapter 4, “Data Protection for SQL Server backup” on page 121
and Chapter 5, “Data Protection for SQL Server restore” on page 171
respectively.

Full backup only (legacy or VSS backup)


This approach is best for SQL databases that are relatively small because it
implies that the entire database is backed up each time. Each full backup takes
the same amount of time to perfom and is directly affected by the resources
available in the environment. If you have a large database you can use VSS
snapshot to improve backup and restore times.

The restore process is most efficient because only the most recent full backup
needs to be restored.

Figure 2-1 illustrates the full backup only strategy.

Monday Tuesday Wednesday

• Perform full backups daily to Tivoli Storage Manager if:


Database is small
Database has few changes or is read-only

• Perform full backups using VSS snapshot if:


Database is larger

Figure 2-1 Full backup only strategy

44 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Steps to back up database:


򐂰 Periodically perform full database backups - daily, for example

Steps to restore database:


򐂰 The database is restored in one step from the full backup.

Full plus log backup (legacy backup only)


A full plus transaction log backup strategy is commonly used when the backup
window or network capacity cannot support a full backup each time. In such
cases, a periodic full backup followed by a series of log backups minimizes the
backup window and network traffic.

The restore operation involves restore the most recent full backup and the
transaction logs since them.

Figure 2-2 illustrates a full plus log backup strategy.

Sunday Monday

• Perform log backups if:


Database is often modified
You need to restore in a specific point-in-time

Figure 2-2 Full plus log backup strategy

Steps to back up database:


򐂰 Periodically perform full database backups - daily, for example
򐂰 Periodically perform transaction log backups - for example, every 1 hour.

Steps to restore database:


򐂰 Restore last full backup.
򐂰 Restore all transaction logs since the last full backup until the end of the logs,
or until desired point in time.

Chapter 2. Planning considerations 45


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

Note: You can do a point-in-time restore to a specific date and time using
transaction log backups.

Full plus differential backup (legacy backup only)


Perform this type of backup between full backups. A differential database backup
can save both time and space, because it consists of only the changed portions
of a database since the last full backup, minimizing resources necessary to back
up the database. This strategy also benefits the restore time, because instead of
apply several transaction log backups you just apply the differential backup.

The restore operation involves restore the most recent full backup and the last
differential backup after the full backup.

Figure 2-3 on page 46 illustrates a full plus differential backup strategy.

Sunday Monday Tuesday

• Perform differential backups to Tivoli Storage Manager if:


Database changes frequently
You want to reduce backup time

Figure 2-3 Full plus differential backup strategy

Steps to back up database:


򐂰 Periodically perform full database backups - weekly, for example.
򐂰 Periodically perform differential backups - for example, daily, or each 12
hours.

Steps to restore database:


򐂰 Restore last full backup.

46 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

򐂰 Restore last differential backup.

Full plus differential plus log backup (legacy backup only)


This strategy speeds the restore because it reduces the number of transaction
logs that may need to be restored and applied. If, for example, a full backup is
done weekly, a differential nightly, and a log backup every four hours, the restore
would involve the full backup, a differential, and at most five log backups.

The difference between this strategy and the full plus differential backup is the
transaction log files backup. For a database using simple recovery model the
previous strategy is suitable, however, for production databases using full or
bulk-logged recovery models this strategy is the recommended option.

Figure 2-4 on page 47 illustrates a full plus differential plus log backup strategy.

Monday Tuesday

• Perform differential backups to Tivoli Storage Manager if:


Database changes frequently
You want to reduce backup time

• Perform back up logs separetely


You can restore transaction logs in a specific point-in-time

Figure 2-4 Full plus differential plus log backup strategy

Steps to back up database:


򐂰 Periodically perform full database backups - weekly, for example
򐂰 Periodically perform transaction log backups - for example, every 15 minutes
or 1 hour.
򐂰 Periodically perform differential backups - for example, daily, or each 12
hours.

Steps to restore database:

Chapter 2. Planning considerations 47


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Restore the last full backup


򐂰 Restore the last differential backup (before desired restore point in time)
򐂰 Restore the following transaction logs until the desired point in time.

File or group backups (legacy backup only)


Use a file backup strategy when it is impractical to backup an entire database
due to its size and accompanying time and performance issues. When
performing restores for a file or file group, it is necessary to provide a separate
backup of the transaction log.

Figure 2-5 on page 48 illustrates a file backup strategy.

File 1 File 2

Sunday Monday Tuesday

• Perform file or filegroups to Tivoli Storage Manager if:


Database is very large
A full backup would take too long

• Backup transaction log separetely

• Complex to manage

Figure 2-5 File backup strategy

Steps to back up database:


򐂰 We recommend to perform an initial full backup of the database.
򐂰 Periodically perform transaction log backups - for example, every 15 minutes
or 1 hour.
򐂰 Periodically perform file or group backups.

Steps to restore database:


򐂰 Restore the last file or group backup (before desired restore point in time)
򐂰 Restore the following transaction logs until the desired point in time.

48 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Use VSS and legacy backups together


Using VSS and legacy backups together can implement a highly-effective backup
solution for Data Protection for SQL data.

Microsoft supports and recommends using both methods of backup in your


complete backup strategy. However, Microsoft also states that you cannot mix the
two types of backups. For example, a legacy differential backup cannot be
applied to a VSS full backup.

Table 2-8 gives more details of this strategy.

Table 2-8 Backup strategy characteristics using VSS and legacy backups together
Strategy characteristics Legacy backup only Legacy backup plus VSS
backup

Available backup types Full (1 per week) Legacy Full (1 per week)
Incr (4 per day) VSS Full (1 per day)

Note: Backups to local shadow volumes are usually dictated by versions


because of space limitations and provisioning of VSS storage.

Database recovery models and backup strategies relationship


Table 2-9 shows what backup strategies are supported for each database
recovery model.

Table 2-9 Supported backup strategies for each database recovery model
Backup Strategy Simple recovery Bulk-logged Full recovery
model recovery model model

Full Legacy backup Yes Yes Yes

Full VSS backup Yes Yes Yes

Full plus log backup No Yes Yes

Full plus differential Yes Yes Yes


backup

Full plus differential No Yes Yes


plus log backup

File or group backup Partially - only for Yes Yes


read-only
filegroups

Chapter 2. Planning considerations 49


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

Note: When you implement a full backup only or a full plus differential backup
strategies and the database is using either full or bulk-logged database
recovery models, the transaction log may grown indefinitely, eventually filling
up all available disk space and hanging SQL Server.

If you plan to use these backup strategies without using transaction log
backups, we recommend you to configure the database recovery model to
simple.

2.4 Additional SQL Server backup considerations


Besides the backup strategies just mentioned, there are some SQL Server
additional characteristics and configurations to address for a successful backup
strategy implementation.

2.4.1 System databases


Always back up the system databases (master and msdb) on a regular basis and
at times when alterations concerning system level information for SQL Server are
performed. Also back up the model database if it is modified.

We recommend that you do backups of the system databases daily, since they
are unlikely to become large enough to consume a significant ammount of
resources during the backup operation. The same recommendation applies to
the distribution database in replicate SQL Server environments.

You cannot back up the tempdb database. It is re-created each time the SQL
Server is started.

Note: A SQL Server overview for TSM administrators is discussed in


Appendix B, “Microsoft SQL Server overview for Tivoli Storage Manager
administrators” on page 251.

2.4.2 Backup checksums and database integrity checks


Regardless of the frequency of database backups, it is highly recommended that
you always run dbcc checkdb and dbcc checkcatalog on a database just before
backing it up to check the logical and physical consistency of the database. See
your SQL Server documentation for more information on using the SQL Server
database consistency checker.

50 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

2.4.3 SQL Server mirrored backup media sets


SQL Server 2005 introduces mirrored backup media sets. With this new
funcionality, you can perform up to four copies (mirrors) of the backup data. You
need to use similar devices with the same properties for a successful mirrored
backup, in other words, it is not possible to mirror a backup between tape and
disk devices.

We recommend you to use the option to backup storage pool in IBM Tivoli
Storage Manager. The storage pool can be a group of disk volumes, tape
volumes, or optical volumes. You have two types of storage pool in IBM Tivoli
Storage Manager server, primary storage pool and copy storage pool. The
primary storage pool is used to storage backed information of your SQL Server
environment, and copy storage pool is a copy of your primary storage pool to
improve data availability. You can simultaneously write data to a primary storage
pool and one or more copy storage pools. You can use this feature in IBM Tivoli
Storage Manager, instead of SQL Server mirrored backup media sets.

For more information about Tivoli Storage Manager copy storage pools, refer to
the appropriate Tivoli Storage Manager Administrator Guide for the platform that
you are using.

2.4.4 Backup a transaction log without truncate the log


When you choose to perform a transaction log backup using Data Protection for
SQL, you can indicate that you do not want to truncate the log. In general, you do
not want to truncate the log when rebuilding a corrupt database. This option
enables the server to back up the transaction log but does not try to touch the
data in any way. It writes all transaction log entries from the time of the last log
backup to the point of database corruption.

An example of transaction log backup without log truncation is shown in 4.2.7,


“Tail-log backups” on page 143.

2.4.5 SQL Server replication


Special attention for backup and restore planning is needed in a SQL Server
replicated environments. In a replicated environment you must back up:
򐂰 The publication database at the Publisher
򐂰 The distribution database at the Distributor
򐂰 The subscription database at each Subscriber

Chapter 2. Planning considerations 51


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 The master and msdb system databases in all SQL Server instances. To
reduce replication inconsistency risks, it is recommended to back up these
databases at same time as the relevant replication database in the
appropriate node - the publication, the distribution or the subscription.

If regular transaction log backups are made, replication-related changes should


be captured in the log backups. If not, it is recommended to backup the logs after
a relevant change.

SQL Server provides three replication topologies:


򐂰 snapshot replication, where all publisher data is always transfered to the
subscribers, without allowing partial updates or syncronization.
򐂰 transactional replication, where after an initial snapshot, subsequent changes
in the publisher data are applied to the subscribers.
򐂰 merge replication, that is similar to transaction replication except that with
transactional replication, the subscriber cannot change the data; whereas
merge replication allows the data to be changed by both the publisher and the
subscribers, and then the changes are propagated to other replication
members.

For each type, the backup and restore strategies differ. Data Protection for SQL
Server can be used to protect a replicated SQL Server environment.

A full discussion about the requirements for each replication strategy type is
beyound the scope of this book. For further documentation, refer to the SQL
Server documentation, or se:

http://technet.microsoft.com/en-us/library/ms151152.aspx

2.4.6 SQL Server log shipping


SQL Server log shipping feature is used to transfer transaction log backups from
a primary database on a primary SQL Server instance to one or more secondary
databases on separate SQL Server instances. It can also uses a optional monitor
server to monitor log shipping operations, and raise alerts when a failure occur.

This technique is called warm backup, or stand by database, because the backup
database receives continuously application of the transaction logs, reducing the
database downtime in case of problems.

When SQL Server log shipping is in place, the backup jobs are done by SQL
Server backup jobs. It also requires that transaction log files backups are
performed only to disk devices, not allowing tape devices utilization.

52 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

If you need the log shipping (or stand by databases) capabilities in your
environment, we recommend you to use Tivoli Storage Manager tools instead of
log shipping. You can achieve log shipping functionality simply utilizing Tivoli
Storage Manager Scheduler to periodically restores transaction log backups on
the secondary databases.

Note: An example of stand by implementation can be found on 5.5, “Standby


server” on page 197.

If you prefer to use log shipping tools, you can use Tivoli Storage Manager tools
to protect the database in the following way:
򐂰 Disable automatic transaction log backup files exclusion log shipping task.
򐂰 Use Tivoli Storage Manager backup-archive tools to back up the transaction
log backup files on the primary database. You can exclude the transaction log
backup files from disk after ensure they are already applied to all secondary
databases, and also backed up by Tivoli Storage Manager.
򐂰 Perform full or diferential database backups using Data Protection for SQL
Server or SQL Server tools. If you use SQL Server tools, also back up the
generated files using Tivoli Storage Manager backup-archive tools.
These backups can be generated from the primary or secondary databases,
but keep in mind that if the backups are generated from the secondary
database you can not include all recent changes in the primary database due
to out-of-sync delays between primary and secondary databases.
򐂰 Never use Data Protection transaction log backups against a database
involved in the log shipping.

In a restore operation, you will need to restore the last full or diferential backup,
and then manually apply the transaction log files backed up by Tivoli Storage
Manager backup-archive tool.

2.4.7 SQL Server database mirroring


SQL Server database mirroring feature maintains two copies of a single
database on different SQL Server instances. One instance acts as the principal
server, answering to client requests, while the other instance acts as the mirror
server, also known as hot or warm stand by server. Differently from log shipping,
where the transaction log backup files are moved to a stand by location, SQL
Server mirroring works directly repplying operations on the principal server onto
the mirror server, using transaction log records. Database mirroring can operate
in either synchronous or asynchronous modes. The main difference between
them is that in synchronous mode the transactions must be commited on both

Chapter 2. Planning considerations 53


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

nodes at same time before it returns to the client, while in asynchronous mode
the mirror server can do a delayed commit.

The mirror database is created by restoring backups from the principal database
on the mirror server. However, after a database mirroring section is active, you
have the following restrictions:
򐂰 Backup and restore operations on the mirror database are not allowed
򐂰 Restore of the principal database is not allowed while mirroring is active.
򐂰 Backup of the principal database is allowed since you do not use
NORECOVERY option on the transaction log backups.

You can use Data Protection for SQL Server to create the mirror database, and
also to back up the principal database as any other user database.

2.4.8 SQL Server database snapshot


SQL Server database snapshot provides a read only, static view of a database at
a specific point in time, that can be used for reporting purposes. As the source
database is updated, the original pages are copied to the snapshot database,
preserving the data records as they were when the database snapshot was
created.

You can still backing up the source database. However, you cannot restore the
source database; in order to restore the source database, you must drop the
database snapshots associated to the source database. You cannot also back up
or restore database snapshots.

Data Protection for SQL can be used to back up the source database snapshot.

2.4.9 Full-Text catalogs


In SQL 2005 the full-text catalogs are included in database backups. Until SQL
2000, it was necessary to manually backup the operating system files and
registry entries for the full-text catalogs.

2.4.10 Back up SQL Server non-database components


SQL Server 2005 has several components apart from the database engine. For
some components, the configuration data is not stored inside an SQL Server
database, or a database backup alone is not sufficient to provide the necessary
recoverability capabilities for the component.

54 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Here we discuss these components, and how can you use Tivoli Storage
Management to protect them.

Analysis Services
While sharing the same nomenclature, SQL Server databases and Analysis
Services databases have completely different usages and attributes. An SQL
Server database is used mainly to store relational data, and it is managed by the
SQL Server Database Engine. The Analysis Services database is used to store
OLAP metadata, such as cubes and dimensions, and not the transactional data
itself. Analysis Services databases are stored in operating system files, and are
accessed by the Analysis Services application.

To backup the Analysis Services database, you must use SQL Server tools, such
as SQL Server Management Studio. When you perform a backup operation, it
will check all required files that need to be backed up, and then will generate
package of these files into a single file.

Note: In SQL Server 2000, it was necessary to backup the Analysis Services
data directly from the operating system files - also known as a raw backup. In
SQL Server 2005, although possible, this is not recommended by Microsoft.

You can automate Analysis Services backup execution using scripts, and then
use the Tivoli Storage Manager backup-archive client for Windows to back up the
packaged file to the Tivoli Storage Manager server. By doing this, you can
maintain multiple versions of Analysis Services backups. Data Protection for SQL
Server does not back up Analysis Services databases.

Analysis Services backup and restore are beyond the scope of this book. For
more information about Analysis Services backup and restore strategies, see:

http://www.microsoft.com/technet/prodtechnol/sql/2005/bkupssas.mspx

Reporting Services
There are a number of components to Reporting Services which require backup:
򐂰 Reporting Services Databases
Reporting Services stores its application data in two SQL Server databases:
reportserver, which uses full recovery model, and reportservertempdb, which
uses simple recovery model. Data Protection for SQL Server can back up
these databases, similar to any other SQL Server user database.
򐂰 Encryption keys
To backup and restore Reporting Services encryption keys you must use SQL
Server tools. After you generate a backup file for the encryption key, you can

Chapter 2. Planning considerations 55


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

use the Tivoli Storage Manager backup-archive client for Windows to back up
this file.
򐂰 Reporting Services Web sites
Reporting Services uses Internet Information Services (IIS) as the Web
server for its pages. You can use IIS backup tools to back up the Reporting
Services Web sites.
򐂰 Configuration Files and Data Files
Reporting Services creates several configuration files to store application
settings. Reporting Services also creates several operating system files to
store its components, such as report definition files, report model files, shared
data source files, for example. You can use the Tivoli Storage Manager
backup-archive client for Windows to back up these files.

Reporting Services backup and restore are beyond the scope of this book. For
more information about Reporting Services backup and restore, see:

http://technet.microsoft.com/en-us/library/ms155814.aspx

Integration Services
SQL Server 2005 Integration Services (SSIS) packages are commonly stored in
the msdb database; however, they can also be stored in operating system files. A
regular backup of the msdb database will protect your packages stored in the
database, while you can use the Tivoli Storage Manager backup-archive client for
Windows to back up the packages stored outside the database.

Notification Services
Notification Services stores its data and configuration in databases and operating
system files. You can back up the notification services databases similar to any
other regular user database using Data Protection for SQL Server. To back up
the operating system files, you can use the Tivoli Storage Manager
backup-archive client for Windows.

Note: It is recommended to back up Notification Services database and


operating system files in the same scheduled operation to reduce the
likelihood of application errors after recovery.

Notification Services backup and restore are beyond the scope of this book. For
more information about Notification Services backup and restore, see:

http://technet.microsoft.com/en-us/library/ms166456.aspx

56 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

2.5 IBM Tivoli Storage Manager and Data Protection for


SQL backup strategies considerations
Aside from the main design architecture for Tivoli Storage Manager to backup
SQL Server, other considerations are important for a complete backup strategy.
While these are outside the scope, they are discussed here briefly for
completeness.

2.5.1 Backup policy considerations


IBM Tivoli Storage Manager policy determines how Data Protection for SQL
backups are managed on IBM Tivoli Storage Manager storage.

The Tivoli Storage Manager server recognizes Data Protection for SQL as a
node. Data that is backed up to Tivoli Storage Manager storage from this Data
Protection for SQL node is stored and managed according to settings specified
for Tivoli Storage Manager server policy items. Tivoli Storage Manager policy can
manage the VSS Backups that are placed on local shadow volumes as well as in
Tivoli Storage Manager server storage pools. The Tivoli Storage Manager server
is responsible for managing VSS Backups, whether the backup is stored on local
shadow volumes or on the Tivoli Storage Manager server. Be aware that while a
VSS snapshot (created for back up to Tivoli Storage Manager server storage) is
deleted after the backup completes, a VSS snapshot (created for back up to local
shadow volumes) remains active until the backup version is expired according to
the policy settings for VSS Backups on local shadow volumes.

Make sure the following policy items are defined with the recommended settings:
򐂰 Domain
Create a policy domain on the Tivoli Storage Manager server to be used
exclusively for Data Protection for SQL backups.
򐂰 Policy Set
Policy sets contain management classes (which contain copy groups) that
determine the rules by which Data Protection for SQL backups are performed
and managed. Define the policy set to the policy domain to which Data
Protection for SQL backups belong. Note that the policy set must be activated
and only one policy set can be active in the policy domain.
򐂰 Management Class
Define a management class for backups residing on local shadow volumes
and a management class for backups residing on Tivoli Storage Manager
server storage. Different management classes provide the opportunity for
specialized policies for each storage destination.

Chapter 2. Planning considerations 57


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

Be aware that since Legacy backups on IBM Tivoli Storage Manager server
storage, VSS Backups on IBM Tivoli Storage Manager server storage and
VSS Backups on local shadow volumes all have different IBM Tivoli Storage
Manager server naming and therefore, can each have their own management
class, it is possiblle to have three active backups of the same database. Make
sure your backup strategy is planned and well-defined before defining
management classes.
On legacy backup only, you need to take care about metadata considerations.
The management classes for Data Protection for SQL meta data should be
identical to the corresponding management classes for database data except
that th meta data management classes should not allow migration to
removable media. If any Data Protection for SQL meta data is on removable
media, queries may require media mounts, and backups or restores may
require additional media mounts.
Data objects and their associated meta objects should have the same version
limits and retention values. However, because meta objects may need to be
restored as a result of Data Protection for SQL query, you may want to
consider storing meta objects in a disk-only storage pool so that a media
mount is not necessary to resolve the query. To do this you can either:
– Define a separate management class with a Copy Destination pointing to
a disk pool that does not have any removable media in its hierarchy.
– Bind all meta objects to that management class using an include
statement in the Data Protection for SQL options file. Alternatively, you can
choose to use the same management class (and storage pools) for both
meta and data objects if you rarely need the meta objects, or need them
only immediately preceding a restore when a volume mount is required
anyway. In many cases, you can also obtain the meta object information
from SQL Server as recorded in its msdb database.
򐂰 Copy group
Define the copy group as a backup copy group and not an archive copy group.
Since Data Protection for SQL stores all objects as backup objects on Tivoli
Storage Manager in backup storage pools, an archive copy group is not
required, although an archive copy group can exist. The following backup
copy group parameters significantly influence your backup policy:
– VERExists: Determines the maximum number of SQL Server database
backup versions to retain for databases that exist on the Data Protection
for SQL client system. Therefore, if you want to keep N backups on local
shadow volumes and also perform VSS Backups to Tivoli Storage
Manager server storage, make sure you provision enough storage space
on local shadow volumes and specify verexists=N+1. Make sure to specify
a verexists value that accommodates your VSS Backup goals. If you have
limited storage space for VSS operations and are restricted to a

58 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

verexists=1 setting, you can take advantage of the Backup Destination


BOTH option. This stores the backup on local shadow volumes as well as
sends a copy to Tivoli Storage Manager server storage. It is possible for
VSS Backups (that Data Protection for SQL creates and stores on local
shadow volumes) to be modified and deleted from outside of Tivoli
Storage Manager control. For example, the Microsoft VSSADMIN
DELETE SHADOWS command can remove a VSS Backup managed by
Tivoli Storage Manager without Tivoli Storage Manager being able to
prevent such a removal. In such a situation, Tivoli Storage Manager
recognizes the backup removal and reconciles its index of available
backups with what resides on local shadow volumes. It is important to be
aware of this potential for removal and establish a strategy that protects
VSS Backup data stored on local shadow volumes from being
compromised.
– VERDeleted: Determines the maximum number of SQL Server database
backup versions to retain for databases that have been deleted from the
Data Protection for SQL client system after being backed up by Tivoli
Storage Manager.
– RETExtra: Determines the number of days to retain an SQL Server
database backup version after that version becomes inactive.
– RETOnly: Determines the number of days to retain the last SQL Server
database backup version of a database that has been deleted from the
Data Protection for SQL client system. Be aware that log backups do not
participate in expirations (due to version limit) because there is never more
than one version of log backup object. This is because log backups are
always uniquely named. However, all Legacy backup objects for an SQL
Server database are inactivated when a new full backup of that SQL
Server database is performed.
– MODE, SERialization, FREQuency: You can accept default values for
these backup copy group parameters as they are not applicable to Data
Protection for SQL.
– DESTINATION: Select your preferred storage pool to send your backups.
Verify performance considerations on “Data Protection for SQL Server
performance considerations” on page 64.

See the IBM Tivoli Storage Manager for Windows Administrator’s Reference,
SC32-0127 for complete information regarding these parameters.

Additional considerations for VSS backups


Be aware that the following issues impact your Tivoli Storage Manager policy for
managing VSS Backups:
򐂰 Overall backup strategy.

Chapter 2. Planning considerations 59


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Length of time that VSS Backups will reside on Tivoli Storage Manager server
storage.
򐂰 Number of VSS Backup versions to reside on Tivoli Storage Manager server
storage.
򐂰 Types of VSS Backups to reside on Tivoli Storage Manager server storage.
򐂰 Number of VSS Backup versions to reside on local shadow volumes.
򐂰 Types of VSS Backups to reside on local shadow volumes.
򐂰 The amount of available target volume storage provisioned for VSS
operations.
򐂰 Schedule VSS and legacy backups to start at different times, because you do
not want these backups to overlap. Determine how long each backup would
take and adjust their start times, so that one type of backup will not start
before another has finished.

2.5.2 Client node name considerations


The machine where Data Protection for SQL is installed must be registered to the
Tivoli Storage Manager server with a node name. This node name owns and
manages all Data Protection for SQL data that is backed up to the Tivoli Storage
Manager server. Specify this node name with the nodename option in the dsm.opt
options file located (by default) in the Data Protection for SQL installation
directory.

Be aware to configure the parameter BACKDELete value of YES. This parameter


determines whether the Data Protection for SQL node can delete its own backup
files from the IBM Tivoli Storage Manager server.

Note that in order to perform VSS operations, you may need to register node
names for additional machines.

Proxy node definitions


Since Data Protection for SQL VSS Backup operations are implemented through
the Tivoli Storage Manager backup-archive client, you must use node names
specifically for VSS operations in addition to using a node name for where Data
Protection for SQL is installed. As part of the configuration procedure, a proxy
relationship is defined for these various node names. This proxy relationship
allows node names to perform operations on behalf of another node name. When
registering these nodes to the Tivoli Storage Manager server for VSS operations,
do not specify the Tivoli Storage Manager USerid=NONE parameter. VSS
operations will fail when this parameter is specified. There are two types of node
names defined in proxy node relationships:

60 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

򐂰 Target node: A node name that controls backup and restore operations and
that also owns the data on the Tivoli Storage Manager server.
򐂰 Agent node: A node name that performs operations on behalf of a target
node.

Required node names for basic VSS operations


To perform basic VSS operations, you must have one target node and one agent
node:

Table 2-10 Required node name for basic VSS operations


Proxy node type Nodename Where to specify Considerations

Target node Data Protection for Use the nodename in the Node name where Data
SQL node name Data Protection for SQL Protection for SQL is installed.
options file (dsm.opt)

Agent node Local DSMAGENT Use the Node name where the
node localdsmagentnode backup-archive client and VSS
parameter in the Data provider are installed, it is
Protection for SQL resposible for perfoming VSS
configuration file. operations as Data Protection
itself does not perform any
direct VSS operations.

Note: The agent node and target node will be on the same machine for basic
VSS operations.

Required node name for VSS off-loaded backup


To perform VSS off-loaded backups, you must have one target node and two
agent nodes:

Table 2-11 Required node name for VSS off-load backup


Proxy node type Nodename Where to specify Considerations

Target node Data Protection for Use the nodename option Node name where Data
SQL node name in the Data Protection for Protection for SQL is installed.
SQL options file (dsm.opt)

Chapter 2. Planning considerations 61


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

Proxy node type Nodename Where to specify Considerations

Agent node Local DSMAGENT Use the Node name where the
Node localdsmagentnode backup-archive client and VSS
parameter in the Data provider are installed, it is
Protection for SQL resposible for perfoming VSS
configuration file. operations as Data Protection
itself does not perform any
direct VSS operations

Agent node Remote Use the Node name of a separate


DSMAGENT Node remotedsmagentnode machine that must also have
parameter in the Data the backup-archive client and
Protection for SQL VSS provider installed. The
configuration file. machine is responsible for
perform movement of VSS
snapshot data from local
shadow volumes to the IBM
Tivoli Storage Manager.

Make sure that the localdsmagentnode and remotedsmagentnode are registered to


the same Tivoli Storage Manager server that is specified in the Data Protection
for SQL options file (dsm.opt) and the backup-archive client options file (also
dsm.opt).

2.5.3 Schedule considerations


Scheduling of DP for SQL Server backups is done using the Tivoli Storage
Manager backup-archive client scheduler.

Consider the following when defining a Tivoli Storage Manager scheduler:


򐂰 If you want to use the Tivoli Storage Manager server-prompted scheduling
mode, the Data Protection for SQL option file must contain the
TCPCLIENTADDRESS and TCPCLIENTPORT options. If you want to run more than
one scheduler service, use the same TCPCLIENTADDRESS. However, you must
use different values for TCPCLIENTPORT (in addition to different node names).
You need multiple scheduler services when you are scheduling Data
Protection for SQL as well as the regular Windows backup client.
Server-prompted scheduling is supported only TCP/IP commnunication. By
default, Data Protection for SQL uses the client polling schedule mode.
򐂰 The scheduler must be re-started after making any changes to the DP for
SQL Server options file which affect the scheduler.

62 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Note: If you are running the scheduler service in a cluster environment, use
the Cluster Administrator to stop and restart your scheduler service. Do not
use the net stop and net start commands.

򐂰 The default Tivoli Storage Manager scheduler log file (dsmsched.log)


contains status information fot the scheduler. This file is created by default in
the installation program directory. To override this, use the SCHEDLOGNAME
option in the Data Protection options file.
򐂰 Data Protection for SQL Server creates its own log file with statistics about
the backed up database objects when the /logfile parameter is specified
with the tdpsqlc command.

Note: Output from scheduled commands are sent to the scheduler log file
(dsmsched.log). After scheduled work is performed, check the log to ensure
the work completed successfuly.

򐂰 If PASSWORDACCESS GENERATE is not specified in the dsm.opt file, then the Tivoli
Storage Manager password needs to be specified on the tdpsqlc command.

2.5.4 Data Protection for SQL Server security considerations


Data Protection for SQL Server must be installed by an ID with Windows
administrator authority.

Standard Tivoli Storage Manager security requirements apply to Data Protection


for SQL Server. Data Protection for SQL Server must be registered to the Tivoli
Storage Manager server and the appropriate node name and password must be
used when connecting to the Tivoli Storage Manager server.

Data Protection for SQL Server provides three options when specifying SQL
Server logon information:
򐂰 Accept the default account and blank password used in releases prior to SQL
2005.
򐂰 Use SQL user ID security and specify both the SQL user name and
password. With SQL user ID security, the SQL Server administrator provides
the logon ID and the password that provides access to the SQL Server.
򐂰 Use a trusted connection and let Windows authenticate the logon.

Note: The SQL logon user or Windows user name must be added to the SQL
Server SYSADMIN fixed server role before it can be used by Data Protection
for SQL Server.

Chapter 2. Planning considerations 63


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

For more information about SQL Server security, refer to “SQL Server security”
on page 261.

2.5.5 Data Protection for SQL Server performance considerations


Data Protection for SQL Server provides certain parameters that can be tuned for
optimum performance.

Buffering
Data Protection for SQL Server is a multi-threaded application that uses
asynchronous execution threads to transfer data between the SQL and Tivoli
Storage Manager servers. To accomplish this, multiple data buffers are used to
allow one thread to receive data from one side, while another thread sends data
to the other side. For example, one thread can be reading data from SQL Server
while another is sending data to the Tivoli Storage Manager server. The number
of buffers that Data Protection for SQL Server allocates to these threads can be
specified in the /BUFFERS and /SQLBUFFERS parameters of the command line
interface. The size of these buffers can be specified in the /BUFFERSIZE and
/SQLBUFFERSIZE parameters.

Data striping
In addition to multi-threading to maximize throughput on a single session, Data
Protection for SQL Server uses separate threads to support SQL data striping,
which allows use of multiple parallel sessions to backup and restore a single
database. This is another method to maximize data throughput. If a single
session cannot fully exploit the available bandwidth, multiple parallel sessions
can yield improved data throughput, especially if the database is spread across
multiple physical volumes.

If you use one data stripe per physical volume for both the SQL Server and the
Tivoli Storage Manager server, the performance (measured as the amount of
time necessary to backup or restore a particular SQL database) should show an
improvement over the unstriped case (approximately proportional to the number
of data stripes used, given the constraints of the devices and the network used,
and striping independent overhead in SQL Server, Tivoli Storage Manager
server, and Data Protection for SQL Server).

You must use the MAXNUMMP parameter on a Tivoli Storage Manager REGISTER
NODE or UPDATE NODE command to allow a node to use multiple sessions to store
data on removable media such as tape (which requires multiple mount points to
be allocated to that node).

64 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

Note: Additional striping does not necessarily improve performance and may
even decrease performance if system resources such as real and paged
memory, CPUs, Network Interface Cards, networks, device I/O , and RAID
overhead become saturated or exceed capacity.

If you use striping in conjunction with SQL buffers, make sure that the number
of SQL buffers specified is equal to or greater than the number of stripes.

The default values that Data Protection for SQL Server assigns to buffers,
buffersize, and stripes can be changed in the Data Protection for SQL
configuration file. Use the set command or the Edit menu of the GUI to modify
the configuration file.

LAN-free
Running Data Protection for SQL in a LAN-free environment if you are equipped
to do so avoids network constraints. Specify ENABLELANFREE YES in the Data
Protection for SQL Server options file. For information on setting up a LAN-free
environment, see IBM Tivoli Storage Manager for SAN for Windows Storage
Agent User’s Guide.

Collocation
If you use the full plus log backup strategy, you must decide whether to modify
Tivoli Storage Manager storage management policies to ensure that all log
backups are stored together on the Tivoli Storage Manager server (collocated).
This helps improve restore performance by reducing the number of media
mounts necessary for restoring a series of log backups. Consult your Tivoli
Storage Manager administrator for details on collocation. A single restore can
require a full backup, a differential backup, and multiple incremental backups. It is
recommended to use collocation if these backups are stored on removable
media. Specify collocation by file space: define stgpool COLlocate=FILespace if
you plan to restore multiple databases in parallel. This is recommended because
individual data stripes stay on separate removable volumes. If you use data
striping, use collocation by file space on sequential storage pools to maintain the
stripes on separate storage volumes. This is necessary to allow concurrent
parallel access to each of the stripes. If it happens that multiple stripes for the
same object end up on the same sequential volume (because insufficient empty
volumes are available), the Tivoli Storage Manager server move data command
can be used to move the objects to a disk storage pool or to new sequential
volumes added to the storage pool so that they can be accessed in parallel. A
single, complete restore may require a full database backup, a differential
backup, and multiple log backups, or one or more group, file, or set backups and
multiple log backups. It is recommended that you use collocation if these
backups may be stored on removable media.

Chapter 2. Planning considerations 65


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

2.5.6 Clustering considerations


If you use Microsoft Cluster Server clustering for fail-over support, you must
install Data Protection for SQL on each cluster node and configure it identically.
Additional setup is required to complete the fail-over installation. You must
identify a clustered SQL Server by its virtual server name and use that name in
Data Protection for SQL to access that SQL Server.

Data Protection for SQL supports SQL Server running in a Microsoft Cluster
environment and Veritas Cluster environment. The VSS is supported in a SQL
Server clustered environment.

For Windows 2003, Data Protection for SQL uses the Active Directory to support
fail-over clustering. The list below provides information to consider when running
Data Protection for SQL in a Microsoft Cluster Server Environment or in a Veritas
Cluster Server environment:
򐂰 You must install Data Protection for SQL on both nodes of the cluster. In
addition, when installing Data Protection for SQL, you must install it on a disk
local to each node (not on a shared cluster disk).
򐂰 You must specify clusternode yes in the Data Protection for SQL options file.
򐂰 Use identical configurations in the Data Protection for SQL options file when
configuring Data Protection for SQL on each node of the cluster.
򐂰 If you are using the Tivoli Storage Manager scheduler for automating
backups, you must install the scheduler service on both nodes of the cluster
to enable fail-over support.
򐂰 The Tivoli Storage Manager treats backups as coming from a single server
(the virtual server) regardless of which node of the cluster a backup was
performed on.

Data Protection for SQL supports VSS operations in a clustered SQL Server
environment. These requirements and limitations must be understood in order for
Data Protection for SQL to successfully perform VSS operations in a clustered
SQL Server environment. Some limitations that you need to take care about
clustering on VSS enviroments:
򐂰 Dynamic disks are not supported.
򐂰 VSS Backups that reside on local VSS shadow volumes can only be restored
to the physical node that created the VSS Backup. For example, if NODE_A
of a cluster created a VSS Backup and stored it on local shadow volumes,
NODE_B of the cluster cannot restore that particular VSS Backup. NODE_B
can only restore VSS Backups stored on the Tivoli Storage Manager server or
VSS Backups stored on local shadow volumes that were created by

66 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-2-planning.fm

NODE_B. This is due to a limitation related to VSS cluster support and not to
Tivoli Storage Manager.
򐂰 VSS Backups that reside on local VSS shadow volumes may be deleted in the
event of a cluster failover. This means that if NODE_A of a cluster created a
local VSS Backup and afterward, the SQL Server fails over to NODE_B, if a
Data Protection for SQL VSS operation is performed on NODE_B of the
cluster, the local VSS Backup created by NODE_A will be deleted. This is
caused by the fact that the Microsoft VSS architecture is not cluster aware.
򐂰 The Tivoli Storage Manager Client Acceptor Daemon (CAD) must be installed
on each cluster node so that it can continue operations in the event of a
failover. Make sure the CAD service name is the same on all cluster nodes so
that it can be started by a generic cluster service.
򐂰 It is recommended that the Local DSMAgent client node be a separate node
from your normal backup-archive client, as this CAD service will need to be
made a non cluster option.
򐂰 The Remote DSMAgent client node does not require you to register a
separate node for each server within the cluster as this server only acts as a
secondary server.
򐂰 Use the Microsoft vssadmin and vshadow commands to verify the
environment.
򐂰 A Data Protection for SQL configuration file should be configured for each
node in the cluster. These files are almost identical, except that the
localdsmagentnode parameter points to the corresponding local DSMAgent
on each node.

The considerations about Data Protection for SQL in a cluster environment will
be covered in “Configure Data Protection options file in a clustered environment”
on page 102.

2.5.7 Multiple SQL Servers on same machine


If multiple instances of SQL Server are running, the additional instances are
identified by the instance name. You must use that name in Data Protection for
SQL Server to access that SQL Server.

2.5.8 SQL Server listening on a non default port


If SQL Server is listening on a port different than 1433, you must include the port
number in the TDPCFG.sql file. For more information, see 3.2.10, “Specifying
Data Protection for SQL preferences” on page 103.

Chapter 2. Planning considerations 67


6148ch-2-planning.fm Draft Document for Review April 30, 2008 1:21 pm

68 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Chapter 3. Installation and


configuration
In this chapter we describe how to install and customize IBM Tivoli Storage
Manager Data Protection for SQL to protect your SQL database, and other
related components that is necessary to configure your environment.

The instructions given in this chapter are very detailed. By following them, you
should be able to successfully install IBM Tivoli Storage Manager Data
Protection for SQL and configure it, meeting your company’s requirements.

Beside the basic installation and configuration, we also explain some additional
the Data Protection for SQL installation with IBM Tivoli Storage Manager
Manager for Copy Services. This includes the installation of all components
including the backup-archive client.

The following topics are discussed in this chapter:


򐂰 3.1, “Installation and configuration overview” on page 70
򐂰 3.2, “Detailed installation and configuration procedure” on page 77

© Copyright IBM Corp. 2008. All rights reserved. 69


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

3.1 Installation and configuration overview


This section provides detailed information about installation and configuration
Data Protection for SQL and setting IBM Tivoli Storage Manager options, policies
and preferences.

In your planning steps it is necessary to consider if you are using legacy and
VSS backups, if you have VSS backups you need to do an additional
configuration on your IBM Tivoli Storage Manager server.

You need to identify which applications is necessary to install and configure in


your environment. The Table 3-1 on page 70 identifies the software applications
that you need to install and what is necessary to configure to perform certain
features.

Table 3-1 List of applications to install and to configure


To use these features Application to install (SQL Applications to configure
Server machine)

򐂰 Legacy backup 򐂰 Backup-archive client 򐂰 Data Protection for SQL


򐂰 Legacy restore 򐂰 Data Protection for SQL 򐂰 Tivoli Storage Manager
Server
򐂰 Tivoli Storage Manager
backup-archive client
scheduler

򐂰 VSS Backup 򐂰 Backup-archive client 򐂰 Data Protection for SQL


򐂰 VSS Restore 򐂰 Data Protection for SQL 򐂰 Tivoli Storage Manager
򐂰 IBM Tivoli Storage Manager Server
for Copy Services 򐂰 Tivoli Storage Manager
backup-archive client
scheduler
򐂰 Tivoli Storage Manager
backup-archive client local
Client Acceptor Daemon
(CAD) (Local DSMAGENT
Node)
򐂰 VSS software provider and /
or VSS hardware provider

70 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

To use these features Application to install (SQL Applications to configure


Server machine)

򐂰 VSS Backup 򐂰 Backup-archive client 򐂰 Data Protection for SQL


򐂰 VSS Restore 򐂰 Data Protection for SQL 򐂰 Tivoli Storage Manager
򐂰 Off-loaded backup 򐂰 IBM Tivoli Storage Manager Server
for Copy Services 򐂰 Tivoli Storage Manager
backup-archive client
scheduler
򐂰 Tivoli Storage Manager
backup-archive client local
Client Acceptor Daemon
(Local DSMAGENT Node)
򐂰 Tivoli Storage Manager
backup-archive client local
Client Acceptor Daemon
(Remote DSMAGENT Node)
򐂰 VSS software provider and /
or VSS hardware provider.

򐂰 VSS Backup 򐂰 Backup-archive client 򐂰 Data Protection for SQL


򐂰 VSS Restore 򐂰 Data Protection for SQL 򐂰 Tivoli Storage Manager
򐂰 VSS Instant Restore 򐂰 IBM Tivoli Storage Manager Server
򐂰 Off-loaded backup for Copy Services 򐂰 Tivoli Storage Manager
backup-archive client
scheduler
򐂰 Tivoli Storage Manager
backup-archive client local
Client Acceptor Daemon
(Local DSMAGENT Node)
򐂰 Tivoli Storage Manager
backup-archive client local
Client Acceptor Daemon
(Remote DSMAGENT Node)
򐂰 VSS software provider and /
or VSS hardware provider

Note: You can configure Legacy and VSS backups to work together. Consider
the features you want to use and install all the necessary software to attend all
requests.

Chapter 3. Installation and configuration 71


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

3.1.1 IBM Tivoli Storage Manager components requirements


We assume that you have knowledge in IBM Tivoli Storage Manager client and
server installation and configuration. For more detailed information about IBM
Tivoli Storage Manager server, you can use other IBM Redbooks for reference:
򐂰 IBM Tivoli Storage Management Concepts, SG24-487777
򐂰 IBM Tivoli Storage Manager Implementation Guide, SG24-541616

Perform these steps on your IBM Tivoli Storage Manager server:


1. Define the policy domains, policy sets, management classes, copy groups,
and storage pools needed to meet your Data Protection for SQL backup and
restore requirements. For VSS operations, Tivoli Storage Manager server
authentication must be on.
2. Register your Data Protection for SQL node name and password with the
Tivoli Storage Manager REGISTER NODE command. For example: For VSS
operations, this node is the Target Node. Note that when registering nodes to
the Tivoli Storage Manager server specifically for VSS operations, do not
specify the Tivoli Storage Manager USerid=NONE parameter. VSS operations
will fail when this parameter is specified.
3. If not already defined, register your Tivoli Storage Manager backup-archive
client node name and password for the machine where the SQL Server
installed. For example:For VSS operations, this agent node is the Local
DSMAGENT Node.
4. (VSS only) If you plan to perform off-loaded backups, register the Tivoli
Storage Manager backup-archive client node name and password for the
machine that will perform the VSS off-loaded backups.
5. (VSS only) Define the proxy node relationship (for the Target Node and agent
nodes) with the Tivoli Storage Manager GRANT PROXYNODE command.

3.1.2 SQL Server machine configuration


Perform these steps on the machine where the SQL Server is installed and
running:
1. Specify your Data Protection for SQL node name and communication method
in the dsm.opt file located (by default) in the Data Protection for SQL
installation directory. Additional options are also available. For additional
information, see 3.2.9, “Specifying Data Protection for SQL options” on
page 99.
2. Specify your Data Protection for SQL preferences (such as language, date
format, log file, etc.) in the tdpsql.cfg file located (by default) in the Data

72 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Protection for SQL installation directory. Use the set command or the menu
Edit → Configuration task of the Data Protection for SQL GUI. For additional
information, see 3.2.10, “Specifying Data Protection for SQL preferences” on
page 103.
3. Add the Microsoft SQL Server binary path to the PATH statement in the
system environment variables.
4. The following additional steps are for VSS only customization:
a. Specify your VSSPOLICY statement in your Data Protection for SQL
configuration file. For additional information, see 3.2.10, “Specifying Data
Protection for SQL preferences” on page 103.
b. Configure the Tivoli Storage Manager backup-archive client (if it is not
already configured). If the backup-archive client is already configured, you
can use existing client services. The backup-archive client Setup Wizard
can guide you through the configuration process (if needed). In the
backup-archive client GUI menu, select Utilities → Setup Wizard → Help
me configure the TSM Backup Archive Client. Note that the node name
for this machine is referred to as the Local DSMAGENT Node and is
specified with the localdsmagentnode parameter in the Data Protection for
SQL configuration file (tdpsql.cfg by default). For additional information,
see “Required node name for VSS off-loaded backup” on page 61.
c. Install and configure the Tivoli Storage Manager Client Acceptor Daemon
(CAD) Service (if not already installed and configured). You can use an
existing client CAD Service if one is already installed and configured. The
backup-archive client Setup Wizard can guide you through the CAD
installation process (if needed). In the backup-archive client GUI menu,
select Utilities → Setup Wizard → Help me configure the TSM Web
Client. Make sure this CAD service is running before proceeding to Step
6.
d. Install and configure the Tivoli Storage Manager Remote Client Agent
Service (DSMAGENT) if it is not already installed and configured. The
backup-archive client Setup Wizard can guide you through the
configuration process. In the backup-archive client GUI menu, select
Utilities → Setup Wizard → Help me configure the TSM Web Client.
You can use the existing DSMAGENT if one is already installed and
configured.
e. Install the Tivoli Storage Manager Copy Services SQL VSS Integration
Module from the product (if it is not already installed).
f. If you plan to perform VSS Instant Restores, install the Tivoli Storage
Manager Copy Services Hardware Devices Snapshot Integration Module
from the product (if it is not already installed). Note that a SAN Volume

Chapter 3. Installation and configuration 73


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Controller, DS6000, or DS8000 storage subsystem is also required to


perform VSS Instant Restores.
g. Install and configure a VSS provider. Consult the VSS provider
documentation for information regarding configuration of that software.
That there is no installation or configuration required if you are using the
default Windows VSS System Provider.
h. Define storage space to hold VSS Backups that will reside on local
shadow volumes. Make sure you define enough space to hold all copies of
the VSS Backups as designated by your policies. For additional
information, see 2.5.1, “Backup policy considerations” on page 57.

3.1.3 VSS off-loaded backup configuration


The VSS offloaded backup configuration is necessary when you are working with
VSS backups.

Perform these steps on the machine running the off-loaded backups:


1. Configure the Tivoli Storage Manager backup-archive client (if it is not already
configured). If the backup-archive client is already configured, you can use
existing client services. The backup-archive client Setup Wizard can guide
you through the configuration process (if needed). In the backup-archive
client GUI menu, select Utilities → Setup Wizard → Help me configure the
TSM Backup Archive Client. Note that the node name for this machine is
referred to as the Remote DSMAGENT Node and is specified with the
remotedsmagentnode parameter in the Data Protection for SQL configuration
file (tdpsql.cfg by default).
2. Install and configure the Tivoli Storage Manager Client Acceptor Daemon
(CAD) Service (if not already installed and configured). You can use an
existing client CAD Service if one is already installed and configured. The
backup-archive client Setup Wizard can guide you through the CAD
installation process (if needed). In the backup-archive client GUI menu, select
Utilities → Setup Wizard → Help me configure the TSM Web Client.
3. Install and configure the Tivoli Storage Manager Remote Client Agent Service
(DSMAGENT). The backup-archive client Setup Wizard can guide you
through the configuration process. In the backup-archive client GUI menu,
select Utilities → Setup Wizard → Help me configure the TSM Web
Client.

74 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Note: The SQL Server does not need to be installed or running on this
machine. Only the Microsoft SQL Server management tools are required to be
installed on this machine. Check your Microsoft SQL Server documentation for
necessary license requirements.

4. Install and configure a VSS provider (if you are not using the default system
VSS provider). Consult the VSS provider documentation for information
regarding configuration of that software.

3.1.4 Our environment overview


Our lab environment permits a lot of capabilities of Data Protection for SQL
implementation. It is possible to simulate Legacy and VSS backups, as well as
fast restore.

Our environment consists of five servers: ZAIRE is our IBM Tivoli Storage
Manager server, COPPER is a stand alone SQL Server used for Legacy and
VSS backups. We also have an MSCS clustered SQL Server environment -
consisting of servers LIBRA and LEO. For the VSS offloaded backup server we
have the MOLITO server. We have an IBM System Storage 3582 Tape Library
with two drives.

Figure 3-1 on page 76 shows our environment.

Chapter 3. Installation and configuration 75


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Corporat e LAN

Cluster He artbe at

Microsoft Cluster

zaire AIX 5.3 cooper Windows 2003 libra Windows 2003 leo
TSM Serv er Ac tive Directory SQL Server
CIM Agent SQL Server

molito
switch Windows 2003
Offloaded

358 2
N Serie s
2 drives

Figure 3-1 LAB environment

In our lab environment we have IBM N series external storage which hosts the
clustered SQL Server database environment. This is used as the source for VSS
backups. Table 3-2 describes our server’s configuration.

Table 3-2 IBM redbook machines configuration


Host name Purpose Operating IP Software installed
System Address

ZAIRE 򐂰 Tivoli Storage AIX 5.3 9.43.86.22 򐂰 IBM Tivoli Storage


Manager Server Manager server

COPPER 򐂰 Active Directory Windows 2003 9.43.86.64 򐂰 SQL Server


򐂰 DNS 򐂰 IBM Tivoli Storage
򐂰 SQL Server Legacy Manager client
Backup 򐂰 Data Protection for SQL
򐂰 IBM Tivoli Storage
Manager for Copy Services

76 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Host name Purpose Operating IP Software installed


System Address

LIBRA 򐂰 SQL Server node in Windows 2003 9.43.86.93 򐂰 SQL Server


a cluster 򐂰 IBM Tivoli Storage
environment Manager client
򐂰 VSS and Legacy 򐂰 Data Protection for SQL
Backup together 򐂰 IBM Tivoli Storage
Manager for Copy Services

LEO 򐂰 SQL Server node in Windows 2003 9.43.86.92 򐂰 SQL Server


a cluster 򐂰 IBM Tivoli Storage
environment Manager client
򐂰 VSS and Legacy 򐂰 Data Protection for SQL
Backup together 򐂰 IBM Tivoli Storage
Manager for Copy Services

MOLITO 򐂰 Offload backup Windows 2003 9.43.86.95 򐂰 IBM Tivoli Storage


Manager client
򐂰 VSS Provider that is
supports transportable
shadow copies
򐂰 IBM Tivoli Storage
Manager for Copy Services

3.2 Detailed installation and configuration procedure


In the following sections we explain the detailed steps to install and configure
your environment for Legacy and VSS backups of SQL Server.

3.2.1 Verify name resolution


It is important that all servers in your configuration can correctly perform name
resolution, including the IBM Tivoli Storage Manager server. You can check if all
machines can connect using both host name and IP address (forward and
reverse name resolution).

In our configuration we have five machines, one AIX and four Windows.
COPPER is our DNS server and Active Directory domain controller.

3.2.2 Configure storage pools


It is recommended to set up separate storage pools to back up your SQL Server
environment. Three storage pools will be used in this configuration. one disk

Chapter 3. Installation and configuration 77


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

storage pool and two tape storage pools. SQLDISKPOOL is the primary storage pool
for SQL backup of transaction logs and SQLTAPEPOOL will be the next storage pool
for the SQLDISKPOOL and the primary storage pool for the SQL backup
databases. We have another pool, LNGTAPEPOOL, for long term retention period.
Example 3-1 on page 78, shows the commands to create these storage pools.

Example 3-1 IBM Tivoli Storage Manager server storage pool definitions
tsm: ZAIRE> define stgpool SQLDISKPOOL DISK description=”Backup SQL
Server transaction logs”

tsm: ZAIRE> define stgpool SQLTAPEPOOL LTO2-DC maxscratch=100


reusedelay=1 description=Backup SQL Server Databases”

tsm: ZAIRE>define stgpool lngtapepool LTO2-DC maxscratch=100


reusedelay=1 descri ption="Backup SQL Server Databases for
Long Term retention"

If you are working with VSS backups it is recommended that you configure an
additional disk storage pool on disk for SQL meta objects. Example 3-2 on
page 78, shows the commands for configuration.

Example 3-2 Adittional IBM Tivoli Storage Manager server storage pool definitions
tsm: ZAIRE>define stgpool sqlmetapool disk description="Storage Pool
for VSS Bac kup Metadata"

3.2.3 Configure policy settings


Remember to set up your configuration carefully, considering all requirements for
your data retention. A policy domain will be used in this configuration just to
backup SQL Server databases. We create the following management classes to
satisfy our retention requirements:
򐂰 SQL_DAILY: This is the management class used for weekly and daily legacy
backups. The retention policy is based on date. If you need to have different
backup policies you should create more than one management classes
򐂰 SQL_LONG: This is the management class used for legacy long-term
backups. It is enforced by date policy, and in our example we create this
management class to retain monthly backups.
򐂰 SQL_LOGS: This is the management class used to backup SQL transaction
logs.

78 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

If you are working with VSS backups, it is recommended to configure additional


management classes:
򐂰 VSS_LOCAL: This is the management class used for local VSS backups.
Usually you can perform several local backups per day. The retention policy
should be enforced by version instead of time, because you must ensure that
you have enough disk space to hold all your required snapshots. In this case
we specify VEREXISTS=3. The copy group destination points to a small disk
storage pool. This is because even though the VSS backup itself does not use
IBM Tivoli Storage Manager space pool, some backup metadata is stored in a
storage pool. We recommend to configure a disk pool only, with no migration
to tape, to ensure that the metada can be quickly accessed in the event of a
restore.
򐂰 VSS_FULL_TSM: This is the management class used for daily VSS backups
that are sent to IBM Tivoli Storage Manager. This kind of backup uses just
one non-persistent (temporary) snapshot in order to send the data to the IBM
Tivoli Storage Manager server. Therefore, you just need to ensure that you
always have the required disk space for this snapshot. If you perform your
backup destination with both, then the target set will be used for both
backups, local and IBM Tivoli Storage Manager. The retention policy for
backups to IBM Tivoli Storage Manager should be enforced by time period, in
this case we configure 30 days, VEREXISTS=NOLIMIT and RETEXTRA=30.

Example 3-3 on page 79 shows the commands to configure these policy


requirements.

Example 3-3 Define policy requirements for SQL Server backups


tsm: ZAIRE>define domain pdsql description="SQL Server Policy Domain"

tsm: ZAIRE>define policyset pdsql pssql description="SQL Server Policy


Set"

tsm: ZAIRE>define mgmtclass pdsql pssql sql_daily description="SQL


Server daily Backups"

tsm: ZAIRE>define mgmtclass pdsql pssql sql_LONG description="SQL


Server Long Tr em backups"

tsm: ZAIRE>define mgmtclass pdsql pssql sql_logs description="SQL


Server transac ation logs"

tsm: ZAIRE>define copygroup pdsql pssql sql_daily type=backup


destination=sqltap epool verexists=nolimit verdeleted=nolimit
retextra=30 retonly=30

Chapter 3. Installation and configuration 79


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

tsm: ZAIRE>define copygroup pdsql pssql sql_logs type=backup


destination=sqldisk pool verexists=nolimit verdeleted=nolimit
retextra=30 retonly=30

tsm: ZAIRE>assign defmgmtclass PDSQL PSSQL SQL_DAILY

tsm: ZAIRE>validate policyset PDSQL PSSQL

tsm: ZAIRE>activate policyset PDSQL PSSQL

Example 3-4 on page 80, shows additional configuration if you have VSS
Backups.

Example 3-4 Additional policy requirements for SQL server backups


tsm: ZAIRE>define mgmtclass pdsql pssql VSS_LOCAl description="VSS
Local Mgmtcla ss"

tsm: ZAIRE>define mgmtclass pdsql pssql VSS_FULL_TSM description="VSS


Full Mgmtc lass"

tsm: ZAIRE>define mgmtclass pdsql pssql VSS_LONG_TSM description="VSS


Copy Mgmtc lass"

tsm: ZAIRE>define copygroup pdsql pssql vss_local type=backup


destination=sqlmet apool verexists=3 verdeleted=3 retextra=nolimit
retonly=nolimit

tsm: ZAIRE>define copygroup pdsql pssql vss_full_tsm type=backup


destination=sql tapepool verexists=nolimit verdeleted=nolimit
retextra=30 retonly=30

tsm: ZAIRE>define copygroup pdsql pssql vss_copy_tsm type=backup


destination=lng tapepool verexists=nolimit verdeleted=nolimit
retextra=365 retonly=365

tsm: ZAIRE>assign defmgmtclass PDSQL PSSQL VSS_LOCAL

tsm: ZAIRE>validate policyset PDSQL PSSQL

tsm: ZAIRE>activate policyset PDSQL PSSQL

80 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

3.2.4 Configure node names


Now you must register the nodes on the IBM Tivoli Storage Manager server.

Example 3-5 on page 81, shows how to configure a node just to use Legacy
Backup. We register one node for each of our SQL Server servers.

Example 3-5 Node configuration for Legacy Backup


tsm: ZAIRE>register node copper_sql copper domain=pdsql

tsm: ZAIRE>register node clussql01_daily <password> domain=pdsql

tsm: ZAIRE>register node clussql01_long <password> domain=pdsql

Example 3-6 on page 81 shows how to configure a node to work with VSS
Backups and Legacy Backups together.

Example 3-6 Node configuration for VSS and Legacy Backups together
tsm: ZAIRE>register node copper_vss <password> domain=pdsql

tsm: ZAIRE>register node libra_vss <password> domain=pdsql

tsm: ZAIRE>register node leo_vss <password> domain=pdsql

Example 3-7 on page 81, shows how to configure a node to perform offloaded
VSS backups.

Example 3-7 Node configuration for offloaded backups


tsm: ZAIRE>register node molito_offload <password> domain=pdsql

3.2.5 Install the backup-archive client code


Install the IBM Tivoli Storage Manager backup-archive client at V5.5 or higher on
all machines that will participate in the backup of SQL Server. In our environment
we have 4 servers where will install the backup-archive client. The server
COPPER has a standalone SQL Server and will perform both legacy and VSS
backup. Servers LEO and LIBRA will have the VSS and Legacy working
together, in a cluster environment. The server MOLITO will act as as VSS
off-loaded server.

In a cluster environment you need to install the IBM Tivoli Storage Manager
backup-archive client on both machines.

Chapter 3. Installation and configuration 81


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Refer to the client installation documentation for detailed instructions. You may
choose Custom installation to select additional components and features, such
as Open Files support, Image backup support, and more.

If these features are not required, we recommend that you choose Typical
installation to ensure that all Tivoli Storage Manager basic client components and
prerequisites are installed. You may install the remaining features later, when
required.

To install the IBM Tivoli Storage Manager backup-archive client, follow these
steps:
1. Insert the product installation CD. Double click the IBM Tivoli Storage
Manager backup-archive client installer icon.

Note: If you do not have the CD and have downloaded the software from the
IBM Passport Avantage Web site, just double-click on the IBM Tivoli Storage
Manager backup-archive client executable file (ending with .exe), and you will
be directed to the screns below.

2. Select “Install Products” on Main Menu option, as shown in Figure 3-2 on


page 82

Figure 3-2 Main Menu IBM Tivoli Storage Manager Client

82 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

3. Select “TSM Backup-archive client - x32”, as shown in Figure 3-3 on page 83.

Figure 3-3 Install TSM Backup-archive Client - X32

4. Select a language for the installation, as shown in Figure 3-4 on page 83.
English language will be selected in this installation.

Figure 3-4 Select language for installation

5. Click Next in the installation wizard welcome screen, as shown in Figure 3-5
on page 84.

Chapter 3. Installation and configuration 83


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-5 InstallShield Wizard Welcome

6. Accept the license aggreement and click Next.


7. Select the destination folder to install the package and click Next. The default
installation directory C:\PROGRAM FILES\TIVOLI\TSM\BACLIENT will be
used. See Figure 3-6 on page 84.

Figure 3-6 IBM Tivoli Storage Manager backup-archive client installation code

8. Select setup type. We choose Custom setup so that we can also install the
Administrative Client command line files. Click Next, as in Figure 3-7.

84 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-7 Select setup type

9. Click Install to start the installation. See Figure 3-8 on page 86.

Chapter 3. Installation and configuration 85


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-8 Ready to install program

10.If the installation completes successfully, click Finish. See Figure 3-9 on
page 86.

Figure 3-9 IBM Tivoli Storage Manager backup-archive client completed successfully

After the client installs, verify that the VSS Snapshot Plug-in pivss.dll exists in the
BACLIENT\PLUGINS directory (C:\PROGRAM
FILES\TIVOLI\TSM\BACLIENT\PLUGINS).

86 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Installing Language packs - X32


Addicional Language packs can be installed to provide messages in a language
other than English. You can choose the option TSM Language Packs - X32,
followed by Main Menu, see Figure 3-10 on page 87, to see which languages you
can install.

Figure 3-10 Language Packs - X32

3.2.6 Install the Data Protection for SQL code


Install the Data Protection for SQL at V5.5 or higher on all machines that will
participate in the SQL Server backup. In a cluster environment, you need to
install Data Protection for SQL on both nodes. If you have an Active / Active SQL
Server cluster environment, you should create a Start Menu shortcut for each
virtual SQL Server that can run on this machine.

To install Data Protection for SQL, follow these steps:


1. Insert the product installation CD. Double click the Data Protection for SQL
installer icon.

Chapter 3. Installation and configuration 87


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Note: If you do not have the CD and have downloaded the software from the
IBM Passport Avantage Web site, just double-click on the Data Protection for
SQL client executable file (ending with .exe) and you will be directed to the
screns below.

2. Select a language for the installation, as shown in Figure 3-11 on page 88.
We choose English.

Figure 3-11 Select language for installation

3. Click Next in the installation wizard welcome, as shown in Figure 3-12 on


page 88.

Figure 3-12 InstallShield Wizard Welcome

4. Accept the license agreement and click Next.


5. Select the destination folder to install the package and click Next. The default
installation directory C:\PROGRAM FILES\TIVOLI\TSM will be used. See
Figure 3-13 on page 89.

88 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-13 Data Protection for SQL installation code

6. Click Install, to start the installation. See Figure 3-14 on page 89.

Figure 3-14 Ready to install program

7. If the installation completes successfully, click Finish. See Figure 3-15 on


page 90.

Chapter 3. Installation and configuration 89


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-15 Data Protection for SQL installed successfully

If you want to use the Silent Installation you can use the Data Protection for SQL
Installation and User’s Guide for reference.

Installing Data Protection for SQL additional language packs


Additional language packs can be installed to provide messages in a language
other than English. The language packs are additional executable files provided
with product CD-ROM. The files are located in the TDPSql\x32\languages
directory on the product CD-ROM. You can choose a directory with a three-letter
country code associated with the language that you want to install. You have the
following languages available:
򐂰 chs: Chinese Simplified
򐂰 cht: Chinese Traditional
򐂰 deu: Standard German
򐂰 esp: Standard Spanish
򐂰 fra: Standard French
򐂰 ita: Standard Italian
򐂰 jpn: Japanese
򐂰 kor: Korean
򐂰 ptb: Brazilian Portuguese

3.2.7 Install Copy Services code and Hardware integration module


Install the Copy Services code at V5.5 or higher on all machines that will
participate in the SQL Server VSS backups.

90 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

IBM Tivoli Storage Manager for Copy Services actually consists of two modules:
MS SQL Server VSS Integration Module and Hardware Devices Snapshot
Integration Module. The first module is required in all configurations for VSS
backup. The Hardware Devices Snapshot Integration Module is required only if
you are using disk storage which supports Instant Restore.

Install Copy Services code


To install Copy Services, follow these steps:
1. In the directory TDPSql\x32\plugin, run setup.exe.

Note: If you do not have the CD and have downloaded the software from the
IBM Passport Avantage Web site, just double-click on the Copy Services
executable file (ending with .exe) and you will be directed to the screns below.

2. Select a language for the installation, as shown in Figure 3-16 on page 91.
English language will be selected in this installation.

Figure 3-16 Select language for installation

3. Click Next in the installation wizard welcome, shown in Figure 3-17 on


page 92.

Chapter 3. Installation and configuration 91


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-17 InstallShield Wizard Welcome

4. Accept the license aggreement and click Next.


5. Click Install, to start the installation. See Figure 3-18 on page 92.

Figure 3-18 Ready to install program

6. If the installation completes successfully, click Finish. See Figure 3-19 on


page 93.

92 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-19 Copy Services installed successfully

Install the Hardware Device Snapshot integration module


To install Copy Services, follow these steps:
1. In the directory tsmcli\x32\plugin, run setup.exe.

Note: If you do not have the CD and have downloaded the software from the
IBM Passport Avantage Web site, just double-click on the Copy Services
executable file (ending with .exe) and you will be directed to the screns below.

2. Select a language for the installation, as show in Figure 3-20 on page 93. We
choose English language.

Figure 3-20 Select language for installation

3. Click Next in the installation wizard welcome, shown in Figure 3-21 on


page 94.

Chapter 3. Installation and configuration 93


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-21 InstallShield Wizard Welcome

4. Accept the license aggreement and click Next.


5. Click Install, to start the installation. See Figure 3-22 on page 94.

Figure 3-22 Ready to install program

6. If the installation completes successfully, click Finish. See Figure 3-23 on


page 95.

94 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-23 Hardware Snapshot Integration Module installed successfully

3.2.8 Specifying backup-archive client options


If you are using VSS backups, the SQL Server node requires an IBM Tivoli
Storage Manager backup-archive client node (DSMAgent) with an associated
options file. The standard options file, dsm.opt, is located in the installation
directory (C:\Program files\tivoli\TSM\baclient).

Note: If you are just using Legacy Backups, these steps are not necessary.

Configure backup-archive options file on a standalone


environment
The machine COPPER is a standalone SQL Server configuration. The node
copper_vss was created just to act as DSMAgent. This node has an associated
options file. See Example 3-8 on page 95.

Example 3-8 Backup-archive options file for a standalone machine configuration


NODename copper_vss
CLUSTERnode NO
PASSWORDAccess generate

COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63
TCPBuffSize 32

Chapter 3. Installation and configuration 95


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

TCPCLIENTADDRESS 9.43.86.64
managedservices webclient

We created options file dsm_vss.opt in the client installation directory, rather than
the default options file dsm.opt. We recommend creating a shortcut for the
backup-archive GUI which points to the actual options file. Follow these steps to
create a shortcut:
1. On your Windows Desktop, click the right mouse button and select New →
Shortcut. The Create Shortcut screen appears, see Figure 3-24 on page 96:

Figure 3-24 Create a shortcut

2. Select the binary files “c:\program files\tivoli\tsm\baclient\dsm.exe”, and


include the options file. In our example, the full string is "C:\Program
Files\Tivoli\TSM\baclient\dsm.exe" -optfile=”C:\Program
Files\Tivoli\TSM\baclient\dsm_vss.opt”. Click Next. SeeFigure 3-25 on
page 97.

96 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-25 Select options file

3. Select a name for the shortcut and click Finish. See Figure 3-26 on page 97:

Figure 3-26 Select a name for shortcut

A shortcut is now created in your Windows Desktop. It is necessary to launch the


backup-archive GUI using the shortcut to store the encrypted password in the
registry, since we specified PASSWORDACCESS GENERATE in the options file. If you
change this password you need to run the backup-archive GUI again and
revalidate the password.

Alternatively, you can use the the command line interface to perform this step, as
shown in Example 3-9 on page 98.

Chapter 3. Installation and configuration 97


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Example 3-9 Using command-line interface to store encrypted password


C:\Program Files\Tivoli\TSM\baclient>dsmc -optfile="c:\program
files\tivoli\tsm\
baclient\dsm_vss.opt"
IBM Tivoli Storage Manager
Command Line Backup/Archive Client Interface
Client Version 5, Release 5, Level 0.0 0827FA
Client date/time: 10/14/2007 18:02:05
(c) Copyright by IBM Corporation and other(s) 1990, 2007. All Rights
Reserved.

Node Name: COPPER_VSS


Session established with server ZAIRE: AIX-RS/6000
Server Version 5, Release 4, Level 0.0
Server date/time: 10/14/2007 16:01:32 Last access: 10/14/2007
16:00:56

tsm>

Configure backup-archive options file in a clustered


environment
The servers LIBRA and LEO are part of a cluster environment. The nodes
libra_vss and leo_vss were created just to act as DSMAgents. Each node has an
associated option file. In a cluster environment, it is recommended to store the
options file on a shared disk device. You can maintain the configuration files on
each server local disk, but you need to remember that any modification must be
replicated to other cluster machines.

When you have a cluster environment and local VSS backups will be made, it is
necessary to configure the parameter VSSALTSTAGINGIDIR in the DSMAgent
option file. This parameter is used to specify a location to store VSS manager
files on a shared volume. It should point to a shared device that does not contain
any SQL Server objects. See Example 3-10 on page 98 and Example 3-11 on
page 99.

Example 3-10 Backup-archive options file for Local DSMAgent node for machine Libra
NODename libra_vss
PASSWORDAccess generate
vssaltstagingdir f:\tsmvssdir

COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63

98 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager


Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

TCPBuffSize 32
TCPCLIENTADDRESS 9.43.86.64
clusternode no
clusterdisksonly no
managedservices webclient

Example 3-11 Backup-archive options file for Local DSMAgent node for machine Leo
NODename leo_vss
PASSWORDAccess generate
vssaltstagingdir f:\tsmvssdir

COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63
TCPBuffSize 32
TCPCLIENTADDRESS 9.43.86.64
clusternode no
clusterdisksonly no
managedservices webclient

Note: It is recommended that the Local DSMAgent client node be a separate


node from your normal backup-archive client, as this CAD service will need to
be made a non cluster option. So, make sure to specify the following options
“clusternode no” and “clusterdiskonly no” in each of the dsm.opt files that are
used for the LOCALDSMAGENT.

3.2.9 Specifying Data Protection for SQL options


Once Data Protection for SQL is registered to a Tivoli Storage Manager server,
several Data Protection for SQL parameters need to be configured. The Tivoli
Storage Manager administrator should have provided you with the node name,
password, and the communications method with the appropriate parameters to
connect to the Tivoli Storage Manager server. These values, together with other
parameters, are stored in an options file in the Data Protection for SQL directory.
The default options file name is dsm.opt it can be edited with a standard text
editor. The options file includes the following parameters, which are required for
initial configuration:

Nodename
The Tivoli Storage Manager nodename is the unique name by which Tivoli
Storage Manager knows the machine running Data Protection for SQL.

Chapter 3. Installation and configuration 99


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Servername
This is the name of the Tivoli Storage Manager server to which you backup SQL
databases.

Commmethod
The communication protocols link the Data Protection for SQL node with the
Tivoli Storage Manager server. Data Protection for SQL supports the same set of
communication protocols supported by other Tivoli Storage Manager clients.

Passwordaccess
When set to the value GENERATE, this instructs the Tivoli Storage Manager API to
store the current password (encrypted) in the Windows registry and automatically
generate a new one when the current one expires. This method of password
management is recommended when running scheduled, unattended backups
since it ensures that the backup never fails because of an expired password. The
default value is PROMPT. A utility program named dsmcutil.exe allows you to
manage (update or display) the password as stored in the registry. This utility
program is distributed with the Tivoli Storage Manager backup-archive client
package. For more information on using the dsmcutil program, see the
dsmcutil.hlp file or the dsmcutil.txt file which are distributed with the Tivoli
Storage Manager Backup-Archive Client package.

Compression
A setting of COMPRESSION ON instructs the Tivoli Storage Manager API to
compress data before sending it to the Tivoli Storage Manager server; this
reduces traffic and storage requirements.

Clusternode
A setting of CLUSTERNODE YES directs the Tivoli Storage Manager API and Data
Protection for SQL to be cluster-aware when running in a MSCS or VCS
environment. This option must be specified for Data Protection for SQL to
function properly in a MSCS or VCS environment.

Enablelanfree
A setting of ENABLELANFREE YES allows Data Protection for SQL to run in a LAN
free environment if you are equipped to do so.

Note: If you are running Data Protection for SQL in a MSCS envronment, the
options file on both nodes of the cluster must be identical, including the
nodename.

You can create additional Data Protection for SQL options files to point to
other IBM Tivoli Storage Manager servers.

100 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Configure Data Protection options file in a standalone


environment
In a non-clustered environment, you can use the default standard name and
location (C:\Program Files\Tivoli\TSM\TDPSql\dsm.opt). In our case we have two
different backup policies configured, one for daily backups and another one for
monthly backups. For this scenario, it is necessary to have a different options file
for each type of retention policy with an associated node name.

Data Protection for SQL allows you to utilize Tivoli Storage Manager automatic
expiration and version control by policy. Setting automatic policy for backup data
is accomplished through the Data Protection for SQL options file. Use include
and exclude statements in the options file to define which files are subject to
automatic processing, and to assign specific management classes to files using
object naming conventions.

See Example 3-12 on page 101 for Daily Backups and Example 3-13 on
page 101 for monthly backups.

Example 3-12 Options file for daily SQL Backups


NODename copper_sql
CLUSTERnode NO
PASSWORDAccess generate
password copper
COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63
TCPBuffSize 32
COMPRESSIon NO
SCHEDMODE Prompt

INCLUDE "\...\meta\...\*" SQL_DAILY


INCLUDE "\...\data\...\*" SQL_DAILY

INCLUDE "\...\meta\...\log*" SQL_LOGS


INCLUDE "\...\data\...\log*" SQL_LOGS

EXCLUDE "\...\master\...\log*"
EXCLUDE "\...\msdb\...\log*"

Example 3-13 Options file for Monthly SQL Backups


NODename copper_lng
CLUSTERnode NO
PASSWORDAccess generate

Chapter 3. Installation and configuration 101


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

password copper
COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63
TCPBuffSize 32
COMPRESSIon NO
SCHEDMODE Prompt

INCLUDE "\...\meta\...\*" SQL_LONG


INCLUDE "\...\data\...\*" SQL_LONG

EXCLUDE "\...\master\...\log*"
EXCLUDE "\...\msdb\...\log*"

Configure Data Protection options file in a clustered


environment
In a clustered environment, the Data Protection options file must be accessible
from both nodes. You can use a directory in an external disk, to store this file.
This directory must be in the cluster configuration to fail over with the SQL Server
instance. You can use automatic expiration in a clustered enviroment, the same
as you can in a standalone configuration. So, if you have different backup policies
for legacy backups, you need to create a different options file. It is necessary to
specify that we are in a cluster environment, so the parameter “CLUSTERNODE
yes” needs to be specified.

See Example 3-14 on page 102 for a daily backup example and Example 3-15
on page 103 for a monthly backup example.

Example 3-14 Options file for daily SQL Backups


NODename clussql01_daily
CLUSTERnode Yes
PASSWORDAccess generate
password mssqldb
COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63
TCPBuffSize 32
COMPRESSIon NO
SCHEDMODE Prompt

INCLUDE "\...\meta\...\*" SQL_DAILY


INCLUDE "\...\data\...\*" SQL_DAILY

102 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

INCLUDE "\...\meta\...\log*" SQL_LOGS


INCLUDE "\...\data\...\log*" SQL_LOGS

EXCLUDE "\...\master\...\log*"
EXCLUDE "\...\msdb\...\log*"

Example 3-15 Options file for Monthly SQL Backups


NODename clussql01_lng
CLUSTERnode Yes
PASSWORDAccess generate
password copper
COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63
TCPBuffSize 32
COMPRESSIon NO
SCHEDMODE Prompt

INCLUDE "\...\meta\...\*" SQL_LONG


INCLUDE "\...\data\...\*" SQL_LONG

EXCLUDE "\...\master\...\log*"

EXCLUDE "\...\msdb\...\log*"

3.2.10 Specifying Data Protection for SQL preferences


Data Protection for SQL configuration parameters are defined in the Data
Protection for SQL configuration file (tdpsql.cfg by default). These configuration
parameters determine such preferences as the location of your log file, how date
and time stamps display, and the number of buffers to use. You can set the
values of the Data Protection for SQL configuration parameters in two ways:
򐂰 Using the menu Edit → Configuration of the Data Protection for SQL GUI.
򐂰 Using the tdpsqlc set command in the Data Protection for SQL Command
Line Interface.

Note the following characteristics of Data Protection for SQL configuration


parameters:

Chapter 3. Installation and configuration 103


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 The value of a configuration parameter specified on a command line


invocation overrides (but does not change) the value of the configuration
parameter specified in the Data Protection for SQL configuration file.
򐂰 During a command line invocation that does not specify an overriding value
for a configuration file parameter, the values in the default Data Protection for
SQL configuration file (tdpsql.cfg) are used.

Set the policy for VSS backups by specifying the VSSPOLICY statement in your
Data Protection for SQL configuration file. Note this parameter can only be set in
the configuration file - it cannot be specified using the tdpsqlc set command or
the menu Edit → Configuration task of the Data Protection for SQL GUI.

VSSPOLICY statements are processed from the bottom up and processing stops
at the first match. To ensure that more specific specifications are processed at
all, the more general specification should be listed before the more specific ones,
so as to be processed after the more specific specifications. Otherwise, the more
general specification will match the target before the more specific specifications
are seen.

By default, SQL Server accepts connections on TCP/IP port 1433. If SQL Server
is configured to listen on a TCP/IP port different than 1433, you must specify the
TCP/IP port for the parameters SQLSERVer and FROMSQLserver.
Example 3-16 shows how to configure Tivoli Data Protection for SQL Server to
access the instance SQL_STDBY on server COPPER using port 5555.

Example 3-16 TDPSQL.cfg parameter file for SQL Server with non default port
SQLSERVer COPPER\SQL_STDBY,5555
FROMSQLserver COPPER\SQL_STDBY,5555

If you do not specify the TCP/IP port when accessing a SQL Server instance
listening on a non default port, you will receive an error messages similar to
Example 3-27.

Figure 3-27 Tivoli Data Protection for SQL connection error

104 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Note: This error can happen when you install SQL Server 2000 and 2005 on
the same machine. In our tests, we installed SQL Server 2000 first and then
SQL Server 2005. Although SQL Server tools were able to connect to both
SQL Server installations, Tivoli Data Protection for SQL Server was able to
connect only to the SQL Server listening on the port 1433, and to solve this
issue was necessary to include the port which SQL Server was listening on
the TDPSQL.cfg configuration file.

You can verify the port which SQL Server is listening using SQL Server tools,
such as the Server Network utility for SQL Server 2000 or SQL Server
Configuration Manager for SQL Server 2005. Another way to verify this
information is to check the SQL Server error log.

Configure Data Protection preferences on a standalone


environment
In a non-clustered environment you can configure the preferences in the default
preferences files located on C:\Program Files\Tivoli\TSM\TDPSQL\tdpsql.cfg. If
you have more than one backup policy, you can create different preferences files.
See Example 3-17 on page 105 and Example 3-18 on page 106.

Example 3-17 Data Protection for SQL configuration file for Daily Backups
(tdpsql_daily.cfg)
SQLSERVer COPPER
FROMSQLserver COPPER
SQLAUTHentication INTegrated
nodename copper_sql
MOUNTWaitfordata Yes
BACKUPMethod LEGACY
DIFFESTimate 20
BUFFers 3
BUFFERSIze 1024
STRIPes 1
SQLBUFFers 0
SQLBUFFERSIze 1024
LOGPrune 60
LANGuage ENU
BACKUPDestination Both
LOCALDSMAgentnode copper_vss
REMOTEDSMAgentnode
********** Server Storage Group Name BU Type BU Dest. Mgmt Class
********** ------ ------------------ ------- -------- ----------
VSSPOLICY * * FULL TSM VSS_FULL_TSM

Chapter 3. Installation and configuration 105


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

VSSPOLICY * * LOCAL LOCAL VSS_LOCAL

Example 3-18 Data Protection for SQL configuration file for Monthly Backups
(tdpsql_long.cfg)
SQLSERVer COPPER
FROMSQLserver COPPER
SQLAUTHentication INTegrated
nodename copper_lng
MOUNTWaitfordata Yes
BACKUPMethod LEGACY
DIFFESTimate 20
BUFFers 3
BUFFERSIze 1024
STRIPes 1
SQLBUFFers 0
SQLBUFFERSIze 1024
LOGPrune 60
LANGuage ENU
BACKUPDestination TSM
LOCALDSMAgentnode copper_vss
REMOTEDSMAgentnode
********** Server Storage Group Name BU Type BU Dest. Mgmt Class
********** ------ ------------------ ------- -------- ----------
VSSPOLICY * * FULL TSM VSS_LONG_TSM

We recommend creating a shortcut for the TDP for SQL GUI pointing to each
options file. You can follow the steps 1-3 described on page 96 to create the
shortcuts.

To create shortcuts for daily and monthly backups you need to specify the
options and configuration file. See example Example 3-19 on page 106 and
Example 3-20 on page 106.

Example 3-19 Shortcut definition for Daily SQL Backup


"C:\Program Files\Tivoli\TSM\TDPSql\tdpsql.exe" /tsmoptfile="C:\Program
Files\Tivoli\TSM\TDPSql\dsm_daily.opt" /configfile="C:\Program
Files\Tivoli\TSM\TDPSql\tdpsql_daily.cfg"

Example 3-20 Shortcut definition for Monthly SQL Backup


"C:\Program Files\Tivoli\TSM\TDPSql\tdpsql.exe" /tsmoptfile="C:\Program
Files\Tivoli\TSM\TDPSql\dsm_long.opt" /configfile="C:\Program

106 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Files\Tivoli\TSM\TDPSql\tdpsql_long.cfg"

Configure Data Protection preferences in a clustered


environment
In a clustered environment the DSMAgent options file for each node in a cluster
was created. Now, it is necessary to configure Data Protection for SQL
preferences for each node in the cluster. You can use a directory in an external
disk, and configure both files, one for each node in the cluster. You need to match
the correspondent LOCALDSMAgentnode according to the specific machine in
the cluster.

If you are using an offloaded backup server, it is necessary to configure the


REMOTEDSMAgent node, pointing to your offloaded node. This parameter is
only required if you are using an offloaded backup server.

This configuration also contains the VSSPOLICY statements, so if you have


more than backup policy it is necessary to specify more than one configuration.
See Example 3-21 on page 107, Example 3-21 on page 107, Example 3-23 on
page 108 and Example 3-24 on page 109.

Example 3-21 Data Protection for SQL configuration file for Daily Backups
(tdpsql_libra_daily.cfg)
SQLSERVer CLUSQL01\SQL01
FROMSQLserver CLUSQL01\SQL01
SQLAUTHentication INTegrated
nodename CLUSQL01_Daily
MOUNTWaitfordata Yes
BACKUPMethod LEGACY
DIFFESTimate 20
BUFFers 3
BUFFERSIze 1024
STRIPes 1
SQLBUFFers 0
SQLBUFFERSIze 1024
LOGPrune 60
LANGuage ENU
BACKUPDestination Both
LOCALDSMAgentnode libra_vss
REMOTEDSMAgentnode leo_offload
********** Server Storage Group Name BU Type BU Dest. Mgmt Class
********** ------ ------------------ ------- -------- ----------
********** ------ ------------------ ------- -------- ----------
VSSPOLICY * * FULL TSM VSS_FULL_TSM

Chapter 3. Installation and configuration 107


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

VSSPOLICY * * LOCAL LOCAL VSS_LOCAL

Example 3-22 Data Protection for SQL configuration file for Monthly Backups
(tdpsql_libra_long.cfg)
SQLSERVer CLUSQL01\SQL01
FROMSQLserver CLUSQL01\SQL01
SQLAUTHentication INTegrated
nodename clusql01_lng
MOUNTWaitfordata Yes
BACKUPMethod LEGACY
DIFFESTimate 20
BUFFers 3
BUFFERSIze 1024
STRIPes 1
SQLBUFFers 0
SQLBUFFERSIze 1024
LOGPrune 60
LANGuage ENU
BACKUPDestination TSM
LOCALDSMAgentnode libra_vss
REMOTEDSMAgentnode leo_offload
********** Server Storage Group Name BU Type BU Dest. Mgmt Class
********** ------ ------------------ ------- -------- ----------
VSSPOLICY * * FULL TSM VSS_LONG_TSM

Example 3-23 Data Protection for SQL configuration file for Daily Backups
(tdpsql_leo_daily.cfg)
SQLSERVer CLUSQL01\SQL01
FROMSQLserver CLUSQL01\SQL01
SQLAUTHentication INTegrated
nodename CLUSQL01_Daily
MOUNTWaitfordata Yes
BACKUPMethod LEGACY
DIFFESTimate 20
BUFFers 3
BUFFERSIze 1024
STRIPes 1
SQLBUFFers 0
SQLBUFFERSIze 1024
LOGPrune 60
LANGuage ENU
BACKUPDestination Both
LOCALDSMAgentnode leo_vss

108 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

REMOTEDSMAgentnode libra_offload
********** Server Storage Group Name BU Type BU Dest. Mgmt Class
********** ------ ------------------ ------- -------- ----------
********** ------ ------------------ ------- -------- ----------
VSSPOLICY * * FULL TSM VSS_FULL_TSM
VSSPOLICY * * LOCAL LOCAL VSS_LOCAL

Example 3-24 Data Protection for SQL configuration file for Monthly Backups
(tdpsql_leo_long.cfg)
SQLSERVer CLUSQL01\SQL01
FROMSQLserver CLUSQL01\SQL01
SQLAUTHentication INTegrated
nodename clusql01_lng
MOUNTWaitfordata Yes
BACKUPMethod LEGACY
DIFFESTimate 20
BUFFers 3
BUFFERSIze 1024
STRIPes 1
SQLBUFFers 0
SQLBUFFERSIze 1024
LOGPrune 60
LANGuage ENU
BACKUPDestination TSM
LOCALDSMAgentnode leo_vss
REMOTEDSMAgentnode libra_offload
********** Server Storage Group Name BU Type BU Dest. Mgmt Class
********** ------ ------------------ ------- -------- ----------
VSSPOLICY * * FULL TSM VSS_LONG_TSM

We recommend creating a shortcut for the TDP for SQL GUI pointing to each
options file. You can follow the steps 1-3 described on page 96 to create the
shortcuts.

To create shortcuts for daily and monthly backups you need to specify the
options and configuration file. See Example 3-25 on page 109, Example 3-26 on
page 110, Example 3-27 on page 110 and Example 3-28 on page 110.

Example 3-25 Shortcut definition for Daily SQL Backup for server Libra
"C:\Program Files\Tivoli\TSM\TDPSql\tdpsql.exe"
/tsmoptfile="E:\tsmdata\dsm_mssqldb_daily.opt"
/configfile="E:\tsmdata\tdpsql_libra\tdpsql_libra_daily.cfg"

Chapter 3. Installation and configuration 109


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Example 3-26 Shortcut definition for Daily SQL Backup for server Leo
"C:\Program Files\Tivoli\TSM\TDPSql\tdpsql.exe"
/tsmoptfile="E:\tsmdata\dsm_mssqldb_daily.opt"
/configfile="E:\tsmdata\tdpsql_libra\tdpsql_leo_daily.cfg"

Example 3-27 Shortcut definition for Monthly SQL Backup for server Libra
"C:\Program Files\Tivoli\TSM\TDPSql\tdpsql.exe"
/tsmoptfile="E:\tsmdata\dsm_mssqldb_long.opt"
/configfile="E:\tsmdata\tdpsql_libra\tdpsql_libra_long.cfg"

Example 3-28 Shortcut definition for Monthly SQL Backup for server Leo
"C:\Program Files\Tivoli\TSM\TDPSql\tdpsql.exe"
/tsmoptfile="E:\tsmdata\dsm_mssqldb_daily.opt"
/configfile="E:\tsmdata\tdpsql_libra\tdpsql_leo_long.cfg"

3.2.11 Configuration on the machine running the Offloaded backups


(VSS Only)
Perform these steps on the machine running the off-loaded backups. In our
configuration, this is MOLITO:
1. Install IBM Tivoli Storage Manager Backup-Archive Client as described in
3.2.5, “Install the backup-archive client code” on page 81.
2. Configure the IBM Tivoli Storage Manager backup-archive client, as shown in
Example 3-29.

Example 3-29 Backup-archive client options file for offloaded machine


NODename molito_offload
PASSWORDAccess generate

COMMMethod TCPip
TCPServeraddress 9.43.86.45
TCPPort 1500
TCPWindowsize 63
TCPBuffSize 32
TCPCLIENTADDRESS 9.43.86.64
clusternode no
clusterdisksonly no
managedservices webclient

110 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

3. Install and configure the IBM Tivoli Storage Manager Client Acceptor Daemon
(CAD) Service and Remote Client Agent Service (DSMAgent). Remember,
that you can use the backup-archive GUI, select Utilities → Setup Wizard →
Help me configure the TSM Web Client. You will configure both services.
See the steps on “Configure the CAD and remote agent services” on
page 112.
4. If in your environment you have a VSS provider (that is not the default system
VSS provider) you need to configure it. Consult the VSS provider
documentation for information regarding configuration of that software.
5. Verify on your Windows services panel, if you have the CAD and remoted
agent started.

3.2.12 Summary of configuration files


As described in earlier chapters, we have a lot of files to configure before starting
to backup SQL databases. The following examples shows the files to configure in
a non-clustered and in a clustered environment. See Figure 3-28 on page 111
and Figure 3-29 on page 112.

C O PPER

MS SQ L
Server

Local DSM Agent (B A options file):


BA Client C:\Program files\Tivoli\TS M \baclient\dsm _v ss.opt
O ptional O ffloaded Server

Data Protection options file (Daily Configuration):


C:\P rogram files\Tivoli\TSM\TDPSQ L\dsm _daily.opt

BA C lient
Data P rotection config file (Daily Configuration):
C:\P rogram files\Tivoli\TSM\TDPSQ L\tdpsql_daily.cfg
Data
Protection
for SQ L Local DSM Agent (B A options file):
Data Protection options file (M onthly Configuration): C:\P rogram files\Tivoli\TSM \baclient\dsm _v ss.opt
C:\P rogram files\Tivoli\TSM\TDPSQ L\dsm _long.opt

Data Protection config file (Monthly Configuration):


C:\P rogram files\Tivoli\TSM\TDPSQ L\tdpsql_long.cfg

Figure 3-28 Summary configuration files in a standalone environment

Chapter 3. Installation and configuration 111


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

libra leo
MS SQL
Server

Loc al DSMAgent (BA options file): Loc al DSMAgent (BA options file):
BA Clie nt E:\ts mdata\ds m_libra_vss .opt E:\tsmdata\ds m_leo_vs s .opt BA Clie nt

Data Protection options file (Daily Configuration):


E:\ ts mdata\dsm_c luss ql01_daily.opt

Data Data
Protection Data Protection options file (Monthly Configuration): Protection
for SQL E:\ ts mdata\ds m_c luss ql01_long.opt for SQL

Data Protection config file (Daily Configuration): Data Protection config file (Daily Configuration):
E:\ ts mdata\tdps ql_libra_daily .c fg E:\ tsmdata\tdps ql_leo_daily .c fg

Data Protection config file (Daily Configuration): Data Protection config file (Daily Configuration):
E:\ ts mdata\tdps ql_libra_long.cfg E:\ ts mdata\tdps ql_leo_long.c fg

Loc al DSMAgent (BA options file):


BA Clie nt C:\Program files \Tiv oli\TSM\bac lient\ds m_vs s .opt

Op tional Offloa ded Serv er

Figure 3-29 Summary configuration files in a clustered environment

3.2.13 Configure the CAD and remote agent services


It is necessary to configure the client acceptor (CAD) and remote agent services
for the local DSMAgent node in order to permit communication between the Data
Protection for SQL and backup-archive client and IBM Tivoli Storage Manager.

You can use either IBM Tivoli Storage Manager backup-archive setup wizard or
dsmcutil to perform these tasks.
1. From the backup-archive GUI, select Utilities → Setup Wizard
2. The screen TSM Client Configuration Wizards appears. Select the option
Help me to configure the TSM Web Client. See Figure 3-30 on page 113.

112 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-30 TSM Client Configuration Wizard

3. Select the option Install a new Web client agent and click Next. See
Figure 3-31 on page 113.

Figure 3-31 Select “Install a new Web client agent”

4. Select the name of the TSM acceptor and click Next. Figure 3-32 on
page 114.

Chapter 3. Installation and configuration 113


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-32 Select the name of the TSM acceptor

5. Select the options file and location and click Next. See Figure 3-33 on
page 114

Figure 3-33 Select options file

6. Choose the HTTP Port and click Next. See Figure 3-34 on page 115.

114 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-34 HTTP Port

7. Fill in the nodename and password information for the backup-archive node.
See Figure 3-35 on page 115.

Figure 3-35 TSM authentication

8. Select to use the System Account, if you want to use a specific user you can
fill this account with user name and the password. Configure the service to
start automatically. See Figure 3-36 on page 116.

Chapter 3. Installation and configuration 115


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-36 Service login options

9. Choose the Remote Agent service name. See Figure 3-37 on page 116.

Figure 3-37 Choose Web services name

10.Select No to revoke the remote access privileges to the Web Client. See
Figure 3-38 on page 117.

116 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

Figure 3-38 Web client parameters

11.Select Yes to start this service now. See Figure 3-39 on page 117.

Figure 3-39 Immediate start option

12.On the completion screen click Finish. See Figure 3-40 on page 118.

Chapter 3. Installation and configuration 117


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 3-40 Completing TSM Client Configuration Wizard

Note: In a clustered environment you can create a service to manage the


CAD service as a cluster resource. So, in step 8, configure Manually when I
explicity the service to start, and in step 11, configure No so that the
service does not start immediately.

3.2.14 Configure the proxy node definitions


It is necessary to configure proxy node definitions when you intend to have VSS
Backups. Configure proxy authority enables you to grant proxy authority to a
client node on the IBM Tivoli Storage Manager server. Target client nodes own
the data and agent nodes act on behalf of the target nodes. When granted proxy
authority to a target client node, an agent node can perform backup and restore
operations for the target node. Data that the agent node stores on behalf of the
target node is stored under the target node's name in server storage.

The DSMAgent is used as an agent node. The options file (dsm.opt) created for
the backup-archive client is used as the DSMAgent. And the target node is the
owner of the backups. In Example 3-30 on page 118, we can see a GRANT PROXY
command for two nodes, because we have two different backup policies for this
SQL Server node, in a standalone configuration.

Example 3-30 Proxy authority


tsm: ZAIRE>GRANT PROXYNODE target=copper_sql agent=copper_vss

118 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-3-install.fm

tsm: ZAIRE>GRANT PROXYNODE target=copper_lng agent=copper_vss

Example 3-31 on page 119 shows the GRANT PROXY commands required in the
clustered environment, with two different backup policies.

Example 3-31 Proxy authority in a clustered environment


tsm: ZAIRE>GRANT PROXYNODE target=clusql01_daily agent=libra_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_lng agent=libra_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_daily agent=leo_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_lng agent=leo_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_daily agent=libra_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_lng agent=libra_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_daily agent=leo_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_lng agent=leo_vss

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_daily agent=molito_offload

tsm: ZAIRE>GRANT PROXYNODE target=clusql01_lng agent=molito_offload

3.2.15 The Hardware Provider


To support VSS Instant Restore it is necessary to configure the hardware
provider. You need to check if the hardware is supported by IBM Tivoli Storage
Manager for Copy Services at this web site:

http://www-1.ibm.com/support/docview.wss?&uid=swg21269169.

Your hardware provider process installation depends on your disk hardware type.

The following steps are performed by the Microsoft VSS in conjunction with
FlashCopy when a backup application initiates a request for a backup on an IBM
disk system (SVC, DS6000 or DS8000):
򐂰 VSS retrieves a list of volumes from the storage system and selects
appropriate target volumes from the free pool (VSS_FREE)

Chapter 3. Installation and configuration 119


6148ch-3-install.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 VSS moves the target volumes to the reserved pool (VSS_RESERVED) and
the SQL Server databases suspends writes.
򐂰 VSS issues a FlashCopy from the source volumes to the target volumes. The
FlashCopy is performed on the hardware under the direction of the VSS
hardware provider. The FlashCopy is made as a transportable nonpersistent
snapshot.
򐂰 The database resumes writes after the FlashCopy is complete. The SQL
Server now has no further involvement in the operation.
򐂰 VSS assigns the target volumes to the offloaded server’s HBAs. Microsoft
Windows mounts the volumes on the offloaded server.
򐂰 The VSS requestor reads the data from the target volumes and copies it to
IBM Tivoli Storage Manager server storage.
򐂰 Once the backup to IBM Tivoli Storage Manager is complete, Microsoft
unmounts the volumes and VSS unassigns the target volumes from the
backup server’s HBAs.
򐂰 VSS assigns the target volumes back to the free pool (VSS_FREE).
򐂰 They are available for use in other VSS operations.

For more information refer to DS Open Application Programming Interface 5.3


Installation and Reference, Chapter 9. You can find this manual at the following
website:

http://www-1.ibm.com/support/docview.wss?uid=ssg1S7001160&aid=1.

120 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Chapter 4. Data Protection for SQL


Server backup
In this chapter we discuss how to use the Data Protection for SQL Server
graphical user interface (GUI) and command line interface (CLI) to backup SQL
Server databases.

This chapter covers the following:


򐂰 4.1, “GUI overview” on page 122
򐂰 4.2, “Legacy GUI backups” on page 135
򐂰 4.3, “VSS GUI backups” on page 144
򐂰 4.4, “Working with existing backups with GUI” on page 148
򐂰 4.5, “CLI overview” on page 153
򐂰 4.6, “Legacy CLI backups” on page 155
򐂰 4.7, “VSS CLI backups” on page 165
򐂰 4.8, “Working with existing backups with CLI” on page 167

© Copyright IBM Corp. 2008. All rights reserved. 121


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

4.1 GUI overview


The Data Protection for SQL Server GUI consists of a main window with the
following elements:
򐂰 Common menu bar
򐂰 Toolbar
򐂰 Backup databases tab
򐂰 Backup groups/files tab
򐂰 Restore database tab
򐂰 Restore groups/files tab
򐂰 Inactivate tab

Note: By default, the Inactivate tab is not displayed in the main window. To
display the Inactivate tab you must check the option Inactivate tab in the
View menu bar option.

The backup and restore windows contain a directory tree and operation controls.

Figure 4-1 shows the Data Protection for SQL Server GUI. We describe how to
launch the GUI in 4.1.3, “Launching the GUI” on page 133. Because we have
installed Tivoli Storage Manager for Copy Services, the VSS Backup option is
available for selection. If it was not installed, the option would be grayed out.

122 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Figure 4-1 Data Protection for SQL Server GUI

4.1.1 Menu bar


The Data Protection for SQL Server menu bar has these itens and menu list
functions:
򐂰 File
Exit Data Protection for SQL Server GUI Tool
򐂰 Edit
Edit Data Protection for SQL Server configurations. The default configuration
settings are contained in the tdpsql.cfg file.
򐂰 View
Refresh the tree window and display the Inactivate tab.
򐂰 Utilities
Change the Tivoli Storage Manager password, set SQL Server login
information, or show server information for both the Tivoli Storage Manager
server and the SQL Server.
򐂰 Help

Chapter 4. Data Protection for SQL Server backup 123


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Obtain Data Protection for SQL help to assist with GUI tasks, Tivoli Storage
Manager Web access, and information about Data Protection for SQL.

Edit menu
Use the Edit menu to change Data Protection for SQL configuration settings.

You can modify the Data Protection for SQL Server configuration file. If a
configuration file was not specified on launching the GUI tool, the file tdpsql.cfg is
used. If no configuration file is found, a default file is created which contains all
the default settings for the parameters, except for LASTPRUNEDATE value. To
specify a different configuration file, start the GUI from the command line with the
/configfile parameter.

Click Configure under Edit to display the Data Protection for SQL Settings dialog
with the following five tabs and their parameters:

General tab
This tab displays the preferences page for general configuration parameters.

The General tab is shown in Figure 4-2.

Figure 4-2 General tab

In this tab you can modify the following settings:


򐂰 SQL Server
Specifies the SQL server that Data Protection for SQL logs on to.
򐂰 From SQL Server
Specifies the SQL server that backup objects were backed up from. This
parameter is necessary only when the name of the SQL server to restore to,
as determined by the SQL Server parameter, is different from the name of the
SQL server that the backup objects were created from.

124 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Note: By default, SQL Server listens on TCP/IP port 1433. If the SQL Server
is listening on a TCP/IP port other than 1433, you must explicitly configure it
for the SQL Server and From SQL Server parameters above. For more
information, see 3.2.10, “Specifying Data Protection for SQL preferences” on
page 103.

򐂰 SQL Authentication
Specifies the authorization mode used when logging on to the SQL server.
– Integrated (default)
Specifies to use a trusted connection and allow Windows to authenticate
the logon.
– SQL User ID
Specifies to use SQL User ID security. With this type of security, the
administrator provides the logon ID and the password to logon to Data
Protection for SQL.
򐂰 Wait for Tape Mounts for Backup or Restore
Check this box if you want Data Protection for SQL Server to wait for tape
media (if used) to be mounted for backup and restore operations. When
backups are stored on tape, it is likely that backup and restore operations will
need to wait until the required tape volume mounts.
This setting specifies whether Data Protection for SQL Server should wait for
the media mount or stop the current operation. Wait for tape mounts is the
default, which is usually appropriate in an environment with an automated
tape library. This option is only used on legacy operations.
򐂰 Use VSS Backup as the default Backup method
Check this box to set VSS Backups as the default backup method. This
parameter is grayed out if the Tivoli Storage Manager for Copy Services
Microsoft SQL VSS Integration Module is not installed. Remember that VSS
backups can only be restored using VSS. If you use VSS as the default, the
Local DSMAGENT Node name parameter must be specified (as shown in
Figure 4-6, “VSS Backup tab” on page 129).
򐂰 Estimate % Change for Differential Backup
Specifies the value for the estimated change to database pages for differential
backups. This estimate is used by Data Protection for SQL to determine if
sufficient storage space is available for the backup. The value specified here
becomes the default value for all differential backups.

Chapter 4. Data Protection for SQL Server backup 125


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Performance tab
This tab displays the preferences page for performance configuration
parameters. The Performance tab is shown in Figure 4-3.

Figure 4-3 Performance tab

In this tab you can configure the following settings:


򐂰 DP Buffers (3 by default)
Specifies the number of communication data buffers Data Protection for SQL
uses when transferring data between Data Protection for SQL and the Tivoli
Storage Manager server. Each buffer is the size specified by the TDP Buffer
Size option. Note that this option applies to Legacy backups only.
򐂰 DP Buffer Size (1024 by default)
Specifies the size of the buffers used by Data Protection for SQL to transfer
data to the Tivoli Storage Manager server. Note that this option applies to
Legacy backups only.
򐂰 Stripes (1 by default)
Specifies the number of data stripes (1 to 64) to use in a Legacy backup or
Legacy restore operation. The default value is 1. Note that VSS operations do
not support multiple stripes. As a result, the default value for VSS operations
is 1.
򐂰 SQL Buffers (0 by default)
Select a number (0 to 999 ) that specifies the number of communication data
buffers Data Protection for SQL uses when transferring data between the
SQL Server and Tivoli Storage Manager server. Each buffer is the size
specified in the TDP Buffer Size option.
򐂰 SQL Buffer Size (1024 by default)

126 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Select a number (64 to 4096) that specifies the size of the buffers used by
Data Protection for SQL to transfer data from the SQL Server to Data
Protection for SQL.

Logging
This tab displays the preferences page for logging configuration parameters. The
Logging tab is shown in Figure 4-4.

Figure 4-4 Logging tab

In this tab you can configure the following settings:


򐂰 Log File Name (tdpsql.log by default)
Specifies the name of the file where you want Data Protection for SQL to write
activity log information.
򐂰 Prune Old Entries (selected by default)
Check this box to enable pruning of the activity log.
– Number of days to keep (60 by default)
Use this field to specify the number of days (0 to 9999) worth of entries to
keep in the activity log. Data Protection for SQL prunes entries greater
than this number when you initialize this application.
– Prune Now
Click Prune Now to prune the activity log immediately.

Regional
This tab displays the preferences page for regional configuration parameters.
The Regional tab is shown in Figure 4-5.

Chapter 4. Data Protection for SQL Server backup 127


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 4-5 Regional tab

In this tab you can configure the following settings:


򐂰 Language (American English by default)
Specify the language to use for displaying the GUI and Data Protection for
SQL messages. You can select from the following:
– English (United States) (This is the default).
– Brazilian Portuguese
– Chinese (Simplified)
– Chinese (Traditional)
– French
– German
– Italian
– Japanese
– Korean
– Spanish
The language you specify does not become effective until you exit and restart
the GUI.

Note: To use a non default language you must install the corresponding
language pack . See “Installing Data Protection for SQL additional language
packs” on page 90 for the installation procedure.

򐂰 Date Format (mm/dd/yyyy by default)


Click one of the following buttons for the date format of your choice.
– dd: Day of the Month
– mm: Month of the Year
– yyyy: YearTime Format (hh:mm:ss by default)
򐂰 Time Format (hh:mm:ss by default)

128 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Click one of the Time Format buttons to select a format for displaying time.
– hh: Hours (24-hour day)
– mm: Minutes in an hour
– ss: Seconds in a minute
򐂰 Number Format (xxx,xxx.dd by default)
Click one of the Number Format buttons to select a format for displaying
numbers. The choices on the display represent several ways to place the
decimal, comma, and spaces.

VSS Backup
This tab displays the preferences page for VSS Backup configuration
parameters. The VSS Backup panel is shown in Figure 4-6.

Figure 4-6 VSS Backup tab

In this tab you can configure the following settings:


򐂰 Default Backup Destination (TSM server by default)
Select the default storage location for your backups. You can select from the
following storage locations:
– TSM Server
The data is stored on Tivoli Storage Manager server storage only. This is
the default.
– Local
The backup is stored on local VSS disk only.
– Both
The backup is stored on both Tivoli Storage Manager server storage and
local VSS disk.Note that this parameter is only valid when using the VSS
Backup method.

Chapter 4. Data Protection for SQL Server backup 129


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Local DSMAGENT Node name (blank by default)


Specify the Tivoli Storage Manager node name (agent node) of the local
client machine that performs VSS operations and moves the VSS data from
local shadow volumes to Tivoli Storage Manager server storage during Tivoli
Storage Manager server backups. This parameter must be specified for VSS
operations to be performed. See Chapter 5, “Data Protection for SQL Server
restore” on page 171 for instructions on how to configure this node.
򐂰 Remote DSMAGENT Node name (blank by default)
Specify the Tivoli Storage Manager node name (agent node) of the remote
client machine that moves the VSS data from local VSS disks to Tivoli
Storage Manager server storage during off-loaded backups. This option is
only required if you are using an off-loaded backup server. See Chapter 3,
“Installation and configuration” on page 69 for instructions on how to configure
this node.

View menu
The view menu gives you the following options:
򐂰 Refresh tree view
By refreshing the GUI, you can:
– clear any selections.
– collapse the tree to the level you have highlighted.
– collapse corresponding tab trees even if they are not currently displayed
(e.g., refreshing the Backup Databases tree also refreshes the Backup
Groups/Files tree)
– display new backup operations in the restore trees.

Note: If you simply move back and forth between tabs without refreshing, the
current selections or tree view are kept.

򐂰 Inactivate tab
Click this item to add the tab control to the backup and restore windows,
allowing you to inactivate SQL databases in Tivoli Storage Manager storage.

Utilities menu
The Utilities menu provides you the following options:
򐂰 Change TSM Password
This dialog prompts you to enter the old password, then enter the new
password twice, in order to verify the new password.

130 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

򐂰 SQL Server login settings


The SQL Server Login Information dialog allows you to select the following:
– Use Windows Authentication (selected by default)
– Use SQL Authentication; if you select this option, you need to fill in a user
id (sa by default) and password (blank by default).
Figure 4-7 on page 131 shows the SQL Server Login Information screen.

Figure 4-7 SQL Server Login Information

Note: SQL Server login permission requirements for Data Protection for SQL
Server is discussed in 2.5.4, “Data Protection for SQL Server security
considerations” on page 63.

򐂰 Show TSM server information


This window displays the following Connection Information:
– Nodename
– Server Network Host Name
– Tivoli Storage Manager API Version
– Server Name
– Server Type
– Server Version
– Compression Mode
– Domain Name
– Active Policy Set
– Default Management Class
Figure 4-8 on page 132 shows the tivoli Storage Manager server information
screen.

Chapter 4. Data Protection for SQL Server backup 131


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 4-8 TSM Server information

򐂰 Show MS SQL Server information


This window displays the following SQL Server information:
– SQL Server Name
– Version
– Cluster

Help Menu
The Help Menu provides:
򐂰 Data Protection for SQL Help
This dialog launches online help.
򐂰 TSM Web Access
This dialog launches a Web browser to view Tivoli Storage Manager
information online.
򐂰 About Data Protection for SQL
This dialog launches version, release, and modification level information
about Data Protection for SQL.

4.1.2 Toolbar
The toolbar provides shortcuts to frequently used items, such as:
򐂰 Refresh tree view
򐂰 Edit Data Protection for SQL configuration
򐂰 Access Tivoli Storage Manager Web links

132 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

4.1.3 Launching the GUI


To launch the GUI, navigate Start → Programs → Tivoli Storage Manager →
Data Protection For Microsoft SQL Server → SQL Client GUI.

Alternatively, you can use the tdpsql command from the installation directory,
which can take the following parameters:
򐂰 configfile
If specified, this parameter overrides the default Data Protection for SQL
Server configuration file - tdpsql.cfg in the installation directory. Otherwise, the
default configuration file is used.
For example, to specify a configuration file, file.cfg, located in the \temp\test
directory when invoking the GUI, enter:
tdpsql /CONFIGfile=c:\temp\test\file.cfg
򐂰 sqlserver
If specified, this parameter overrides the default SQL Server, which is the
local SQL server. You must use this switch to access SQL Server named
instances and SQL Server clustered instances.
For example, to access a SQL Server named instance SQLNAMED1 on
server Copper, invoke the Data Protection for SQL Server GUI as:
tdpsql /sqlserver=Copper\SQLNAMED1
򐂰 tsmoptfile
If specified, overrides the default Tivoli Storage Manager API option file
(dsm.opt). For example, to specify the file.opt option file located in the
\temp\test directory, enter:
tdpsql /TSMOPTFile=c:\temp\test\file.opt

If you need to specify non-default options, as if for example you are in a clustered
environment, we recommend customizing a shortcut for launching the GUI, as
shown in “Configure Data Protection options file in a clustered environment” on
page 102

4.1.4 Backup and restore windows


Data Protection for SQL offers separate windows for backup and restore
operations, each with its own tree, list, and tab controls.

Considerations
The following are some considerations:

Chapter 4. Data Protection for SQL Server backup 133


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Both legacy and VSS operations are performed from the same tab.
򐂰 When the GUI starts, the backup window is the initial display.
򐂰 Different types of backup and restores are available in different tabs.
򐂰 VSS-related features are grayed out unless the Tivoli Storage Manager for
Copy Services MS SQL VSS Integration Module is installed.
򐂰 After you install Tivoli Storage Manager for Copy Services, the VSS backup
becomes the default type for SQL backups. You can modify it changing the
checkbox “Use VSS Backup as the default Backup method”, as discussed in
“General tab” on page 124.
򐂰 You cannot close, minimize or move the backup or restore windows
independently of the main window.

Expanded backup options


You must use different Data Protection for SQL Server tabs to perform different
types of backup operations. For each tab, a different view of the backup and
restore window will be displayed in the right pane. According to the selected tab,
you can use different selectable units to perform the operations. For example, in
the Backup databases tab, the lowest level of SQL Server structure you can
choose is the database, while in the Backup Group/Files tab you can choose to
back up a specific file or filegroup.

Table 4-1 describes the available tabs, and what type of backup and restore is
available in each tab.

Table 4-1 Data Protection backup and restore tabs

Tab Selection Function Lowest selectable unit

Backup Databases Perform full, differential and log backups Database

Backup Group/Files Perform group, file and set backups Filegroup or file

Restore databases Restore from full, differential and log backups Database, differential
and log

Restore group / files Restore from full, group, file, set, and log Filegroup, file or set
backups. backup

Inactivate tab Manually inactivate selected objects apart Tivoli Storage Manager
from automated inactivation backup object

Highlighting and selecting


When an item is highlighted in the Tree, information about all the items one level
under the highlighted item are displayed in the List View; for example:

134 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

򐂰 If a database is highlighted in the Backup Groups/Files, the filegroups and


transaction log for that database are displayed in the List View.
򐂰 If a database is highlighted in the Restore Tree, all full and differential
database and log backups for that database are displayed in the List View.
򐂰 If a database is highlighted in the Restore File/Groups, all full, differential,
group, file and set backups for that database are displayed in the List View.

To select an item for backup or restore, check the square selection box on the left
of the item name. Checking a selection box in the Tree also highlights the item,
and displays associated information in the List View.

Double-click a selection box in the Tree to select that item and collapse or expand
the Tree at that point. An item can be selected from both the Tree and the List
View.

4.2 Legacy GUI backups


In this section we discuss how to perform SQL Server backups using Data
Protection for SQL Server GUI tool. In the next examples, it is expected that you
have already installed and configured Data Protection for SQL, launched the
Data Protection for SQL Server GUI as explained in 4.1.3, “Launching the GUI”
on page 133, and expanded the SQL Server tree on the left pane. All backup
scenarios are performed starting at this point.

4.2.1 Full database backups


To perform a full backup of a database, execute the following steps:
1. Select the Backup Databases tab.
2. In the left pane, choose the databases to back up. If you want to backup all
databases for the SQL Server instance, choose the SQL Server instance
name, and automatically all databases under this instance will be selected.
3. In the Backup Options section, choose the Legacy Backup radio button, and
the number of stripes for this backup.
4. In the Backup Type drop-down menu, choose Full.
5. Click Backup to start the backup.

Figure 4-9 on page 136 shows how to select all databases in a SQL Server
instance for a full backup.

Chapter 4. Data Protection for SQL Server backup 135


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 4-9 Legacy full backup

The backup progress will be displayed as shown in Figure 4-10.

Figure 4-10 Database operation progress

After the backup is complete, the Backup Progress window indicating whether or
not the operation completed successfully and the object(s) backed up with
detailed status information is displayed, as shown in Figure 4-11. Click OK to
finish. If any error message is displayed, it means that the backup has failed.

136 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Figure 4-11 Backup complete message

4.2.2 Transaction log backups


Performing a transaction log backup is very similar to a full database backup. The
difference is that you must choose Log instead of Full in the Backup Type
drop-down menu . When you choose this option, in the Backup Options section,
the options Truncate Log and Log Est % Chg become available for you change
their configuration. Unless you are performing a tail-log backup, we recommend
that you do not uncheck Truncate Log, otherwise the transaction log file will not
be truncatde when the transaction log backup finishes, allowing the transaction
log to consume all disk space available.

Note: An example of tail-log backup is shown in 4.2.7, “Tail-log backups” on


page 143.

The Log Est % Chg spin box allows you to estimate the percentage of database
pages that have changed due to non-logged operations since the last log backup.
The default is 0.

All databases that cannot have a transaction log backup due to the simple
recovery model or truncate log on checkpoint option active are displayed with an
“X” on the left pane, so that you cannot choose these databases to perform a log
backup.

Figure 4-12 on page 138 shows an example of how to select a database for log
backups. In our example, we select the SalesDB database to perform transaction
log backup. Note that several databases on the left pane are marked with an “X”,
such as master and msdb databases. You are not allowed to perform transaction
log backups for these databases.

Chapter 4. Data Protection for SQL Server backup 137


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 4-12 Legacy transaction log backup

Click Backup to start the backup operation. The Backup Progress window is
displayed to inform you whether or not the operation completed successfully and
lists the object(s) backed up with detailed status information.

4.2.3 Differential backups


Performing a full differential backup is similar to full and transaction log backups.
You must click on the Backup Databases tab, and select Differential in the
Backup Type drop-down menu. The parameters Stripes and Diff Est % Chg
become available for you to customize your backup operation. The parameter
Diff Est % Chg assumes the value specified in “Estimate % Change for
Differential Backup” , as discussed in “General tab” on page 124. It is used to
estimate the percentage of database pages that have changed since the last full
backup.

Figure 4-13 on page 139 shows an example of a differential backup.

138 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Figure 4-13 Legacy differential backup

Click Backup to start the backup operation. The Backup Progress window is
displayed to inform you whether or not the operation completed successfully and
lists the object(s) backed up with detailed status information.

4.2.4 Group backups


While for full, log and differential backups you use the Backup Databases tab, for
filegroup, file and set backups you use the Backup Groups/Files. To perform a
group backup:
򐂰 Select the Backup Groups/Files tab.
򐂰 Select the Group radio box in Backup Type section.
򐂰 Select the number of stripes in Backup Options section.
򐂰 On the left pane, expand the SQL Server tree to display the list of databases.
Note that, as for transaction log backups, neither databases using the simple
recovery model nor with truncate log on checkpoint active are available for
selection. You can identify those databases not available for group backups by
the “X” on its checkbox.

Chapter 4. Data Protection for SQL Server backup 139


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 On the left pane, click on the database you want to backup. The existing
filegroups for the database will appear under the database name, and also on
the right pane.
򐂰 Select the filegroups you want to back up. Note that when you highlight the
filegroup. the files belonging to this filegroup are listed on the List View in the
right pane. However, you cannot select the file individually; if you select a file,
all filegroup will be selected.
򐂰 You can select several filegroups on the same database, or filegroups on
different databases repeating the last step.

Figure 4-14 on page 140 shows an example of group backup. In this example, we
are backing up the SalesDB_LA filegroup of the SalesDB database.

Figure 4-14 Legacy group backup

Click Backup to start the backup operation. The Backup Progress window is
displayed to inform you whether or not the operation completed successfully and
lists the object(s) backed up with detailed status information.

Note: We recommend you to follow group backups with transaction log


backups for all SQL databases you back up.

140 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

4.2.5 File backups


Peforming a file backup is similar to a group backup. On the right pane, click the
Backup Groups/Files tab, select the File radio box in the Backup Type section,
and choose the number of stripes. On the left pane, expand the tree to select the
files you want to back up. In comparison to a group backup, in a file backup you
can choose individually the files to back up on the left pane, while in the group
you choose the filegroup itself, and back up all files belonging to the filegroup.
Note that when you highlight the filegroup on the left pane, the files belonging to
this filegroup are listed on the List View in the right pane, and for file backups you
can individually select any file belonging to the filegroup.

Figure 4-15 on page 141 shows an example of file backup. In this example, only
the file SalesDB_LA_1 is backed up. All other files from the SalesDB_LA
filegroup are not included in this backup.

Figure 4-15 Legacy file backup

Click Backup to start the backup operation. The Backup Progress window is
displayed to inform you whether or not the operation completed successfully and
lists the object(s) backed up with detailed status information.

Chapter 4. Data Protection for SQL Server backup 141


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Note: We recommend you to follow file backups with transaction log backups
for all SQL databases you back up.

4.2.6 Set backups


Performing a set backup is similar to group or file backups. On the right pane,
click the Backup Groups/Files tab, select the Set radio box in the Backup Type
section and choose the number of stripes in the Backup Options section, On the
left pane, choose what SQL Server files and filegroups you will be back up.

Figure 4-16 on page 142 shows an example of a set backup. In this example the
filegroup SalesDB_EMEA and the file SALESDB_LA_2 from the filegroup
SalesDB_LA are backed up.

Figure 4-16 Legacy set backup

142 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Click Backup to start the backup operation. The Backup Progress window is
displayed to inform you whether or not the operation completed successfully and
lists the object(s) backed up with detailed status information.

Note: We recommend you to follow set backups with transaction log backups for all SQL
databases you back up.

4.2.7 Tail-log backups


A tail-log backup is similar to a transaction log backup. The only difference is that
you must remove the checkbox Truncate Log in the Backup Options section.

Figure 4-17 on page 143 shows an example of tail-log backup. Note that the
truncate log checkbox is unchecked.

Figure 4-17 Legacy tail-log backup

Click Backup to start the backup operation. The Backup Progress window is
displayed to inform you whether or not the operation completed successfully and
lists the object(s) backed up with detailed status information.

Chapter 4. Data Protection for SQL Server backup 143


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Note: Tail-log backups are intended only for special situations. Refer to 2.4.4,
“Backup a transaction log without truncate the log” on page 51 for more
information.

4.3 VSS GUI backups


With Data Protection for SQL Server you can only perform full VSS backups. Two
types of VSS backups are available with Data Protection for SQL Server:
򐂰 VSS full backup
򐂰 VSS off-loaded full backup

In the following sections we discuss how to perform GUI backups using both VSS
backup types.

4.3.1 VSS GUI full backup


To perform a full VSS backup:
1. Make sure a Local DSMAGENT Node name is specified and correctly
configured. See “VSS Backup” on page 129 for more information.
2. In Data Protection for SQL Server GUI, click the Backup Databases tab.
3. In the left pane, choose the databases to back up. If you want to backup all
databases for the SQL Server instance, choose the SQL Server instance
name, and automatically all databases under this instance will be selected.
4. In the right pane, select the VSS Backup radio box in the Backup Options
section, and choose the VSS Backup Destination. The VSS Backup
Destination can be:
– Both: The backup will be performed to local disk and TSM Server.
– Local: The backup will be performed only in local disks.
– TSM Server: The backup will be performed only in TSM Server.
5. Click Backup to start the backup.

Figure 4-18 on page 145 shows an example of VSS full backup selection for all
databases in a SQL Server instance. Note that only the full backup option is
available.

144 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Figure 4-18 VSS full backup

After you click Backup, the following activities are performed by Data Protection
for SQL Server:
1. A connection to the local DSM agent is established, as shown in Figure 4-19
on page 145.

Figure 4-19 Connection to Local DSM Agent for VSS backup

Chapter 4. Data Protection for SQL Server backup 145


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

2. After a connection to Local DSM Agent is established, Data Protection for


SQL Server queries the Local DSM Agent to gather information about VSS
configuration, as shown in Figure 4-20 on page 146.

Figure 4-20 Querying VSS Information on local DSM agent node

3. Then the VSS backup of the selected databases is started, as shown in


Figure 4-21.

Figure 4-21 Start of VSS backup operation

4. The VSS backup operation progress is reported in Backup Progress window.


When the backup finishes, a report with VSS backup results is displayed, as
shown in Figure 4-22 on page 147.

146 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Figure 4-22 VSS backup report

4.3.2 VSS GUI off-loaded backup


An off-loaded backup uses an alternate machine to move SQL data to Tivoli
Storage Manager server storage. This may reduce the impact on network, I/O,
and CPU resources during backup processing.

Performing a VSS GUI off-loaded backup is very similar to a normal VSS GUI
backup. The differences are that you must configure the
REMOTEDSMAgentnode parameter in the Data Protection for SQL Server
configuration file (tdpsql.cfg by default) using either the Configuration task in the
Edit Menu of the GUI or the tdpsqlc set command,. Then, in the Backup
Databases tab, choose the Backup Destination listbox as TSM Server
(offloaded), as shown in Figure 4-23.

Chapter 4. Data Protection for SQL Server backup 147


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 4-23 VSS GUI off-loaded backup selection

4.4 Working with existing backups with GUI


With the Data Protection for SQL Server GUI, you can display information about
existing backups, and manually inactivate backups.

This section covers:


򐂰 Displaying existing backups
򐂰 Inactivating legacy backups

4.4.1 Displaying existing backups using GUI


You can use the Restore Databases tab and the Restore Groups/Files tab to list
the existing Legacy and VSS backups for a SQL Server instance, The Restore
Databases tab displays full, differential and log backups, and Restore
Groups/Files tab displays full, log, groups, file and set backups.

Figure 4-24 on page 149 shows an example of backups displayed in the Restore
Databases tab for the SalesDB database.

148 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Figure 4-24 List database backups in the Restore databases tab

Figure 4-25 on page 149 shows an example of the backups displayed in the
Restore Groups/File tab for the SalesDB database.

Figure 4-25 List databases backups in the Restore Groups/Files tab

Chapter 4. Data Protection for SQL Server backup 149


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

By default, only active backups are displayed. To display both active and inactive
backups, check Show Active and Inactive.

Figure 4-26 on page 150 shows both active and inactive backups for the
SalesDB database.

Figure 4-26 Displaying inactive backups

4.4.2 Inactivating backups using GUI (Legacy only)


Data Protection for SQL Server GUI tool allows you to inactivate all active
objects, all objects of a particular backup type, or specific objects.

Only the backups taken since the last full backup are considered to be active.
When you perform a legacy full database backup, all backups taken since the
previous full backup are automatically inactivated. This does not mean they
cannot be used anymore to restore your databases. You can still use an inactive
backup as long as it is not expired from the Tivoli Storage Manager inventory.
Once a backup has been expired from the Tivoli Storage Manager inventory, it
can no longer be used in a restore operation. Other backup types also inactivate
previous backups, as can be seen in Table 4-2.

150 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Table 4-2 Automatic inactivation by backups

Backup type What it inactivates

Legacy full backup All prior active backup objects for the same SQL database

Legacy differential backup All differential backups taken since the last full backup for
the same SQL database

Legacy log backup Does not inactivate any backup

Legacy group backup All group backups taken since the last full backup for the
same filegroup for the same SQL database

Legacy file backup All file backups taken since the last full backup for the same
file for the same SQL database

Legacy set backup Does not inactivate any backup

Tivoli Storage Manager never expires the active backup. If you drop an SQL
Server database, its active backup will remain in the Tivoli Storage Manager
Server inventory until it is manually inactivated, and then expired. The space
allocated for this backup also will not be deallocated from Tivoli Storage Manager
Server.

In fact, when you inactivate a backup you just select it to participate in Tivoli
Storage Manager expiration processing. Typical backups do not require this
command as Data Protection for SQL Server performs inactivation as a part of
Tivoli Storage Manager policy management. As a result, backup objects are
typically inactivated as part of the scheduled backup processing.

Note: You must manually enable the Inactivate tab. See “View menu” on
page 130 for more information.

Figure 4-27 on page 152 shows the inactivate tab. In the next example, we
selected all backups on SalesDB to be inactivated.

Chapter 4. Data Protection for SQL Server backup 151


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 4-27 Inactivate tab

To inactivate the backups, click Inactivate. Figure 4-28 displays the backups that
were inactivated in our example.

Figure 4-28 Backups inactivated

Figure 4-29 shows an example of full backup automatically inactivating previous


backups for a database. You do not need to worry about the inactivation
messages.

152 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Figure 4-29 Automatic inactivation by legacy full backup

4.5 CLI overview


The Data Protection for SQL Server CLI is called tdpsqlc.exe. It is located in the
directory where Data Protection for SQL Server is installed; \Program
Files\Tivoli\TSM\TDPSql is the default directory. Issue the tdpsqlc ? or tdpsqlc
help command to display help for the command line interface. Data Protection for
SQL Server CLI provides the comands listed on Table 4-3.

Table 4-3 Data Protection for SQL Server CLI commands

Command Description

Backup Backs up all or part of one or more SQL databases to Tivoli Storage
Manager server

Query Displays information about servers, databases, backup objects, and


Data Protection for SQL configuration.

Restore Restores all or part of one or more SQL databases to SQL server

INACTIVate Inactivates one or more active backup objects on the Tivoli Storage
Manager server

Help Displays the syntax of Data Protection for SQL commands.

Set Changes the values of configuration parameters

CHANGETSMPassword Changes the Tivoli Storage Manager password used by Data Protection
for SQL.

Chapter 4. Data Protection for SQL Server backup 153


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

By default, tdpsqlc uses the parameters stored in the tdpsql.opt configuration


file. To specify a different configuration file you can use the parameter
/CONFIGfile = configfilename, where configfilename is the name of Data
Protection for SQL Server configuration file. Other useful parameters are
/sqlserver and /tsmoptfile. When the /sqlserver parameter is specified, Data
Protection for SQL Server overrides the default SQL Server, which is the local
SQL server. You must use this switch to access SQL Server named instances
and SQL Server clustered instances. When the /tsmoptfile is specified, it
overrides the default Tivoli Storage Manager API option file (dsm.opt).

You can also use tdpsqlc parameters to specify customized settings for your
operations. One example is the parameter /BACKUPMethod, that is used to choose
the type of backup will be performed, Legacy or VSS. If you omit this parameter,
the value specified for BACKUPMethod parameter in the configuration file will be
used.

Note: Data Protection for SQL Server CLI parameters are not case sensitive;
however, all SQL names of databases or parts of databases are
case-sensitive.

For a detailed explanation of the command line tdpsql tool, refer to Data
Protection for Microsoft SQL Server Installation and Users Guide, SC32-9059.

4.5.1 Data Protection for SQL Server 5.5 CLI new features
In Data Protection for SQL Server releases prior to 5.5, to control what
databases are included and excluded from backup operations you used
INCLUDE and EXCLUDE statements. The INCLUDE and EXCLUDE statemets
are stored, by default, in the dsm.opt configuration file. You have the flexibility to
include or exclude individual databases from a specific backup type, for example,
excluding offline databases from backup operations, or excluding databases
using simple recovery models from transaction log backups.

This option is still available in Data Protection for SQL Server 5.5; however, Data
Protection for SQL Server 5.5 CLI introduces a new parameter to the backup
command, and provides two built-in features in order to provide a greater
flexibility and control over backup operations.

The new CLI parameter introduced in the backup command is the /EXCLUDEDB
parameter. With this parameter, available for all Legacy and VSS backup types,
you can exclude databases from being backed up directly in Data Protection for
SQL Server CLI backup command, instead of having to change the EXCLUDE
statements in the dsm.opt file. Example 4-2 on page 157 shows an example of a
full legacy backup with the /EXCLUDEDB parameter.

154 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

The two built-in features introduced in Data Protection for SQL Server 5.5 are:
򐂰 Automatic exclusion of simple recovery model databases from CLI log
backups. An example of this built-in functionality is shown in Example 4-4 on
page 159.
򐂰 Automatic exclusion of master database from CLI log and differential
backups. An example of this built-in functionality is shown in Example 4-6 on
page 160.

For more information about Data Protection for SQL Server 5.5 new features,
refer to Data Protection for Microsoft SQL Server Installation and Users Guide,
SC32-9059.

4.6 Legacy CLI backups


In this section we discuss how to perform SQL Server backups using Data
Protection for SQL Server CLI tool. In the next examples, it is expected that you
already have installed and configured Data Protection for SQL.

The next sections will show how to perform similar backups to those performed in
4.6, “Legacy CLI backups” on page 155 using Data Protection for SQL CLI tool.

Note: For the next examples we use the default configuration parameters
stored in the tdpsql.cfg file. The parameter BACKUPMethod is configured as
Legacy.

4.6.1 Full database backups


Example 4-1 shows an example of full database backup and its output. The next
example backs up all databases, and produces the same result as the GUI
example shown in 4.2.1, “Full database backups” on page 135.

Example 4-1 CLI legacy full database backup


C:\>tdpsqlc backup * full

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Chapter 4. Data Protection for SQL Server backup 155


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning full backup for database master, 1 of 6.


Full: 0 Read: 3230464 Written: 3230464 Rate: 278.47 Kb/Sec
Backup of master completed successfully.

Beginning full backup for database model, 2 of 6.


Full: 0 Read: 2184960 Written: 2184960 Rate: 534.51 Kb/Sec
Backup of model completed successfully.

Beginning full backup for database msdb, 3 of 6.


Full: 0 Read: 6377216 Written: 6377216 Rate: 1,262.72 Kb/Sec
Backup of msdb completed successfully.

Beginning full backup for database ReportServer, 4 of 6.


Full: 0 Read: 3231488 Written: 3231488 Rate: 646.80 Kb/Sec
Backup of ReportServer completed successfully.

Beginning full backup for database ReportServerTempDB, 5 of 6.


Full: 0 Read: 2182912 Written: 2182912 Rate: 426.69 Kb/Sec
Backup of ReportServerTempDB completed successfully.

Beginning full backup for database SalesDB, 6 of 6.


Full: 0 Read: 2192000 Written: 2192000 Rate: 433.15 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 6


Total SQL backups attempted: 6
Total SQL backups completed: 6
Total SQL backups excluded: 0
Total SQL backups inactivated: 0

Throughput rate: 539.79 Kb/Sec


Total bytes transferred: 19,399,040
Elapsed processing time: 35.10 Secs

As discussed in 4.5.1, “Data Protection for SQL Server 5.5 CLI new features” on
page 154, it is possible to exclude a database from a backup operation using the
/excludedb parameter, as shown in Example 4-2. In this example, we exclude the
databases ReportServer and ReportServerTempDB from the backup operation.

156 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Example 4-2 Exclusion of a database in a full database backup operation


C:\>tdpsqlc backup * full /excludedb=ReportServer,ReportServerTempDB

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning full backup for database master, 1 of 4.


Full: 0 Read: 3231488 Written: 3231488 Rate: 353.31 Kb/Sec
Backup of master completed successfully.

Beginning full backup for database model, 2 of 4.


Full: 0 Read: 2187008 Written: 2187008 Rate: 398.16 Kb/Sec
Backup of model completed successfully.

Beginning full backup for database msdb, 3 of 4.


Full: 0 Read: 7425792 Written: 7425792 Rate: 1,335.74 Kb/Sec
Backup of msdb completed successfully.

Beginning full backup for database SalesDB, 4 of 4.


Full: 0 Read: 2192000 Written: 2192000 Rate: 468.92 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 6


Total SQL backups attempted: 4
Total SQL backups completed: 4
Total SQL backups excluded: 2
Total SQL backups inactivated: 0

Throughput rate: 604.05 Kb/Sec


Total bytes transferred: 15,036,288
Elapsed processing time: 24.31 Secs

Chapter 4. Data Protection for SQL Server backup 157


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

4.6.2 Transaction log backups


Example 4-3 shows an example of transaction log backup and its output. We
back up the SalesDB transaction log, similar to the GUI example shown in 4.2.2,
“Transaction log backups” on page 137.

Example 4-3 CLI legacy transaction log backup


C:\>tdpsqlc backup SalesDB log

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning log backup for database SalesDB, 1 of 1.


Full: 0 Read: 26240 Written: 26240 Rate: 37.08 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 1


Total SQL backups attempted: 1
Total SQL backups completed: 1
Total SQL backups excluded: 0

Throughput rate: 36.71 Kb/Sec


Total bytes transferred: 26,240
Elapsed processing time: 0.70 Secs

A new Data Protection for SQL Server feature is very useful when performing
transaction log backups: the ability to automatically exclude databases using the
simple recovery model (or truncate log on checkpoint option) from log backups.
With this new feature, you can simply ask Data Protection to perform transaction
log backups for all databases from a SQL Server, and it will detect the databases
using simple recovery model and automatically exclude them from the backup
operation.

Example 4-4 shows an example of this new feature.

158 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Example 4-4 Automatic exclusion of simple recovery model databases from transaction
log backup
C:\>tdpsqlc backup * log

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning log backup for database model, 1 of 2.


Full: 0 Read: 1535744 Written: 1535744 Rate: 1,315.57 Kb/Sec
Backup of model completed successfully.

Beginning log backup for database SalesDB, 2 of 2.


Full: 0 Read: 223872 Written: 223872 Rate: 193.99 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 6


Total SQL backups attempted: 2
Total SQL backups completed: 2
Total SQL backups excluded: 4

Throughput rate: 754.33 Kb/Sec


Total bytes transferred: 1,759,616
Elapsed processing time: 2.28 Secs

4.6.3 Differential backups


Example 4-5 shows an example of differential backup and its output. We back up
the SalesDB database, similar to the GUI example shown in 4.2.3, “Differential
backups” on page 138.

Example 4-5 CLI legacy differential backup


C:\>tdpsqlc backup SalesDB diff

Chapter 4. Data Protection for SQL Server backup 159


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning difffull backup for database SalesDB, 1 of 1.


Full: 0 Read: 1143424 Written: 1143424 Rate: 270.37 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 1


Total SQL backups attempted: 1
Total SQL backups completed: 1
Total SQL backups excluded: 0

Throughput rate: 269.91 Kb/Sec


Total bytes transferred: 1,143,424
Elapsed processing time: 4.14 Secs

A new Data Protection for SQL Server feature is very useful when performing
differential backups: the ability to automatically exclude the master database
from differential backups. With this new feature, you can simply ask Data
Protection to perform differential backup for all databases from a SQL Server,
and it automatically will exclude the master database from the backup operation.

Example 4-6 shows an example of automatic exclusion of master database in


differential backups.

Example 4-6 Automatic exclusion of master database from differential backups


C:\>tdpsqlc backup * diff

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

160 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning difffull backup for database model, 1 of 5.


Full: 0 Read: 1138432 Written: 1138432 Rate: 285.94 Kb/Sec
Backup of model completed successfully.

Beginning difffull backup for database msdb, 2 of 5.


Full: 0 Read: 2182912 Written: 2182912 Rate: 403.21 Kb/Sec
Backup of msdb completed successfully.

Beginning difffull backup for database ReportServer, 3 of 5.


Full: 0 Read: 1134336 Written: 1134336 Rate: 243.19 Kb/Sec
Backup of ReportServer completed successfully.

Beginning difffull backup for database ReportServerTempDB, 4 of 5.


Full: 0 Read: 1134336 Written: 1134336 Rate: 246.77 Kb/Sec
Backup of ReportServerTempDB completed successfully.

Beginning difffull backup for database SalesDB, 5 of 5.


Full: 0 Read: 1143424 Written: 1143424 Rate: 245.36 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 6


Total SQL backups attempted: 5
Total SQL backups completed: 5
Total SQL backups excluded: 1

Throughput rate: 288.53 Kb/Sec


Total bytes transferred: 6,733,440
Elapsed processing time: 22.79 Secs

4.6.4 Group backups


Example 4-7 shows an example of group backup and its output. We back up the
SalesDB_LA filegroup of SalesDB database, similar to the GUI example shown
in 4.2.4, “Group backups” on page 139.

Example 4-7 Cli legacy group backup


C:\>tdpsqlc backup SalesDB group=SalesDB_LA

Chapter 4. Data Protection for SQL Server backup 161


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning group backup for database SalesDB, 1 of 1.


Full: 0 Read: 1139968 Written: 1139968 Rate: 266.33 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 1


Total SQL backups attempted: 1
Total SQL backups completed: 1
Total SQL backups excluded: 0

Throughput rate: 265.95 Kb/Sec


Total bytes transferred: 1,139,968
Elapsed processing time: 4.19 Secs

Note: We recommend you to follow group backups with transaction log


backups for all SQL databases you back up.

4.6.5 File backups


Example 4-8 shows an example of file backup and its output. In this example only
the file SalesDB_LA_1 is backed up. All other files from the SalesDB_LA
filegroup are not included in this backup. It produces the same result as the GUI
example shown in 4.2.5, “File backups” on page 141.

Example 4-8 CLI legacy file backup


C:\>tdpsqlc backup SalesDB file=SalesDB_LA_1

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

162 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Connecting to SQL Server, please wait...

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning file backup for database SalesDB, 1 of 1.


Full: 0 Read: 1138304 Written: 1138304 Rate: 264.55 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 1


Total SQL backups attempted: 1
Total SQL backups completed: 1
Total SQL backups excluded: 0

Throughput rate: 264.17 Kb/Sec


Total bytes transferred: 1,138,304
Elapsed processing time: 4.21 Secs

Note: We recommend you to follow file backups with transaction log backups
for all SQL databases you back up.

4.6.6 Set backups


Example 4-9 hows an example of file backup and its output. In this example the
filegroup SalesDB_EMEA and the file SALESDB_LA_2 from the filegroup
SalesDB_LA are backed up. It produces the same result as the GUI example
shown in 4.2.6, “Set backups” on page 142.

Example 4-9 CLI legacy set backups


C:\>tdpsqlc backup SalesDB set /group=SalesDB_EMEA /file=SalesDB_LA_2

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Chapter 4. Data Protection for SQL Server backup 163


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning set backup for database SalesDB, 1 of 1.


Full: 0 Read: 1139456 Written: 1139456 Rate: 281.71 Kb/Sec
Backup of SalesDB completed successfully.

Total SQL backups selected: 1


Total SQL backups attempted: 1
Total SQL backups completed: 1
Total SQL backups excluded: 0

Throughput rate: 281.28 Kb/Sec


Total bytes transferred: 1,139,456
Elapsed processing time: 3.96 Secs

Note: We recommend you to follow set backups with transaction log backups
for all SQL databases you back up.

4.6.7 Tail-log backups


Example 4-10 shows an example of transaction log backup and its output. We
back up the SalesDB transaction tail log, similar to the GUI example shown in
4.2.7, “Tail-log backups” on page 143.

Example 4-10 CLI legacy tail-log backup


C:\>tdpsqlc backup SalesDB log /trunc=no

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Starting SQL database backup...

Connecting to TSM Server as node 'COPPER_SQL'...

Beginning log backup for database SalesDB, 1 of 1.


Full: 0 Read: 223872 Written: 223872 Rate: 171.74 Kb/Sec

164 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Backup of SalesDB completed successfully.

Total SQL backups selected: 1


Total SQL backups attempted: 1
Total SQL backups completed: 1
Total SQL backups excluded: 0

Throughput rate: 170.93 Kb/Sec


Total bytes transferred: 223,872
Elapsed processing time: 1.28 Secs

Note: Tail-log backups are intended only for special situations. Refer to 2.4.4,
“Backup a transaction log without truncate the log” on page 51 for more
information.

4.7 VSS CLI backups


With Data Protection for SQL Server you can only perform full VSS backups. Two
types of VSS backups are available with Data Protection for SQL Server:
򐂰 VSS full backup
򐂰 VSS off-loaded full backup

In next sections we discuss how to perform CLI backups using both VSS backup
types.

4.7.1 VSS CLI full backup


Example 4-11 on page 165 shows an example of a VSS full database backup
and its output. We back up all databases, similar to the GUI example shown in
4.3.1, “VSS GUI full backup” on page 144.

Example 4-11 CLI VSS full backup


C:\>tdpsqlc backup * full /backupmethod=VSS

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

Chapter 4. Data Protection for SQL Server backup 165


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

Connecting to TSM Server as node 'COPPER_SQL'...


Connecting to Local DSM Agent 'copper_vss'...

Starting SQL database backup...

Beginning VSS backup of 'ReportServer', 'ReportServerTempDB',


'SalesDB', 'master', 'model', 'msdb'...

Preparing to backup using snapshot.


Files Examined/Completed/Failed: [ 64 / 64 / 0 ] Total Bytes:
6183635

VSS Backup operation completed with rc = 0


Files Examined : 64
Files Completed : 64
Files Failed : 0
Total Bytes : 6183635

4.7.2 VSS CLI off-loaded backup


An off-loaded backup uses an alternate machine to move SQL data to Tivoli
Storage Manager server storage. This may reduce the impact on network, I/O,
and CPU resources during backup processing.

A VSS CLI off-loaded backup has a very similar procedure than a normal VSS
CLI backup. The differences are that you must configure the
REMOTEDSMAgentnode parameter in the Data Protection for SQL Server
configuration file (tdpsql.cfg by default) using either the Configuration task in the
Edit Menu of the GUI or the tdpsqlc set command, and use the /offload
parameter in the Data Protection for CLI command, as shown in Example 4-12

Example 4-12 VSS CLI off-loaded backup


C:\>tdpsqlc backup * full /backupmethod=VSS /backupdestination=TSM
/offload

166 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

4.8 Working with existing backups with CLI


With Data Protection for SQL Server GUI you can display information about
existing backups, and manually inactivate backups.

This section covers:


򐂰 Displaying existing backups
򐂰 Inactivating legacy backups

4.8.1 Displaying existing backups using CLI


You use the QUERY command to display information about the SQL server and its
databases, about the Tivoli Storage Manager server and its backup objects, and
about Data Protection for SQL. Table 4-4 shows some useful query commands.

Table 4-4 Useful query commands


To display information about... Use the command

SQL Server instance tdpsqlc query sql /compat

All SQL Server databases tdpsqlc query sql * /compat

A specific SQL Server database tdpsqlc query sql SalesDB /compata

Data Protection for SQL Server configuration file tdpsqlc query tdp
information

All active legacy backup types for all databases tdpsqlc query tsm * types /active

All active and inactive legacy backup types for all tdpsqlc query tsm * types /all
databases

All active and inactive legacy backup types for a tdpsqlc query tsm SalesDB types /alla
specific database

Active backups for all databasesb tdpsqlc query tsm *

Active backups for a specific database tdpsqlc query tsm SalesDBa

Active full backups for a specific database including tdpsqlc query tsm SalesDB full /compata
compatibility informationb

Active full backups for a specific database including tdpsqlc query tsm SalesDB full /compat
compatibility informationb /activea

Active and inactive full backups for a specific tdpsqlc query tsm SalesDB full /fileinfo
database including file information /mountwait=yes /alla

Chapter 4. Data Protection for SQL Server backup 167


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

a. Change SalesDB to the database name you want do display information


b. VSS and Legacy backups

For a detailed discussion about the query command, refer to Data Protection for
Microsoft SQL Server Installation and Users Guide, SC32-9059-02.

4.8.2 Inactivating backups using CLI (Legacy only)


You use the INACTIVATE command to inactivate one or more active backup
objects on the Tivoli Storage Manager Server.

Inactivating backups through Data Protection for SQL Server CLI gives you more
flexibility in comparison to Data Protection for SQL Server GUI. With CLI you can
inactivate backups older than a specified number of days, while using the GUI
you must individually select the desired objects to inactivate. You can use the
parameter /olderthan to specify how old a backup object must be before the
command can inactivate it. The number of days old can range from 0 to 9999,
and if you select 0 you will inactivate all selected objects. There is no default
value for this parameter.

Example 4-13 shows an example of how to inactivate all backups for a SQL
Server. It is similar to the GUI example shown in 4.4.2, “Inactivating backups
using GUI (Legacy only)” on page 150.

Example 4-13 Inactivating all backups using CLI


C:\>tdpsqlc inactiv * *

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to TSM Server as node 'COPPER_SQL'...

Starting Sql database backup inactivation...


Querying Tivoli Storage Manager server for a list of database backups,
please wait...

Inactivating full backup master


Inactivating full backup model
Inactivating full backup msdb
Inactivating full backup ReportServer
Inactivating full backup ReportServerTempDB

168 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-4-backup.fm

Inactivating full backup SalesDB


Inactivating set backup SalesDB\20071020024434\00001774
Inactivating set backup SalesDB\20071020024714\000017A0
Inactivating set backup SalesDB\20071020024845\00000774
Inactivating log backup SalesDB\20071020025936\00001420

Total database backups inspected: 10


Total database backups requested for inactivation: 10
Total database backups inactivated: 10
Total database skipped: 0

Elapsed processing time: 0.30 Secs

Chapter 4. Data Protection for SQL Server backup 169


6148ch-4-backup.fm Draft Document for Review April 30, 2008 1:21 pm

170 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

Chapter 5. Data Protection for SQL


Server restore
In this chapter we discuss how to use the Data Protection for SQL Server
graphical user interface (GUI) and command line interface (CLI) to restore SQL
Server databases. An introduction to Data Protection for SQL Server GUI and
CLI is discussed in 4.1, “GUI overview” on page 122 and 4.5, “CLI overview” on
page 153, respectively. In this chapter we expected that you are familiarized with
Data Proctection for SQL Server GUI and CLI tools.

We also provide several examples to discuss how to perform restores for some
common situations. It is also discussed how to use Data Protection for SQL
Server to implement a stand by database.

This chapter covers the following:


򐂰 5.1, “Considerations for restore operations” on page 172
򐂰 5.2, “Data Protection for SQL Server GUI restore” on page 173
򐂰 5.3, “Data Protection for SQL Server CLI restore” on page 178
򐂰 5.4, “Restore examples” on page 179
򐂰 5.5, “Standby server” on page 197

© Copyright IBM Corp. 2008. All rights reserved. 171


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

5.1 Considerations for restore operations


Before you restore a database, several factors must be considered for a
successful restore operation. For each specific restore scenario, a different level
of complexity is needed for the restore operation. Data Protection for SQL Server
provides you possibilities going from restore a simple database from a full
backup on the same server to restore all databases on a different server in a
disaster recovery scenario, for example.

It is very important to understand that the restore capabilities for a SQL Server
are directly related to the backup operations performed for the databases. A well
planned and implementated set of backup routines are crucial for a successful
restore operation; in other words, you cannot restore what has not been backed
up. See 2.3, “Microsoft SQL Server backup planning” on page 40 for a discussion
about SQL Server backup planning.

Another important point is that is possible to have unexpected hardware or


software failures during a restore operation. You can minimize this risk by
regularly testing your restore routines to make sure they are working as
expected.

When you restore a database, keep in mind that data which exists in the
database is overwritten and is no longer available after the restore is complete.
Restore Databases allows you to restore databases or parts of databases only
from full, differential, and log backups. Although only VSS full backups are
supported, Legacy differential and Legacy log backups can be applied after a full
VSS Backup has been restored.

A master database restore requires special attention. See 5.4.3, “Restore SQL
Server system databases” on page 181 for step-by-step instructions.

5.1.1 Display list of backups


Before you start a restore process, you must check what backups are available
for the database you want to restore.

Using the Data Protection for SQL Server GUI, you can use the Restore
Databases tab window to display full, differential and log backups, and the
Restore Groups/Files tab window to display full, log, group, set and file backups.
Legacy and VSS backups are displayed together. For more information, refer to
4.4.1, “Displaying existing backups using GUI” on page 148.

Using Data Protection for SQL Server CLI, you can use the query command. For
more information about the query command, see 4.8.1, “Displaying existing

172 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

backups using CLI” on page 167. or refer to Data Protection for Microsoft SQL
Server Installation and Users Guide, SC32-9059.

5.1.2 VSS considerations


Be aware of the following considerations when performing VSS restores. Unless
otherwise specified, “VSS Restores” refers to all restore types that use VSS
(VSS Restore, VSS Fast Restore, VSS Instant Restore):
򐂰 If you plan to perform a VSS Restore of the master database, see 5.4.3,
“Restore SQL Server system databases” on page 181.
򐂰 A VSS Instant Restore overwrites the entire contents of the source volumes.
However, you can avoid overwriting the source volumes by selecting the
Disable VSS Instant Restore option. This option bypasses volume-level copy
and uses file-level copy instead to restore the files from a VSS Backup that
resides on local shadow volumes. It is recommended that the source volume
contain only the SQL database.
򐂰 Be aware that when a VSS restore from local shadow volumes is performed,
the bytes transferred will display “0”. That is because no data (“0”) is restored
from the Tivoli Storage Manager server.
򐂰 In order to perform a VSS Instant Restore, the IBM Tivoli Storage Manager for
Copy Services Hardware Devices Snapshot Integration Module must be
installed.
򐂰 When performing VSS Instant Restores, you must make sure that any
previous background copies (that involve the volumes being restored) are
completed prior to initiating the VSS Instant Restore.

5.2 Data Protection for SQL Server GUI restore


Using the Data Protection for SQL Server GUI you can perform full and partial
restores of your databases. In a full restore you restore all files belonging to the
database, while in a partial restore you choose to restore only individual files
from the database.

If you plan to fully restore your database using full, log and differential backups,
select Restore Database tab in the Data Protection GUI. If you plan to restore
only parts of your database using full, file, group, set or log backups select the
Restore Groups/Files tabs in the Data Protection GUI.

Chapter 5. Data Protection for SQL Server restore 173


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Note: You can choose both Restore Database tab and Restore Groups/Files
tab to fully restore your database from a full backup and apply subsequent
transaction log files. The difference between them is that in Restore
Groups/Files tab you have the option to choose individual files from the
database full backup to be restored, while in Restore Database tab you will
restore all files from your database.

In next sections we discuss how to restore SQL Server databases using Data
Protection for SQL Server GUI.

5.2.1 Perform full database restore


Perform the following steps to restore a SQL Server database using full,
differential and log backups.
1. Start Data Protection for SQL Server GUI.
2. Click the Restore Database tab.
3. Check Show Active and Inactive if you want to display inactive backup
objects in addition to active backup objects.
4. Click the plus sign in the tree view to the left of the SQL Server that you want
to work with. All SQL Servers backed up under the Tivoli Storage Manager
nodename are displayed.
5. Click the plus sign in the tree view to show the names of databases backed up
on the Tivoli Storage Manager server. All databases backed up under the
Tivoli Storage Manager nodename , even for databases that were already
dropped from SQL Server but were not expired from Tivoli Storage Manager
Server inventory.
6. Click the plus sign in the tree view to the left of the SQL Server that you want
to restore from. The tree expands again and shows the databases available
for restore processing.
7. Click the plus sign in the tree view to the left of the database that you want to
restore. The database expands to show the types of backups available for
restore.
8. Click the selection box in the tree view to the left of the full, differential, or
transaction log backup that you want to restore.
9. Select the desired Restore Options for your backup.
10. Click Restore. The Restore Progress dialog appears.
11. Click OK. The restore is complete.

174 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

5.2.2 Perform partial restores


The steps required to restore a SQL Server file or filegroup using Data Protection
for SQL Server GUI are similar to those required to fully restore a SQL Server
database:
1. Start Data Protection for SQL Server GUI.
2. Click on Restore Groups/Files tab.
3. Check Show Active and Inactive if you want to display inactive backup
objects in addition to active backup objects.
4. Click the plus sign in the tree view to the left of the SQL Server that you want
to work with. All SQL Servers backed up under the Tivoli Storage Manager
nodename are displayed.
5. Click the plus sign in the tree view to show the names of databases backed up
on the Tivoli Storage Manager server. All databases backed up under the
Tivoli Storage Manager nodename are displayed, even for databases that
were already dropped from SQL Server but were not expired from the Tivoli
Storage Manager server inventory.
6. Click the plus sign in the tree view to the left of the SQL Server that you want
to restore from. The tree expands again and shows the databases available
for restore processing.
7. Click the plus sign in the tree view to the left of the database that you want to
restore. The database expands to show the types of backups available for
restore.
8. Select the desired Restore Options for your backup.
9. If you want to replace the existing database object with the file group or file
you are about to restore, check the Replace box.
10.I If you want only the database owner to access the database after it has been
restored, check the Database Owner Only box.
11. Click Restore.
12. The Restore Progress dialog appears.
13. Click OK. The restore is complete.

5.2.3 Restore options


You can specify how the restore operation will be performed using the Restore
Options tab. From either the Restore Databases tab or the Restore Groups/Files
tab, you can select the following options.
򐂰 Show Active and Inactive

Chapter 5. Data Protection for SQL Server restore 175


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

By checking this option, you can include inactive backup objects in the tree
and list. This allows you to easily specify inactive objects for restore purposes.
The default is to display only active objects.
򐂰 Stripes
You can specify the number of data stripes to use in a restore operation. A
maximum of 64 data stripes is allowed. The default value is 1. Make sure that
this matches the value set for SQL buffers. Note that this option is always
enabled for Legacy operations. However, stripes are not available for VSS
operations.
򐂰 Replace
You can replace a database during a restore by selecting the check box. The
default is not to replace databases. This option is always enabled and applies
to Legacy restores only.
򐂰 Recovery
If you select several objects for restore in the GUI (e.g. full, difffull, log, log)
and leave this option selected, Data Protection for SQL will make sure that
SQL administers the recovery option only on the last backup object for each
database being restored. This option is selected by default, but you can clear
this checkbox when needed.
򐂰 Database Owner Only
You can mark a database for owner use only after a restore by selecting the
check box. The default is not to mark for owner use. This option is always
enabled and applies to Legacy restores only.
򐂰 Wait for Tape Mounts for Restore
You can specify whether or not the Data Protection for SQL restore operation
waits for the Tivoli Storage Manager server to mount removable media such
as tapes or CDs. This information is retrieved from Tivoli Storage Manager
when you press the plus (+) icon on the backup object to expand the tree.
򐂰 Wait for Tape Mounts for File Information
When querying Tivoli Storage Manager for file information, you can specify
whether or not Data Protection for SQL waits for the Tivoli Storage Manager
server to mount removable media. This option is not selected by default and
applies to Legacy restores only.

From the Restore Databases tab only, the following additional options are
available:
򐂰 Point in Time

176 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

You can specify a point in time to which to restore a database if desired by


clicking the Point in Time button. This button is enabled only when you select
for restore a full backup object and at least one log backup.
– Point in Time Dialog
Clicking on the Point in Time button displays a dialog box with the following
options:
• No point in time
• Stop at
• Stop at mark
• Stop before mark
The stop radio buttons allow you to specify a date and time. With Stop at
mark and Stop before mark, you can name a mark for the restore and
include the date and time to help locate the mark. To clear a point in time
that is set, select the No point in time radio button. When point in time is in
use, a static field is enabled to display the results of the action.
򐂰 Disable VSS Instant Restore
Selecting Disable VSS Instant Restore bypasses volume-level copy and uses
file-level copy to restore the files from a local VSS Backup. If this option is not
selected, volume level snapshot restore is used for local VSS Backups if the
backup exists on volumes that support it. The default value is to use volume
level snapshot restore if supported. This option is available for VSS
operations only. When performing VSS Instant Restores, you must make sure
that any previous background copies (that involve the volumes being
restored) are completed prior to initiating the VSS Instant Restore.

Shortcut Menu
You can display additional restore options by right-clicking a selected item in the
list control. This menu is available only when you highlight a database in the tree.
All of its backup objects will be displayed in the list control, and the menu will be
available for any selected objects. The right-click pop-up menu contains the
following items:
򐂰 Restore Into
Use this option to specify the database to restore a backup object to. Click
Restore Into to display an edit box. If you have selected several databases to
be restored, the restore into name you specify applies only to the selected
backup object that you right-clicked. If other selected backups require the
restore into parameter, you will have to specify them one at a time, but you
can do this in one restore operation.
򐂰 Relocate

Chapter 5. Data Protection for SQL Server restore 177


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Use the Relocate dialogs to specify new destination locations in which to


restore backed up SQL databases, logs, and SQL Server full-text index files:
– Relocate All Files Into a Directory
Select this option to restore the SQL datafiles, logs, and other related files
into a location different from where the data was originally backed up.
• Relocate Log Files Into
Check this box to restore the log files into a location different from
where the SQL database and other related files are being restored.
• Relocate Other Files Into
Check this box to restore SQL Server full-text index files into a location
different from where the SQL database and logs are being restored.
– Relocate Files Individually
Select this option to restore each SQL database, log, and SQL Server
full-text index file individually. This is available for Legacy backups only.
򐂰 Standby Server Undo File
Use this option to specify the undo file for a Legacy restore to a standby
SQL database. If the target SQL database is not already in standby mode,
it will be placed in standby mode. This menu item appears only in the
Restore Databases window and is available for full, differential, and log
backup types, but only for one database at a time. Click this option to
display an edit box for the undo file name. Once you specify this for a
database, it applies to all backup objects for that database. Likewise, once
you remove this option for a backup object, it is removed for all.

5.3 Data Protection for SQL Server CLI restore


The command RESTORE is used to perform Legacy and VSS restores. You can
perform full and partial restores, using full, differential, log, group, file and set
backups.

When using TDP for SQL commands, keep in mind that all SQL names of
databases or parts of databases are case-sensitive, when addressing
commands:
򐂰 SQL database names are case-sensitive.
򐂰 The logicalfilename variable is case-sensitive.
򐂰 The groupname variable is case-sensitive

178 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

Almost all restore operations can be performed using both Data Protection for
SQL Server GUI and CLI tools. In this chapter we will mostly cover Data
Protection for SQL Server GUI routines.

For a complete discussion about RESTORE parameters, refer to Data Protection


for Microsoft SQL Server Installation and Users Guide, SC32-9059.

5.4 Restore examples


Restores done on your SQL server can cover a wide range of complexity, from
simply restoring databases on a running server, to accomplishing a complete
disaster recovery.

In next sections we show a complete example of how a disaster recovery is


performed, plus how to restore from different backup types, in various situations.

5.4.1 Considerations for restore operations


Before we start with our restore examples, a brief reminder about some
important topics for restore operations is necessary.

Recovery option
When the check box Recovery is checked (default), the database is ready for use
as soon as the restore is completed, and no following logs can be applied. If you
accidentally check this option before you apply the last transaction log, you must
restore your database again.

When Recovery is unchecked, the database is restored with norecovery, leaving


it in an unusable intermediate state, and further transaction logs can be applied.
The last backup to restore must be with recovery in order to make the database
ready for use.

Additional information can be found in SQL Server documentation.

Need to back up tail of the log before restore


If you are restoring a database over an existing database, and the database is
using bulk-logged or full recovery models, you must first perform a tail-log
backup, or choose the Replace check box in Restore Options panel. Tail-log
backups are discussed in 4.2.7, “Tail-log backups” on page 143.

If you try to restore a database without the options described above, you will
receive errors similar to those shown in Figure 5-6.

Chapter 5. Data Protection for SQL Server restore 179


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 5-1 Error message related to tail log backup

5.4.2 Disaster recovery


In a disaster recovery situation, the most likely scenario may involve a reinstalled
SQL server, or you may have to rebuild the master database on your existing
SQL server.

Generally, according to the recovery needed, you may need to perform the
following tasks:
1. Install SQL Server and apply the required patchsets. Remember to use the
same sort order and code page as the SQL server you recover.
2. Install Data Protection for SQL Server according to the description in “
Chapter 3, “Installation and configuration” on page 69, and then restore the
dsm.opt and tdpsql.opt files with the TSM Backup/Archive Client. You can
also recreate the dsm.opt and tdpsql.opt yourself, using instructions
contained in same chapter.
3. Start SQL Server in single-mode using sqlservr.exe command with -m
parameter.
4. Use Data Protection for SQL Server to restore master database using either
legacy or VSS backups. At the end of the restore operation, SQL Server will
be shutdown.
5. Start SQL Server normally, as a service.
6. Manually reapply any changes that were made to the master database after
the date of the database backup used to do the restore operation.
7. Use Data Protection for SQL Server to restore all other system and user
databases.

180 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

Note: As the tempdb database is recreated every time SQL Server is


restarted, there is no need to backup this database.

However, there are some situations where only database files are damaged,
while all SQL Server binary files and Windows registry entries are intact, for
example, when a disk containing only SQL Server databases crashes. Another
situation is when you do not have a valid backup for the system databases, only
for the user databases.

For these situations, instead of reinstall SQL Server, you can rebuild the SQL
Server master database and then perform steps 3 to 6 listed above. When you
rebuild the master database, the msdb and model databases are recreated as
well, so you also need to restore those databases after the rebuild operation.

Note: In SQL Server 7 and 2000, to rebuild the master database use the
Rebuildm.exe utility in \..\mssql7\binn\ or \..\Microsoft SQL
server\80\Tools\Binn\ for SQL 2000.

In SQL Server 2005, use the Setup command to rebuild the master database.

For all SQL Server versions, the compact disc or shared network directory
containing the SQL Server installation software is required to rebuild the
master database, as well any service pack applied after the SQL Server
installation.

For more information, refer to SQL Server documentation.

5.4.3 Restore SQL Server system databases


As discussed in 5.4.2, “Disaster recovery” on page 180, in a disaster recovery
scenario, after SQL Server and Data Protection for SQL Server installations you
must restore the system databases, starting from the master database and then
restoring msdb and model databases.

In this section we show how to restore SQL Server databases.

First of all, stop all SQL Server related services to the instance you will restore
the system databases, such as SQL Server Integration Services and SQL Server
Analysis Services. After, you must start SQL Server in a single-user mode. Open
a command prompt window, go to the Binn directory, located inside SQL Server
installation path, and start SQL Server in single-user mode using the following
command:

Chapter 5. Data Protection for SQL Server restore 181


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

sqlservr.exe -m

Now launch Data Protection for SQL Server GUI, select the Restore Databases
tab, and select the master database to restore, as shown in Figure 5-2 on
page 182.

Figure 5-2 Selecting master database for restore

Regardless of the previous file path of the master database files, which is stored
with the backup object of the database, it will be restored where the
reinstalled/rebuild master database is present.

After the restore is completed, a confirmation screen will be displayed with the
restore results, as shown in Figure 5-3.

182 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

Figure 5-3 Restore of master database complete

At the end of the restore operation, SQL Server is automatically shutdown. In


previous Data Protection for SQL Server releases, this causes an error message
to be displayed at the end of restore operation.You can safely ignore this error
message. Now start SQL Server as a service, using Windows Control Panel.

Note: When the file path settings (in the restored master database) are
different from the current file path of the model database (obtained by rebuild
of the master database or from reinstalling SQL server) the SQL server fails to
start.

Workaround: Move the model database files model.mdf and modellog.ldf to


the file path defined in the restored master database.

Now restore the model and msdb databases using TDP for SQL Server. In the
Restore Databases tab, select model and msdb databases. If needed, you can
relocate the file space destination for the database, as shown Figure 5-4 on
page 184.

Chapter 5. Data Protection for SQL Server restore 183


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 5-4 Relocating system databases

In the Relocate window, choose the location to restore the files, as shown in
Figure 5-5.

184 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

Figure 5-5 Choosing the location where model and msdb will be restored

Note: If the Logical File Names and Physical File Names columns do not
contain information about the database files, you must check the Wait for Tape
Mounts for File Information box, and refresh the tree view.

This happens because your metadata was migrated to removable media.

Start the restore process by clicking Restore. At the end of the operation, you will
receive a confirmation screen with the restore results.

At this point, you have restored all your system databases, and then you can
start restoring your user databases, as shown in the next section.

5.4.4 Complete restore


In a disaster recovery scenario after you restore your system databases you
must restore your user databases. There are several other situations where you
would like to restore a database, such as a database corruption, or some data
truncate by mistake, for example.

Chapter 5. Data Protection for SQL Server restore 185


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Performing a complete restore of the database means to apply the last full
backup taken, the last differential backup, if any, and all transaction log backups
since then.

You can choose to restore multiple databases at the same time. If you want to
relocate, you must specify this for each database to be restored.

To perform a complete restore of a database, click on Restore Databases tab,


and select on the left pane the databases to be restored, as shown in Figure 5-6.

Figure 5-6 Complete restore

5.4.5 Transaction log and differential restore


Transaction log backups and differential backups are worthwhile only when
restored together with a full database backup. You cannot start a restore
operation using either a transaction log backup or a differential backup; you must
first restore the last full backup taken before the backup you want to restore, and
then restore the desired backup.

While using Data Protection for SQL Server GUI, the necessary logs to perform a
restore are automatically selected according to the backup object you select.
However, you also have the option to to manually select and restore individual

186 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

backup objects for your databases. Allowing Data Protection for SQL Server GUI
to choose the required backup objects to be restore can avoid waste of time and
resources during a backup operation, for example, not restoring unnecessary
transaction logs due to existence of differential backups.

For more information about selection propagation rules in Data Protection for
SQL Server GUI, refer to Chapter 4, “Using the graphical user interface” in Data
Protection for Microsoft SQL Server Installation and Users Guide,
SC32-9059-02.

If you want to manually restore a transaction log or differential backup, you can:
1. Restore a full database backup taken before the transaction log or differential
backup you want to restore with the Recovery option unchecked.
2. In case of differential backups, directly restore the desired differential backup
with the Recovery option checked.
3. In case of transaction log files, you can apply either the last differential backup
taken before the transaction log backup, if available, and then all transaction
log backups since the last differential backup until the desired transaction log
backup, or all transaction log backups since the full backup. For these two
scenarios, restore only the last transaction log the Recovery option checked.

5.4.6 Point in time restore


To restore a database to a specific point in time using TDP for SQL you must first
restore the latest full backup prior to the desired point in time, then all transaction
logs since the last full backup until the last transaction log backup taken after the
desired point in time to restore the database.

For the next example, we will restore the database SalesDB until Feb 16, 2007,
07:40. We select the last full backup, and all subsequent transaction log backups.
As the time of the last transaction log backup is 07:57:13, it must be included in
this restore operation. Figure 5-7 on page 188 shows our selection.h

Chapter 5. Data Protection for SQL Server restore 187


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 5-7 Selection of backups for the point-in-time restore

Then, as shown in Figure 5-8 on page 188, click on Point in Time button, and
then choose the desired time to restore the database.

Figure 5-8 Point-in-time restore time selection

188 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

Note that after you choose the date and time desired for the point-in-time restore
operation, it will be shown in the main screen, as shown in Figure 5-9 on
page 189.

Figure 5-9 Point-in-time restore

Note: Point in time restores are available only from the Restore Databases tab

If you want to include file, groups or set backups in your point in time restore
operation, you can:
1. Restore, from the Restore Databases tab, a full backup taken before the point
you want to restore you database with the Recovery option in the Restore
options panel unchecked.
2. If there is any differential backup taken after the full backup restored and
before the time you want to use in your point in time recovery, restore it using
the Restore Databases tab with the Recovery option in the Restore options
panel unchecked.
3. Switch to Restore File/Groups tab and apply the subsequent transaction log,
file, group and set backups with Recovery option in the Restore options panel

Chapter 5. Data Protection for SQL Server restore 189


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

unchecked. Do not restore the last transaction log backup taken before the
time you want to
4. Back to the Restore Databases tab and choose the last transaction log to be
applied. Click on Point in Time button to specify until the database will be
restored. Before click on the Restore button, check the Recovery option in the
Restore options panel.

5.4.7 Named point restore


When the need to keep two or more databases consistent, you may implement
named mark transactions. SQL server 2000 and 2005 support named mark
transactions, which means you can mark transactions across related databases
and use these marked transactions to recover related databases to the same
transaction consistent point. Therefore it is not needed to do synchronized
backups.

Data Protection for SQL Server supports restore to a named mark. To restore to
a named mark, you must select Restore Databases tab, and click on Point in
Time option in the Restore Options. Then, you must specify the mark name, and
restore to before or after the mark. Since the mark is bound to the transaction, it
is most likely repeated in the log, therefore you must specify a time prior to the
desired mark in time.

Figure 5-10 shows an example of how to select a named point restore. In this
example, the database will be restored when the named mark batch_start is
found after 05:00 am from November 18, 2007.

Figure 5-10 Restore to a named mark in time

190 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

5.4.8 Relocate files during a restore


The backup object of a database file contain the file’s name and file path location
from where it was backed up. Therefore, when restoring to another file path or
physical filename, relocation must be specified.

To relocate the database files using Data Protection for SQL Server GUI, select
the backup object, right-click on the database object and select RELOCATE, as
shown in Figure 5-11 on page 191

Figure 5-11 How to choose relocate from Data Protection for SQL Server GUI

Then the relocate box pops up, and the new location and physical filename can
be entered. In the relocate box you have two options:
򐂰 Relocate all files into a directory
With this option you can choose to restore all files into a single location, or
choose to restore data files in one location, log files in a different location and
other files, such as full-text index files in another location. If you do not specify
a location for log files or full-text index files, they are restored to the same
location as SQL Server data files.

Chapter 5. Data Protection for SQL Server restore 191


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Relocate files individually


Using this option you can speficy a different location for each physical file.

Figure 5-12 on page 192 shows how to specify a different location for each
physical file from a database with a full-text catalog.

Figure 5-12 How to choose a different location for each file

Note: If the Logical File Names and Physical File Names columns do not
contain information about the database files, you must check the Wait for Tape
Mounts for File Information box, and refresh the tree view.

After you choose the new locations for the physical files, perform the restore
operation clicking on Restore button on Data Protection for SQL Server GUI.

5.4.9 Partial restore


In certain situations, such as a disk corruption, it may be necessary to partially
restore the databases, only restoring those files damaged or lost. You can
perform partial restores only on full database backup objects. You can also use
partial restores to create a subset of the SQL database.

192 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

After the partial restore, it is possible to restore differential and transaction log
backups to return the restored file

When performing a partial restore, the primary file group must always be
restored, together with the other files you specify.

Note: When doing a partial restore on a new server, you must do this from the
Data Protection for SQL CLI, because the relocation option is not valid with
partial restore using Data Protection for SQL Server GUI.

5.4.10 Group and file restore


File group backups should be followed by a transaction log backup. It is not
possible to restore a file group (or multiple groups) without having a current
transaction log backup, or sequence hereof, following the group backup.

When restoring a file group only, it is not possible to restore with recovery. Even
though it is possible to check the Recovery check box from the Data Protection
for SQL GUI, the database will be in a loading state after the restore.

Figure 5-13 on page 194 shows how to select a group backup together with a
transaction log backup.

Chapter 5. Data Protection for SQL Server restore 193


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 5-13 Group restore selection

5.4.11 Restore into another database


Sometimes you want to restore a database in the same server with a different
name. For this situation, you must specify the name of the database to restore
into, and if the database already exists on the SQL server, the Replace check box
must be checked. Also, if the file path is different than specified in the backup
object, it must be relocated, and if the files already exist but are in use by another
database, the physical file names must be changed.

To restore a database backup into another database, you must first select the
database objects to be restored. From Data Protection for SQL Server GUI, first
select the required objects. Then, right click on the backup objects on right panel,
and choose Restore Into option. A pop up screen will be displayed, and you must
enter the new database name, as shown in Figure 5-14 on page 195.

In our example, we will restore database Books into BooksNew. As the database
BooksNew does not yet exist, it is not necessary to check the Replace check box.

194 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

Figure 5-14 Restoring Books to BooksNew

As the database Books exists, it is necessary to relocate the BooksNew files. To


do so, right click on one backup object, and choose Relocate. Then, in the
Relocate pop up, choose where the datafiles will be restored. It is recommended
to change not only the location of the files but also the names of the physical files
to make it easier to identify them as datafiles from the new database. Figure 5-15
on page 196 shows an example of physical files relocated.

Chapter 5. Data Protection for SQL Server restore 195


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 5-15 BooksNew relocated files

Click Restore to restore the Books database into the new BooksNew database.

5.4.12 Restore to another machine - Legacy only


From the Tivoli Data Protection for SQL Server GUI perspective, restoring a SQL
Server database to a different machine is exactly the same procedure as restore
the database to the server where the backup was taken. SQL Server and Data
Protection for SQL Server must be installed and configured on both machines.

Note: Unlike Legacy backups, VSS Backups cannot be restored into an SQL
Server that has a different name.

When restoring a database to another server, you must logon to the Tivoli
Storage Manager server with the correct nodename to be able to retrieve the
backup.

The Tivoli Storage Manager nodename of the SQL Server, from which you
backed up the database, must be specified in the dsm.opt file to provide the
correct logon to the Tivoli Storage Manager server, and the tdpsql.cfg must
specify the server you want to restore to.

196 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

For more information, refer to Appendix F, “Restoring to an alternate machine” on


Data Protection for Microsoft SQL Server Installation and Users Guide,
SC32-9059.

5.4.13 Restore SQL Server 2000 backup to SQL Server 2005 database
In some situations, you may want to restore a database taken from SQL Server
2000 to a SQL Server 2005 instance. Data Protection for SQL Server allows you
to restore this type of backup in the same way as you restore backups taken from
the same database version.

While a Data Protection for SQL Server restore operation creates a SQL Server
2005 database, it does not garantee that your applications will run in SQL Server
2005 in the same way they ran in SQL 2000. We recommend that you check the
SQL Server documentation for all required steps, recommendations, restrictions
and pitfalls in the SQL Server version upgrade process, and spend the necessary
time to test your application against new database version.

5.5 Standby server


The concept of a standby (or warm backup) server is quite simple: after restoring
a full backup taken from the primary server to a standby server, all transaction
log files generated in the primary server are transfered and restored into the
standby server. This method does not guarantee no data loss for your SQL
Server environment; it can only protect all changes until the last transaction log
was acked up, so it is very important to periodically back up the primary
transaction log file. Also, it is necessary to periodically check if all transaction log
files backups are being correctly restored in the standby server to avoid any
unpleasant surprise when you need to use the standby server.

It is common to use standby servers to protect user databases, so keep in mind


that potentially you will need to create routines to propagate changes in system
databases, such as SQL Server logins, for example. Refer to the SQL Server
documentation for additional information.

In the following example we set up a standby server, step by step, from our virtual
SQL Server cluster CLUSQL01\SQL01 to our stand alone SQL Server COPPER,
using the Tivoli Storage Manager Scheduler.

Chapter 5. Data Protection for SQL Server restore 197


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Note: When implementing a standby solution, all transaction log backups


must be restored into the standby server. To simplify the operation, and avoid
transaction log backup gaps during the restore operation, we recommend to
use a common node name for all transaction log backups.

The following steps are necessary:


1. Register the node name SQL01_logship on the Tivoli Storage Manager
server, and create the client options file logship.dsm, containing parameters
for this node’s communication with the Tivoli Storage Manager server.
2. A full backup of the database LogShippingDB is performed on SQL01,
specifying the /tsmoptfile=logship.dsm. In this case, LogShippingDB uses
the full recovery model to ensure that SQL Server will log all data changes.
3. Restore LogShippingDB to the server COPPER with the option RECOVERY
unchecked. You can perform this operation using either the Data Protection
GUI or CLI interfaces, but it is mandatory to leave the database in
RECOVERY mode.
4. Transaction log backups of the LogShippingDB on SQL01 are performed
regularly. To determine the interval of the transaction log backups, you must
balance the overhead of the transaction log backups against your production
servers and the amount of changes in the database you can afford to lose in
case of primary server failure. In our case, we use 10 minutes. The script
used for SQL01\LogShippingDB backup is shown in Example 5-1.

Example 5-1 Transaction log backup script example


REM This command file is placed on the primary Server
REM C:\TSM_jobs\BackupLogShip.cmd
REM-----------------------------------------------------

set sql_dir=C:\Progra~1\Tivoli\TSM\TDPSql

C:
cd %sql_dir%
date < NUL >> %sql_dir%\sqlsched.log
time < NUL >> %sql_dir%\sqlsched.log

%sql_dir%\tdpsqlc backup LogShippingDB log /sqlserver=CLUSQL01\SQL01


/tsmoptfile=logshipdsm.opt

5. Use the Tivoli Storage Manager scheduler to run the cmd file shown in
Example 5-2 every 10 minutes. This will restore the transaction logs on the
standby server COPPER with NORECOVERY. The cmd file first restores all

198 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-5-restore.fm

active log backups for the database LogShippingDB from SQL server
CLUSQL01\SQL01. Then all log backups are inactivated. This must be done,
otherwise every log from the start (since the full backup) will be restored every
time the restore job runs.

Example 5-2 Stand by transaction log restore script example


REM This command file is placed on the standby server
REM C:\TSM_jobs\RestoreLogShip.cmd
REM------------------------------------------------------
set sql_dir=C:\Progra~1\Tivoli\TSM\TDPSql
C:
cd %sql_dir%
date < NUL >> %sql_dir%\sqlsched.log
time < NUL >> %sql_dir%\sqlsched.log
%sql_dir%\tdpsqlc restore LogShippingDB log=* /standby=”e:\temp\file2”
/fromsqlserver=CLUSQL01\SQL01 /tsmoptfile=logshipdsm.opt

%sql_dir%\tdpsqlc inactivate LogShippingDB log=*


/fromsqlserver=CLUSQL01\SQL01

If the file path for the database files is different on the standby server, use the
/relocate=logicalfilename /to=physicalfilename.

Note: Both cmd files specify to use /tsmoptfile=logshipdsm.opt. The client


options file, logshipdsm.opt, defines a different node name than the one
defined in dsm.opt. This is done so that the periodic full backup on the primary
server does not interfere with the log shipping. If the full backup is done with
the same nodename as the log backups for shipping, the log backups which
are active at the time the full backup is completed will be inactivated.

This implies more complicated scripting, since you will then have to check that
the latest log backup is already restored on the standby server prior to
performing the full backup, which inactivates all the prior backups.

The management class for the log objects should be defined so they are always
available on disk. This is done with the command define stgpool LOG_SHIP_DISK
disk description='Disk for Log Shipping’.

The schedules for the two jobs are defined on the Tivoli Storage Manager server.
Example 5-3 shows the schedule for the backup job.

Chapter 5. Data Protection for SQL Server restore 199


6148ch-5-restore.fm Draft Document for Review April 30, 2008 1:21 pm

Example 5-3 Scheduling backup of log


DEFine SCHedule tdpsql2_domain log_ship_backup
DESCription=”Log Ship every 10 minutes”
ACTion=command
OBJects=”C:\TSM_jobs\BackupLogShip.cmd”
STARTDate=TODAY
STARTTime=18:00
DURAtion=5
DURUnits=minutes
PERIods=600
PERUnits=seconds (seconds is not documented but it works)
DAYofweek=any

Example 5-4 shows the schedule for the restore job.

Example 5-4 Scheduling restore of log


DEFine SCHedule tdpsql2_domain log_ship_restore
DESCription=”Log Ship every 10 minutes”
ACTion=command
OBJects=”C:\TSM_jobs\RestoreLogShip.cmd”
STARTDate=TODAY
STARTTime=18:05
DURAtion=5
DURUnits=minutes
PERIods=600
PERUnits=seconds (seconds is not documented but it works)
DAYofweek=any

200 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

Chapter 6. Daily operations


This chapter describes the automation mechanisms IBM Tivoli Storage Manager
provides to initiate certain actions such as regular backup and housekeeping
activities. The following topics will be covered:
򐂰 6.1, “Automating backups” on page 202
򐂰 6.2, “Verifying and monitoring your backups” on page 216

© Copyright IBM Corp. 2008. All rights reserved. 201


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

6.1 Automating backups


When you have Tivoli Data Protection installed and configured, you need to
configure schedules to automate your backup strategy. You can schedule legacy
and VSS backups using the IBM Tivoli Storage Manager scheduler, or another
scheduler tool, for example, Tivoli Workload Scheduler to automate your
backups.

This section will cover how to configure the IBM Tivoli Storage Manager
scheduler to automate your backups.

6.1.1 IBM Tivoli Storage Manager scheduler considerations to


backup SQL Server
IBM Tivoli Storage Manager includes a central scheduling component that allows
the automatic initiation of administrative and client operations at predefined
times. An administrator creates and maintains the schedules in each policy
domain. Two types of scheduling are avalable: administrative and client
scheduling. SQL Server backups are scheduled using client schedules.

For client schedules, you can specify whether the client will poll the server
regularly to receive information about scheduled actions, or whether it must wait
to be contacted by the server to start a scheduled action. This option is called the
scheduling mode on the client and is set in the client options file. There is another
type of client schedule called clientaction, which is for actions which you want
to run only once as opposed to recurring scheduled actions.

Many factors influence the actual start time and duration of the various
operations, including the client backup window, storage pool sizes, amount of
data, and so on. Remember that is important to consider the timing and
sequencing of scheduled operations, otherwise the jobs can overlap and not
complete properly.

Consider the following parameters when defining a IBM Tivoli Storage Manager
schedule:
򐂰 If you are planning to schedule VSS and Legacy backups, do not overlap
these schedules in time, otherwise the second one will fail. SQL Server does
not allow Legacy and VSS backups at the same time.
򐂰 If you are using server-prompted scheduling mode, make sure that the Data
Protection for SQL option file has the TCPCLIENTADDRESS and
TCPCLIENTPORT options specified.

202 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

򐂰 If you change the Data Protection for SQL options file, it is necessary to
restart the service.

Attention: If you are running the scheduler service in a cluster environment,


use the Cluster Administrator to stop and restart your scheduler service.

򐂰 Data Protection for SQL creates its own log file with statistics about the
backed up database objects when the /logfile parameter is specified during
the tdpsqlc command. Output from scheduled commands are sent to the
scheduler log file (dsmsched.log). After scheduled work is performed, check
the log to ensure the work completed successfully.
򐂰 The preferred method of password management for scheduler operations is
to specify PASSWORDACCESS GENERATE in the dsm.opt file. If
PASSWORDACCESS GENERATE is not specified in the dsm.opt, then the
node password needs to be specified in the tdpsqlc command. To specify the
password, use the /tsmpassword parameter in the command file.

Once the Data Protection for SQL nodename has been registered to a IBM Tivoli
Storage Manager server and the SQL Server is installed and configured, you
need to perform the following steps:
1. On the IBM Tivoli Storage Manager server:
a. Define a schedule to execute a Windows command file. This schedule
must be defined in the policy domain to which the Data Protection for SQL
nodename is registered.
b. Associate the Data Protection for SQL node with the defined schedule.
2. On the machine where SQL Server and Data Protection for SQL are installed:
a. Install the IBM Tivoli Storage Manager scheduler client as a Windows
Service for Data Protection for SQL. If a scheduler already exists for the
regular IBM Tivoli Storage Manager backup client, install another one for
Data Protection for SQL.
b. Define a command file that contains the Data Protection for SQL
commands to do the desired backup
c. If you are running in a cluster server environment, install the IBM Tivoli
Storage Manager scheduler client as a Windows service on both cluster
nodes.

If you are running in a cluster server environment, create a new cluster resource
that represents the IBM Tivoli Storage Manager scheduler. Verify that the cluster
resource is started.

Chapter 6. Daily operations 203


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

6.1.2 Install IBM Tivoli Storage Manager scheduler client


In our redbook environment we already have the following setup:
򐂰 IBM Tivoli Storage Manager backup-archive installed on the SQL Server in
the directory C:\Program Files\Tivoli\TSM\baclient.
򐂰 Data Protection for SQL installed on the SQL Server in the directory
C:\Program files\Tivoli\TSM\TDPSql.
򐂰 The communication options is the dsm.opt option files point to IBM Tivoli
Storage Manager server to which the SQL data is to backed up. The options
file that is defined for Data Protection for SQL is used by the scheduler when
validating the node and password. The options file is also used when
contacting the IBM Tivoli Storage Manager for schedule information.

Perform the following on the SQL Server to set up the IBM Tivoli Storage
Manager client scheduler:
1. Login using a Windows account with administrative privileges.
2. Install a new IBM Tivoli Storage Manager service to backup the SQL Server
databases. See Example 6-1 on page 204.

Example 6-1 Install IBM Tivoli Storage Manager scheduler service


C:\Program Files\Tivoli\TSM\baclient>dsmcutil inst /name:"TSM SQL
Scheduler serv
ice" /node:CLUSQL01_DAILY /password:clusql01 /autostart:no
/clientdir:"c:\progra
m files\tivoli\tsm\baclient"
/optfile:"F:\tsmdata\dsm_sql_daily_sql01.opt" /star
tnow:no

Note: In a cluster environment, you need to run this command on both


machines. Remember to configure the following settings:
a. Change the /autostart option to NO, in a standalone environment
configure this option to yes
b. Move the SQL virtual server to the secondary node of the cluster to
create the scheduler service. Make sure the secondary node of the
cluster has ownership of the SQL virtual server
c. The primary node of the cluster must contain the command file on the
fileshare used to create the scheduler service
d. Copy the options file to a shared drive associated with the virtual server.

204 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

3. You can see the log information on the standard output. See Example 6-2 on
page 205.

Example 6-2 Check standard output


TSM Windows NT Client Service Configuration Utility
Command Line Interface - Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation, 1990, 2007, All Rights Reserved.
Last Updated Oct 25 2007
TSM Api Verison 5.5.0

Command: Install TSM Client Service


Machine: LIBRA(Local Machine)

Installing TSM Client Service:

Machine : LIBRA
Service Name : TSM SQL Scheduler service
Client Directory : c:\program files\tivoli\tsm\baclient
Automatic Start : no
Logon Account : LocalSystem
The service was successfully installed.

Creating Registry Keys ...

Updated registry value 'ImagePath' .


Updated registry value 'EventMessageFile' .
Updated registry value 'TypesSupported' .
Updated registry value 'TSM SQL Scheduler service' .
Updated registry value 'ADSMClientKey' .
Updated registry value 'OptionsFile' .
Updated registry value 'ClientNodeName' .
Updated registry value 'EventLogging' .

Generating registry password ...


Authenticating TSM password for node CLUSQL01_DAILY ...

Connecting to TSM Server via client options file


'F:\tsmdata\dsm_sql_daily_sql01
.opt' ...

Password authentication successful.

The registry password for TSM node CLUSQL01_DAILY has been updated.

Chapter 6. Daily operations 205


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

Note: If you need to make corrections after installing a service:


1. Issue the command to remove the service:
dsmcutil remove /name:”TSM SQL Scheduler service”
2. Run step 2 again to install the service

3. If you are in a cluster environment you need to start the scheduler service. So
execute the following steps:
a. Start the cluster administrator. Select the SQL Server Cluster group and
create a new resource to represent the SQL Server scheduler (File →
New → Resource). See Example 6-1 on page 206.

Figure 6-1 Create a new cluster resource

b. Set the Resource type to Generic Service and select your cluster group for
Group. See Figure 6-2 on page 207.

206 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

Figure 6-2 Create a generic service

c. Select the servers that this resource will be handling. See Figure 6-3 on
page 207.

Figure 6-3 Possible owners

d. Select the resource dependencies to start the scheduler service. In the


following example, we just select to have the database started. See
Figure 6-4 on page 208.

Chapter 6. Daily operations 207


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 6-4 Select resource dependencies

e. Set the Generic Service Parameters. See Figure 6-5 on page 208.

Figure 6-5 Generic Service Parameter

f. You need to add Registry Replication. Click Add. When the screen
appears, specify the root registry key. The root registry key needs to be the
exact key where the Data Protection for SQL node name is listed. The
registry key is of the format
SOFTWARE\IBM\ADSM\CurrentVersion\BackupClient\NODES\<nodena
me>\,<servername>,. Specify <nodename> as your cluster TSM SQL

208 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

node, and <servername> as the name of the server you are adding the
service. See Figure 6-6 on page 209.

Figure 6-6 Registry replication

g. You will see a message that the service was created successfully, similar
to Figure 6-7 on page 209.

Figure 6-7 Scheduler created successfully

h. To start the service, select the service, go to menu File → Bring online.
See Figure 6-8 on page 210.

Chapter 6. Daily operations 209


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

Figure 6-8 Start the scheduler service

6.1.3 Configure the scripts to backup your SQL Server


It is necessary to create the scripts on your SQL Server machine. The Data
Protection for SQL installation directory includes a sample command file to
perform a scheduled full legacy backup of all the SQL databases to the IBM Tivoli
Storage Manager server. The file is called sqlfull.smp, as shown in Example 6-3
on page 211. So, you just need to customize it with the appropriate value for you
environment, and create all types of backups that you need.

Note: You must specify COMPLETE PATHNAMES in the command file for all
file names and non-systems commands.

If you are in a cluster environment, your command file can reside on local
drives, but you need to remember to replicate the same command file to all
machines in the cluster. Alternatively, you can create the command file on a
shared drive. The TSMOPTFILE and LOGFILE options specified in your
command file must reflect the location of the options file and log file on the
SQL Server File Share.

210 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

Example 6-3 C:\Program files\tivoli\tsm\tdpsql\sqlfull.smp


@ECHO OFF
rem ==================================================================
rem sqlfull.smp sample command file
rem
rem Sample command file containing commands to do a scheduled full
rem backup of all SQL databases to an IBM Tivoli Storage Manager
rem server.
rem
rem This file is meant to be executed by the IBM Tivoli Storage
rem Manager central scheduler in response to a defined schedule on
rem the IBM Tivoli Storage Manager server.
rem
rem ==================================================================

rem ==================================================================
rem Replace "C:" with the drive where Data Protection for SQL
rem is installed. Update the directory to match the installation
rem directory that you chose when you installed the product.
rem ==================================================================

set sql_dir=C:\Progra~1\Tivoli\TSM\TDPSql

C:

cd %sql_dir%

rem ==================================================================
rem The two lines below put a date/time stamp in a log file for you.
rem Note: You can change "sqlsched.log" to whatever you prefer in
rem lines below.
rem ==================================================================

date < NUL >> %sql_dir%\sqlsched.log


time < NUL >> %sql_dir%\sqlsched.log

rem ==================================================================
rem Now call the command-line interface to do the backup:
rem
rem Replace "srvrname" with the name of the options file name you
rem plan to use.
rem
rem If SQL authentication is being used and the SQL login settings
have

Chapter 6. Daily operations 211


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

rem not been stored via the GUI, you must also specify the /sqluser
and
rem /sqlpassword options on the command below.
rem
rem In this example, we use the '*' to back up all of the databases
rem on the SQL server. Note that database 'tempdb' will not
rem be backed up.
rem
rem Note: You can change "sqlsched.log" and "sqlfull.log" to
rem whatever you prefer.
rem ==================================================================

%sql_dir%\tdpsqlc backup * full /tsmoptfile=%sql_dir%\srvrname.opt


/logfile=%sql_dir%\sqlfull.log >> %sql_dir%\sqlsched.log

Based on this sample script, you can create another script to backup all
databases on your server. See Example 6-4 on page 212 for an example.

Example 6-4 Script sql_backupfull.bat


@ECHO OFF
rem ==================================================================
rem Script to backup the database all databases
rem ==================================================================

rem ==================================================================
rem Set the installation directory
rem ==================================================================

set sql_dir=C:\Progra~1\Tivoli\TSM\TDPSql

C:

cd %sql_dir%

rem ==================================================================
rem The two lines below put a date/time stamp in a log file for you.
rem Note: You can change "sqlsched.log" to whatever you prefer in
rem lines below.
rem ==================================================================

date < NUL >> %sql_dir%\sqlsched.log


time < NUL >> %sql_dir%\sqlsched.log

rem ==================================================================

212 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

rem Backup command


rem ==================================================================

%sql_dir%\tdpsqlc backup * full /SQLSERVER=CLUSQL01\SQL01


/backupdestination=TSM /tsmoptfile=%sql_dir%\dsm_sql_daily_sql01.opt
/configfile=%sql_dir%\tdpsql_daily_sql01.cfg
/logfile=%sql_dir%\sqlfull_full_daily.log >> %sql_dir%\sqlsched.log

You can create another script to backup only one database. For example, the
script sql_backupdb.bat was created to backup just the dbsales7. If you intend to
backup more than one database you can separate the databases using commas.
See Example 6-5 on page 213.

Example 6-5 Script sql_backupdb.bat


@ECHO OFF
rem ==================================================================
rem Script to backup the database DBSales7
rem ==================================================================

rem ==================================================================
rem Set the installation directory
rem ==================================================================

set sql_dir=C:\Progra~1\Tivoli\TSM\TDPSql

C:

cd %sql_dir%

rem ==================================================================
rem The two lines below put a date/time stamp in a log file for you.
rem Note: You can change "sqlsched.log" to whatever you prefer in
rem lines below.
rem ==================================================================

date < NUL >> %sql_dir%\sqlsched.log


time < NUL >> %sql_dir%\sqlsched.log

rem ==================================================================
rem Backup command
rem ==================================================================

%sql_dir%\tdpsqlc backup DBSales7 full /SQLSERVER=CLUSQL01\SQL01


/backupdestination=TSM /tsmoptfile=%sql_dir%\dsm_sql_daily_sql01.opt

Chapter 6. Daily operations 213


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

/configfile=%sql_dir%\tdpsql_daily_sql01.cfg
/logfile=%sql_dir%\sqlfull_db_daily.log >> %sql_dir%\sqlsched.log

You can create another script to backup using VSS. For example, the script
sql_vss.bat was created to backup all database files. See Example 6-6 on
page 214.

Example 6-6 Script sql_vss.bat


@ECHO OFF
rem ==================================================================
rem Script to backup all SQL databases using VSS
rem ==================================================================

rem ==================================================================
rem Set the installation directory
rem ==================================================================

set sql_dir=C:\Progra~1\Tivoli\TSM\TDPSql

C:

cd %sql_dir%

rem ==================================================================
rem The two lines below put a date/time stamp in a log file for you.
rem Note: You can change "sqlsched.log" to whatever you prefer in
rem lines below.
rem ==================================================================

date < NUL >> %sql_dir%\sqlsched.log


time < NUL >> %sql_dir%\sqlsched.log

rem ==================================================================
rem Backup command
rem ==================================================================

%sql_dir%\tdpsqlc backup * full /SQLSERVER=CLUSQL01\SQL01


/backupdestination=LOCAL /backupmethod=VSS
/tsmoptfile=%sql_dir%\dsm_sql_daily_sql01_vss.opt
/configfile=%sql_dir%\tdpsql_daily_sql01.cfg
/logfile=%sql_dir%\sqlfull_db_daily.log >> %sql_dir%\sqlsched_vss.log

214 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

You can create another script to backup just the databases logs. For example,
the script sql_backuplog.bat, as shown in Example 6-7 on page 215.

Example 6-7 Script backup_sql_logs.bat


@ECHO OFF
rem ==================================================================
rem Script to backup the database SQL Logs
rem ==================================================================

rem ==================================================================
rem Set the installation directory
rem ==================================================================

set sql_dir=C:\Progra~1\Tivoli\TSM\TDPSql

C:

cd %sql_dir%

rem ==================================================================
rem The two lines below put a date/time stamp in a log file for you.
rem Note: You can change "sqlsched.log" to whatever you prefer in
rem lines below.
rem ==================================================================

date < NUL >> %sql_dir%\sqlsched.log


time < NUL >> %sql_dir%\sqlsched.log

rem ==================================================================
rem Backup command
rem ==================================================================

%sql_dir%\tdpsqlc backup * full /SQLSERVER=CLUSQL01\SQL01


/backupdestination=TSM /tsmoptfile=%sql_dir%\dsm_sql_daily_sql01.opt
/configfile=%sql_dir%\tdpsql_daily_sql01.cfg
/logfile=%sql_dir%\sqlfull_log_daily.log >> %sql_dir%\sqlsched.log

6.1.4 Configure schedules on the IBM Tivoli Storage Manager server


After creating the scheduler service and the script files on your SQL Server on
you need to create the schedules on the IBM Tivoli Storage Manager server.

Chapter 6. Daily operations 215


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

Perform the following steps on the IBM Tivoli Storage Manager server to create
the schedules to backup your SQL database:
1. Enter the following command to define the schedule. You can enter this
command on the server console or from an administrative client. See
Example 6-8 on page 216.

Example 6-8 Define schedule to backup database daily


tsm: ZAIRE>define schedule PDSQL backup_daily description="SQL Daily
Full Backup" action=command objects="c:\program
files\tivoli\tsm\tdpsql\sql_backupfull.bat" priority=2 starttime=20:00
duration=30 durunits=minutes period=1 perunits=days dayofweek=any

Session established with server ZAIRE: AIX-RS/6000


Server Version 5, Release 4, Level 0.0
Server date/time: 02/08/08 09:50:46 Last access: 02/08/08
05:34:08

ANR2500I Schedule BACKUP_DAILY defined in policy domain PDSQL.

2. Associate this schedule with a node name. See Figure 6-9 on page 216.

Example 6-9 Associate schedule to a node name


tsm: ZAIRE>define association pdsql backup_daily clusql01_daily
ANR2510I Node CLUSQL01_DAILY associated with schedule BACKUP_DAILY in
policy
domain PDSQL.

You can use the same examples to create additional schedules for your
environment, it is important to create a schedule to backup the SQL log files, and
if you have a different backup policy than daily backups you need to create
another schedule.

6.2 Verifying and monitoring your backups


You need to monitor your backups to check if the backups completed
successfully. This task is as important as the backup itself. Otherwise, you cannot
guarantee your restore if it is necessary.

216 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

6.2.1 Log management


If errors are reported in a backup operation, review the logs for any errors or
inconsistencies. There are a number of logs to check. .

IBM Tivoli Storage Manager activity log


The IBM Tivoli Storage Manager activity log contains all messages normally sent
to the server console during a server operation. The activity log can be monitored
using either administrative client command line or the IBM Tivoli Storage
Manager ISC Web interface. The Example 6-10 on page 217, shows the
contents of the activity log related to a Data Protection backup. You can see the
start session for the node to backup, the start session for the proxy agent (in this
case, we are using VSS) and the completion status of the backup, including
statistics.

Example 6-10 IBM Tivoli Storage Manager activity log


tsm: ZAIRE>q actlog begint=07:19:19

02/19/08 07:19:19 ANR0406I Session 335 started for node


CLUSQL01_DAILY (TDP
MSSQL Win32) (Tcp/Ip
libra.itso-sj.ibm.com(1266)).
(SESSION: 335)
02/19/08 07:19:20 ANR0406I Session 336 started for node
LIBRA_VSS (WinNT)
(Tcp/Ip libra.itso-sj.ibm.com(1293)).
(SESSION: 336)
02/19/08 07:19:20 ANR0397I Session 336 for node LIBRA_VSS has
begun a proxy
session for node CLUSQL01_DAILY. (SESSION:
336)
02/19/08 07:19:21 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'DBSales7' using shadow copy.(SESSION: 336)
02/19/08 07:19:21 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'DBTest1' using shadow copy.(SESSION: 336)
02/19/08 07:19:21 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing

Chapter 6. Daily operations 217


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

a full, TSM backup of object


'SqlServerWriter' component
'DBTest2' using shadow copy.(SESSION: 336)
02/19/08 07:19:21 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'DBTest3' using shadow copy.(SESSION: 336)
02/19/08 07:19:21 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'DBTest6' using shadow copy.(SESSION: 336)
02/19/08 07:19:22 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'LogShippingDB' using shadow copy.(SESSION:
336)
02/19/08 07:19:22 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'TEst4' using shadow copy.(SESSION: 336)
02/19/08 07:19:22 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'master' using shadow copy.(SESSION: 336)
02/19/08 07:19:22 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'model' using shadow copy.(SESSION: 336)
02/19/08 07:19:23 ANE4940I (Session: 336, Node: CLUSQL01_DAILY)
Performing
a full, TSM backup of object
'SqlServerWriter' component
'msdb' using shadow copy.(SESSION: 336)
02/19/08 07:19:23 ANR0406I Session 337 started for node
LIBRA_VSS (WinNT)
(Tcp/Ip libra.itso-sj.ibm.com(1324)).
(SESSION: 337)
02/19/08 07:19:23 ANR0397I Session 337 for node LIBRA_VSS has
begun a proxy

218 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

session for node CLUSQL01_DAILY. (SESSION:


337)
02/19/08 07:19:36 ANR0406I Session 338 started for node
LIBRA_VSS (WinNT)
(Tcp/Ip libra.itso-sj.ibm.com(1345)).
(SESSION: 338)
02/19/08 07:19:36 ANR0397I Session 338 for node LIBRA_VSS has
begun a proxy
session for node CLUSQL01_DAILY. (SESSION:
338)
02/19/08 07:20:08 ANR8337I LTO volume 027AKK mounted in drive
3580_1
(/dev/rmt0). (SESSION: 338)
02/19/08 07:20:08 ANR0511I Session 338 opened output volume
027AKK.
(SESSION: 338)
02/19/08 07:20:24 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'DBTest1'
finished
successfully.(SESSION: 338)
02/19/08 07:20:39 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'DBTest2'
finished
successfully.(SESSION: 338)
02/19/08 07:20:53 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'DBTest3'
finished
successfully.(SESSION: 338)
02/19/08 07:21:08 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'DBTest6'
finished
successfully.(SESSION: 338)
02/19/08 07:21:22 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'DBSales7' finished
successfully.(SESSION: 338)
02/19/08 07:21:37 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component
'LogShippingDB'
finished successfully.(SESSION: 338)

Chapter 6. Daily operations 219


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

02/19/08 07:21:52 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)


Backup of
object 'SqlServerWriter' component 'TEst4'
finished
successfully.(SESSION: 338)
02/19/08 07:22:06 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'master'
finished
successfully.(SESSION: 338)
02/19/08 07:22:16 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'model'
finished
successfully.(SESSION: 338)
02/19/08 07:22:22 ANE4941I (Session: 338, Node: CLUSQL01_DAILY)
Backup of
object 'SqlServerWriter' component 'msdb'
finished
successfully.(SESSION: 338)
02/19/08 07:22:22 ANR0514I Session 338 closed volume 027AKK.
(SESSION: 338)
02/19/08 07:22:27 ANR0399I Session 337 for node LIBRA_VSS has
ended a proxy
session for node CLUSQL01_DAILY. (SESSION:
337)
02/19/08 07:22:27 ANE4952I (Session: 336, Node: CLUSQL01_DAILY)
Total
number of objects inspected: 140
(SESSION: 336)
02/19/08 07:22:27 ANR0403I Session 337 ended for node LIBRA_VSS
(WinNT).
(SESSION: 337)
02/19/08 07:22:27 ANE4954I (Session: 336, Node: CLUSQL01_DAILY)
Total
number of objects backed up: 140
(SESSION: 336)
02/19/08 07:22:27 ANE4958I (Session: 336, Node: CLUSQL01_DAILY)
Total
number of objects updated: 0
(SESSION: 336)
02/19/08 07:22:27 ANE4960I (Session: 336, Node: CLUSQL01_DAILY)
Total
number of objects rebound: 0
(SESSION: 336)

220 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

02/19/08 07:22:27 ANE4957I (Session: 336, Node: CLUSQL01_DAILY)


Total
number of objects deleted: 0
(SESSION: 336)
02/19/08 07:22:27 ANE4970I (Session: 336, Node: CLUSQL01_DAILY)
Total
number of objects expired: 0
(SESSION: 336)
02/19/08 07:22:27 ANE4959I (Session: 336, Node: CLUSQL01_DAILY)
Total
number of objects failed: 0
(SESSION: 336)
02/19/08 07:22:27 ANE4961I (Session: 336, Node: CLUSQL01_DAILY)
Total
number of bytes transferred: 40.02 MB
(SESSION: 336)
02/19/08 07:22:27 ANE4963I (Session: 336, Node: CLUSQL01_DAILY)
Data
transfer time: 55.50 sec
(SESSION: 336)
02/19/08 07:22:27 ANE4966I (Session: 336, Node: CLUSQL01_DAILY)
Network
data transfer rate: 738.47 KB/sec
(SESSION: 336)
02/19/08 07:22:27 ANE4967I (Session: 336, Node: CLUSQL01_DAILY)
Aggregate
data transfer rate: 219.11 KB/sec
(SESSION: 336)
02/19/08 07:22:27 ANE4968I (Session: 336, Node: CLUSQL01_DAILY)
Objects
compressed by: 0%
(SESSION: 336)
02/19/08 07:22:27 ANE4964I (Session: 336, Node: CLUSQL01_DAILY)
Elapsed
processing time: 00:03:07
(SESSION: 336)
02/19/08 07:22:27 ANR0399I Session 336 for node LIBRA_VSS has
ended a proxy
session for node CLUSQL01_DAILY. (SESSION:
336)
02/19/08 07:22:27 ANR0403I Session 336 ended for node LIBRA_VSS
(WinNT).
(SESSION: 336)
02/19/08 07:22:27 ANR0399I Session 338 for node LIBRA_VSS has
ended a proxy

Chapter 6. Daily operations 221


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

session for node CLUSQL01_DAILY. (SESSION:


338)
02/19/08 07:22:27 ANR0403I Session 338 ended for node LIBRA_VSS
(WinNT).
(SESSION: 338)
02/19/08 07:22:27 ANR0403I Session 335 ended for node
CLUSQL01_DAILY (TDP
MSSQL Win32). (SESSION: 335)

For more information about the IBM Tivoli Storage Manager server activity log,
see the Tivoli Storage Manager Administrator Guide.

Data Protection for SQL log


Data Protection for SQL logs output to the file tdpsql.log in the Data Protection for
SQL installation directory; by default, this is C:\Program Files\tivoli\tsm\TDPSQL.
To change this location, use the parameter
/logfile=e:\tsmlogs\sqlfull_db_daily.log. Example 6-11 on page 222 shows some
sample output.

Example 6-11 Log SQL sqlfull_db_daily.log


=======================================================================
==
02/19/2008 08:48:08 Request : FULL BACKUP
02/19/2008 08:48:08 Database Input List :
DBSales7,DBTest1,DBTest2,DBTest3,DBTest6,LogShippingDB,master,model,msd
b,TEst4
02/19/2008 08:48:08 Group Input List :
02/19/2008 08:48:08 File Input List :
02/19/2008 08:48:08 Number of Buffers : 3
02/19/2008 08:48:08 Buffer Size : 1024
02/19/2008 08:48:08 Number of SQL Buffers : 0
02/19/2008 08:48:08 SQL Buffer Size : 1024
02/19/2008 08:48:08 Number of Stripes specified : 1
02/19/2008 08:48:08 Estimate : -
02/19/2008 08:48:08 Truncate Log? : -
02/19/2008 08:48:08 Wait for Tape Mounts? : Yes
02/19/2008 08:48:08 TSM Options File : C:\Program
Files\Tivoli\TSM\TDPSql\dsm_sql_daily_sql01.opt
02/19/2008 08:48:08 TSM Nodename Override : -
02/19/2008 08:48:08 Sqlserver : CLUSQL01\SQL01
02/19/2008 08:48:08
02/19/2008 08:49:59 Total SQL backups selected: 10
02/19/2008 08:49:59 Total SQL backups attempted: 10

222 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

02/19/2008 08:49:59 Total SQL backups completed: 10


02/19/2008 08:49:59 Total SQL backups excluded: 0
02/19/2008 08:49:59 Total SQL backups inactivated: 0
02/19/2008 08:49:59 Throughput rate: 289.37
Kb/Sec
02/19/2008 08:49:59 Total bytes transferred:
26,030,592
02/19/2008 08:49:59 Elapsed processing time: 87.85
Secs
02/19/2008 09:15:48
============================================================
02/19/2008 09:15:48 Request : VSS Backup
02/19/2008 09:15:48 Component List : 'DBSales7',
'DBTest1', 'DBTest2', 'DBTest3', 'DBTest6', 'LogShippingDB', 'TEst4',
'master', 'model', 'msdb'
02/19/2008 09:15:48 Backup Type : full
02/19/2008 09:15:48 Backup Destination : TSM
02/19/2008 09:15:48 Local DSMAGENT Node : libra_vss
02/19/2008 09:15:48 Offload to Remote DSMAGENT Node :
02/19/2008 09:15:48 Mount Wait : Yes
02/19/2008 09:15:48
------------------------------------------------------------
02/19/2008 09:18:55 VSS Backup operation completed with rc = 0
02/19/2008 09:18:55 Files Examined : 140
02/19/2008 09:18:55 Files Completed : 140
02/19/2008 09:18:55 Files Failed : 0
02/19/2008 09:18:55 Total Bytes : 41970349

IBM Tivoli Storage Manager API log


The IBM Tivoli Storage Manager API log, dsierror.log, s located n the Data
Protection installation directory. For example, authentication problem messages
are logged in this file, as shown in Example 6-12 on page 223.

Example 6-12 TSM dsierror.log


02/19/2008 08:44:54 ANS1025E Session rejected: Authentication failure
02/19/2008 08:46:21 ANS1025E Session rejected: Authentication failure
02/19/2008 08:46:30 ANS1025E Session rejected: Authentication failure
02/19/2008 08:47:07 ANS1025E Session rejected: Authentication failure
02/19/2008 08:47:19 ANS1025E Session rejected: Authentication failure
02/19/2008 08:47:33 ANS1025E Session rejected: Authentication failure

Chapter 6. Daily operations 223


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

Windows Event log


Using Event Viewer and event logs, you can gather information about hardware,
software and system problems. The VSS snapshot operations write detailed
information to the Application log.

The SQL Server writes event information for the Windows event log. You can look
for backup messages. See Figure 6-9 on page 224.

Figure 6-9 Backup events

Staging directory log files


Staging directory log files are generated when a VSS backup is initiated. For
every VSS operation that is run, a new subdirectory is created with the current

224 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

date and time stamp. In our scenario, this is


F:\adsm.sys\vss_staging\CLUSQL01_DAILY\9.43.86.45. Where the drive F:\ you
configure on dsm.opt for your local DSMAgent, the CLUSQL01_DAILY is the
node name and the 9.43.86.45 is the Tivoli Storage Manager TCP/IP Address.
Within this directory you would find audit log files which are created for each SQL
database. These files will check the VSS volumes for any errors, before using the
volumes.

Additional log files


You need to check the backup-archive client log files, these files also contain
output from the VSS backups:
򐂰 dsmsched.log: To check the result of the schedules
򐂰 dsmerror.log: If you have VSS errors, you can check the backup-archive
dsmerror.log
򐂰 agtsverr.log: This file is located in the backup-archive installation directory
and contains information about VSS backup
򐂰 dsmwebcl.log: This file is located in the backup-archive installation directory
and contains the DSMagent.

If your storage supports VSS instant restore, and you are using this function,
check also the fle IBMVSS.log.

6.2.2 Configure monitoring on IBM Tivoli Storage Manager server


The server and client messages provide a record of IBM Tivoli Storage Manager
activity that you can use to monitor the server. You can log server messages and
most client messages as events to one or more repositories called receivers. You
can log the events to any combination of the following receivers:
򐂰 Tivoli Storage Manager server console and activity log
򐂰 FIle and user exits
򐂰 Tivoli Event Console
򐂰 Simple Network Management Protocol (SNMP)
򐂰 Event server receiver (Enterprise Event Logging)

You can filter the types of events to be enabled for logging. For example, you can
enable some messages for one receiver and another messages to other
receivers.

Chapter 6. Daily operations 225


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

To configure event logging, you need to enable or disable logging for one or more
event types and for one or more receivers and begin or end logging to one or
more receivers.

When you enable or disable events, you can specify the following:
򐂰 A message number or an event severity (ALL, INFO, WARNING, ERROR, or
SEVERE)
򐂰 Events for one or more client nodes (NODENAME) or for one or more servers
(SERVERNAME).

For example, to send TDP for SQL messages to a Tivoli Enterprise Console®,
assuming that you already have a TEC Server in your environment, you need to
follow the steps:
1. In the server options file (dsmserv.opt), specify the location of the host on
which the Tivoli server is running. See Example 6-13 on page 226, to specify
a TEC server at the IP address 9.43.86.50:155

Example 6-13 dsmserv.opt TEC configuration


techost 9.114.22.345
tecport 1555

2. Begin event logging for the Tivoli receiver using the BEGIN EVENTLOGGING Tivoli
Storage Manager administrative command. See Example 6-14 on page 226.

Example 6-14 execute the command on your tsm server prompt


begin eventlogging tivoli

3. On the IBM Tivoli Storage Manager server you need to configure the TDP for
SQL events. See Example 6-15 on page 226

Example 6-15 Enable events to send to TEC


enable events tivoli <event id> Nodename=<node>

The events for Data Protection for SQL, have the string ACO followed by
four-digit numbers. Remember that the application client must have enhanced
T/EC support enabled in order to route the above messages to the Tivoli Event
Console.

226 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

6.2.3 Troubleshooting tips


If you have problems, it is important to look for error messages in the log files
which we have just described. The first step to solving a problem is diagnosis.
Here are some hints to analyze and isolate the problem:
򐂰 Can you connect to SQL Server and Tivoli Storage Manager server using
their native client tools? Can you remotely connect to each server?
򐂰 Are the firewall and network connections between the Tivoli Storage Manager
server and the SQL Server correctly configured?
򐂰 Is Tivoli Data Protection for SQL Server configured to access SQL Server on
its current listening port? If not, refer to 3.2.10, “Specifying Data Protection for
SQL preferences” on page 103, for information on how to configure Tivoli
Data Protection for SQL Server to access the SQL Server when SQL Server
is configured to listen on a non default port - other than 1433.
򐂰 Analyze whether the problem concerns all or individual servers. If only one
server is affected, check the individual configuration
򐂰 Are all databases affected, or just one database? If only one database is
affected, ask your Database administrator, to check, if there is some individual
error on that database
򐂰 Check if the problem is constant or intermittent. What other things are
happening that could affect the operation?
򐂰 If the problem occurs when performing a scheduled backup, try to running the
same backup operation manually, it could be an error on your script.
򐂰 Is is a Legacy or a VSS backup?
򐂰 Try to reproduce the error on both interfaces, GUI and CLI.

Tracing Data Protection for SQL


The Data Protection client uses the Tivoli Storage Manager API to communicate
with the Tivoli Storage Manager server and provide data management functions.
You could run a trace to determine where the problem exists. The trace will give
you detailed trace information about the action you perform. If you use this
parameter, trace information will be written to the trace file or sent to the console.
If you want this information to be sent to a file, specify:
򐂰 /TraceFile=x:\testtrace.log
You can place this option in the dsm.opt file of the SQL Server server for
legacy backups, or in your Local or Remote DSMAgent dsm.opt file. If this file
does not exist, a new one will be created. If the file exists, the new events are
appended to the file.
򐂰 /TraceFlag=ALL

Chapter 6. Daily operations 227


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

This is the default. You could trace only specific events, but this may not give
you the required information to determine your problem. For 90% of the
cases, using /traceflag=all is fine. You can place this option in your dsm.opt
file for legacy backups.
򐂰 TraceFlag ALL_VSS
This option you can use on your dsm.opt file for you local and remote
dsmagent. for VSS backups.

Data Protection for SQL with VSS backup-restore support


Data Protection for SQL provides support for protection Microsoft SQL
databases through two different methods. The most method is through
Microsoft’s Server Managed Objects (SMO) application program interface (API).
Data Protection for SQL can use Microsoft’s Virtual Shadow Copy Server (VSS).

If you encounter a problem during Data Protection for SQL processing using VSS
for Backup and Restore, follow the steps to try to resolve the problem:
1. Retry the operation that failed.
2. If the problem persists, close other applications, especially those applications
that interact with SQL. Retry the operation that failed.
3. If the problem persists:
a. Shut down the SQL Server
b. Restart the SQL Server
c. Run the operation that failed
4. If the problem persists:
a. Shut down the entire machine
b. Restart the machine
c. Run the operation that failed.
5. If the problem persists, open a Ticket on IBM Support.

Determining
VSS issue if the problem is a Data Protection for SQL or a general
The Data Protection client interacts closely with the backup-archive client
(DSMAGENT), which performs all of the Virtual Shadow Copy Service (VSS)
operations. Determine first if the problem is with Microsoft's VSS service or with
the Tivoli Storage Manager.

Perform the following steps to try to isolate the source of the error:
1. Test the connectivity between the Data Protection client and the Tivoli
Storage Manager dsmagent. Issue the TDPSQLC QUERY SQL command on the
machine where the SQL server is installed to verify that your installation and

228 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

configuration is correct. This command returns information about SQL server


status and VSS components, see Example 6-16 on page 229.

Example 6-16 Output “tdpsqlc query sql” command


C:\Program Files\Tivoli\TSM\TDPSql>tdpsqlc query sql
/tsmoptfile="C:\Program Fil
es\Tivoli\TSM\TDPSql\dsm_sql_daily_sql01.opt" /configfile="C:\Program
Files\Tivo
li\TSM\TDPSql\tdpsql_daily_sql01.cfg

IBM Tivoli Storage Manager for Databases:


Data Protection for Microsoft SQL Server
Version 5, Release 5, Level 0.0
(C) Copyright IBM Corporation 1997, 2007. All rights reserved.

Connecting to SQL Server, please wait...

SQL Server Information


----------------------

SQL Server Name ........................ CLUSQL01\SQL01


SQL Server Version ....................... 9.0.3042 (SQL Server 2005)

Volume Shadow Copy Service (VSS) Information


--------------------------------------------

Writer Name : SqlServerWriter


Local DSMAgent Node : libra_vss
Remote DSMAgent Node : leo_vss
Writer Status : Online
Selectable Components : 10

If the TDPSQLC QUERY SQL command does not return all of this information, you
might have a proxy configuration problem.
2. Use the vssadmin or vshadow utility to recreate the VSS operation standalone -
that is, without any involvement of Tivoli Storage Manager. When VSS
operations are failing, use these programs to recreate the error to determine if
this is a general VSS problem or a problem within the Tivoli Storage Manager
code.
– vssadmin

Chapter 6. Daily operations 229


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

A utility that is pre-installed with your operating system. It can display current
volume shadow copy backups and all installed shadow copy writers and
providers in the command window. The following are example VSSADMIN
commands:
• VSSADMIN LIST WRITERS
• VSSADMIN LIST PROVIDERS
• VSSADMIN LIST SHADOWS
– vshadow
A utility included with Microsoft's Volume Shadow Copy Services SDK that
can be used to exercise most of the VSS infrastructure, such as
creating/querying/deleting shadow copies. You can also use vshadow to create
both persistent and non-persistent shadow copies, transportable snapshots,
as well as assign a drive letter or mount point to a shadow copy. The following
can be determined by using the vssadmin or vshadow utility:
• Verify VSS Provider configurations and setup
• Rule out any possible VSS problems before running the Tivoli Storage
Manager VSS functions
• That you might have a VSS configuration problem or a real hardware
problem if an operation does not work with vshadow/vssadmin
• That you might have a Tivoli Storage Manager problem if an operation
works with vshadow/vssadmin but not with the Tivoli Storage Manager
Perform the following tests to ensure that VSS is working correctly:
– Test non-persistent shadow copy creation and deletion
• Run “vshadow -p d: e:” (where d:\ and e:\ are the SQL Server
database and log volumes.
• Repeat the previous step four times
• Inspect the Windows Event Log to ensure that things look appropriate
– Test persistent shadow copy creation and deletion
• Run “vshadow -p d: e:” (where d:\ and e:\ are the SQL Server
database and log volumes. You may have to run “vshadow -da” to
remove this if you do not have enough space.
• Repeat the previous step four times
• Inspect the Windows Event Log to ensure that things look appropriate
– Test non-persistent transportable shadow copy creation and deletion (VSS
Hardware Provider environments only)

230 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ch-6-oper.fm

• Run “vshadow -p -t=export.xml d: e:” (where d:\ and e:\ are


the SQL Server database and log volumes.
• Copy the resultant “export.xml” file from machine 1 to machine 2 before
performing the next step.
• In the machine you have set aside off-load, run “vshadow
-i=export.xml”
• Inspect the Windows Event Log to ensure that things look appropriate
If any of these tests fail repeatedly, there is hardware configuration problem or
a real VSS Problem. Consult your hardware documentation for known
problems or search Microsoft Knowledge Database for any information. If all
tests pass, continue to next text.
– Recreate your specific problem by using vshadow. If you can only recreate
your problem through a series of steps (for example: a backup fails only
when you perform two consecutive local backups), try to perform those
same tests by using vshadow.
• SQL VSS backups to Local are simulated by running a vshadow
persistent snapshot.
• SQl VSS backups to the Tivoli Storage Manager are simulated by
running a vshadow non-persistent snapshot.
• SQL VSS backups to Local and to the Tivoli Storage Manager are
simulated by running a vshadow persistent snapshot.
• Offloaded SQL VSS backups to the Tivoli Storage Manager are
simulated by running a vshadow non-persistent, transportable snapshot.
Refer to the VSHADOW documentation for the specific commands for performing
backups.
If you can recreate the problem, it most likely is a general VSS issue. Refer to
Microsoft Knowledge Database for information. If your operation passes
successfully with vshadow, it most likely is a Tivoli Storage Manager/Data
Protection for SQL client problem.

Gathering files before calling IBM


Several log files and other data can be collected for Data Protection for SQL
server diagnosis.

Gather as many of the following files as possible before contacting IBM Support:
*
򐂰 The Data Protection for SQL configuration file. The default configuration file is
tdpsql.cfg.

Chapter 6. Daily operations 231


6148ch-6-oper.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 The Data Protection for SQL Tivoli Storage Manager application programming
interface (API) options file. The default options file is dsm.opt.
򐂰 The Tivoli Storage Manager registry hive export.
򐂰 The SQL Server registry hive export.
򐂰 The Tivoli Storage Manager Server activity log. The Data Protection client
logs information to the server activity log. A Tivoli Storage Manager
administrator can view this log for you if you do not have a Tivoli Storage
Manager administrator user ID and password.
򐂰 If the Data Protection client is configured for LAN-free data movement, also
collect the options file for the Tivoli Storage Manager storage agent. The
default name for this file is dsmsta.opt.
򐂰 Any screen shots or command-line output of failures or problems.

Log files can indicate the date and time of a backup, the data that is backed up,
and any error messages or completion codes that could help to determine your
problem. The following are the Tivoli Storage Manager log files to gather:
򐂰 The Data Protection for SQL log file. The default location of this file is
C:\Program Files\Tivoli\TSM\TDPSql\tdpsql.log
򐂰 The Tivoli Storage Manager API Error log file. The default location of this file
is C:\Program Files\Tivoli\TSM\TDPSql\dsierror.log
򐂰 The DSMAGENT error log file. The default location of this file is C:\Program
Files\Tivoli\TSM\baclient\dsmerror.log

The Windows event log receives information from the SQL Server and many
different components involved during a Virtual Shadow Copy *Service (VSS)
operation.

The following VSS provider log files can also be helpful, if applicable:
򐂰 System Provider - (Windows Event Log)
򐂰 IBM System Storage SAN Volume Controller, DS6000, DS8000 - D:\Program
Files\IBM\Hardware Provider for VSS\IBMVss.log
򐂰 NetApp or N series- D:\Program Files\SnapDrive\*.log

232 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

Appendix A. Tivoli Storage Manager


family of products
This chapter provides a product overview of the Tivoli Storage Manager family of
products that may be used with the solutions in this IBM Redbook. The products
include:
򐂰 Tivoli Storage Manager
򐂰 Tivoli Storage Manager Express
򐂰 Tivoli Storage Manager Basic Edition
򐂰 Tivoli Storage Manager Extended Edition
򐂰 Tivoli Storage Manager Space Management
򐂰 Tivoli Storage Manager for Space Management
򐂰 Tivoli Storage Manager for Hierarchical Storage Manager (HSM) for Windows
򐂰 Tivoli Storage Manager for Storage Area Networks
򐂰 Tivoli Continuous Data Protection for Files
򐂰 Tivoli Storage Manager for System Backup and Recovery
򐂰 Tivoli Storage Manager for Databases
򐂰 Tivoli Storage Manager for Enterprise Resource Planning
򐂰 Tivoli Storage Manager for Mail
򐂰 Tivoli Storage Manager for Microsoft SharePoint®
򐂰 Tivoli Storage Manager for Advanced Copy Services
򐂰 Tivoli Storage Manager for Copy Services

© Copyright IBM Corp. 2008. All rights reserved. 233


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

Tivoli Storage Manager


IBM Tivoli Storage Manager enables you to protect your organization's data from
failures and other errors by storing backup, archive, space management, and
bare-metal restore data, as well as compliance and Disaster Recovery data in a
hierarchy of offline storage. Because it is highly scalable, Tivoli Storage Manager
can help protect computers running a variety of different operating systems, on
hardware ranging from notebooks to mainframe computers and connected
together through the Internet, wide area network (WAN), local area network
(LAN), or storage area network (SAN).

It uses Web-based management, intelligent data move-and-store techniques,


and comprehensive policy-based automation, which work together to help
increase data protection and potentially decrease time and administration costs.
Because it is highly scalable, Tivoli Storage Manager can also help protect
computers running a variety of different operating systems.

IBM Tivoli Storage Manager's core functions include:


򐂰 Backup and recovery management
򐂰 Archive management

IBM Tivoli Storage Manager Extended Edition adds additional support through:
򐂰 Disaster preparation planning and recovery (Disaster Recovery Manager)
򐂰 NDMP backup for Network Attached Storage
򐂰 Small and large tape libraries

Attributes that set Tivoli Storage Manager apart include:


򐂰 Easy management of multiple types of inactive data in a hierarchical
repository
򐂰 Lower storage cost through intelligent hierarchy of storage
򐂰 Centralized, comprehensive management
򐂰 Reduced network bandwidth through intelligent data movement
򐂰 Policy-based automation

IBM Tivoli Storage Manager family of offerings include:


򐂰 IBM Tivoli Storage Manager for Application Servers
򐂰 IBM Tivoli Storage Manager for Databases
򐂰 IBM Tivoli Storage Manager for Enterprise Resource Planning
򐂰 IBM Tivoli Storage Manager for Copy Services
򐂰 IBM Tivoli Storage Manager for Advanced Copy Services
򐂰 IBM Tivoli Storage Manager for Mail
򐂰 IBM Tivoli Storage Manager for System Backup and Recovery
򐂰 IBM Tivoli Storage Manager for Data Retention

234 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

Optional Additions to Tivoli Storage Manager include:


򐂰 IBM Tivoli Storage Manager for Storage Area Networks
򐂰 IBM Tivoli Storage Manager for Space Management

For more product information, see the following Web site:

http://www.ibm.com/software/tivoli/products/storage-mgr/

IBM Tivoli Storage Manager Express


IBM Tivoli Storage Manager Express is suitable for small and medium
businesses with a comparatively simple IT environment, or at departments within
an enterprise that does not need the full suite of IBM Tivoli Storage Manager
features. It provides a subset of IBM Tivoli Storage Manager features, focusing
on backup and recovery for Windows operating system environments between 5
and 20 client machines. The features of IBM Tivoli Storage Manager Express
are:
򐂰 Easy installation
IBM Tivoli Storage Manager Express takes less than one hour to install,
configure, and start running backups.
򐂰 Simplified administration GUI
A new GUI simplifies administration, and operational reporting is integrated.
Client software deployment is also included. Intuitive web-based interface.
򐂰 Fully upgradeable
It can be easily upgradeed to IBM Tivoli Storage Manager Extended Edition.
򐂰 Simplified tape management
Uses traditional methods such as Grandfather/Father/Son backup sets
simplify tape rotation. All tape management is fully automated
򐂰 Automatic configuration
Clients are automatically configured with scheduled backups using industry
best practices.

IBM Tivoli Storage Manager Express supports:


򐂰 Windows 2003 as the platform for the IBM Tivoli Storage Manager Express
server
򐂰 From 5 to 20 client systems
򐂰 A database size up to 20 GB

Appendix A. Tivoli Storage Manager family of products 235


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 LAN-based systems and devices


򐂰 Optional backup for MS Exchange and MS SQL Server

For more information, see


򐂰 Deployment Guide Series: IBM Tivoli Storage Manager Express, SG24-7033
򐂰 http://www.ibm.com/software/tivoli/products/storage-mgr-express/

IBM Tivoli Storage Manager Basic Edition


IBM Tivoli Storage Manager Basic Edition contains a rich set of features and
provides the core functions of backup, recovery, and archive management.

Backup/restore methodology
Tivoli Storage Manager keeps track of each backed up file in its own internal
relational database, maintaining an individual record of each version of each file
which is backed up so that it can be accurately restored in one step. The
progressive backup methodology used means that only changed files are backed
up - there is no need for periodic full backups after the first initial operation. This
saves time and storage space. Version control allows user-defined policies to
dictate how many versions are kept of each file, and for how long they are kept.
Backups can be automatically schedule to make sure they are reliably executed.
track data wherever it is stored, delivering direct one-step file restore.

Policy management
Tivoli Storage Manager policies allow you to specify:
򐂰 What data is backed up? You can reduce backup times if unneeded files are
not backed up.
򐂰 How many versions to keep? What about if the file is deleted?
򐂰 How long to keep extra file versions, or the last remaining version of a deleted
file?
򐂰 Where to initially store the backup? Backups can go to disk first, or direct to
tape - for example, for large database backups.

These policies can be set for all client nodes, for a group of client nodes, for
individual client nodes, for certain files on a client node, down to individual
policies for each individual file - allowing you to precise control how much storage
space will be needed for the backups.

236 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

Archive
Tivoli Storage Manager archive allows you to archive particular files or groups of
files for a designated period of time. Archived files are separate from the normal
backup cycle, and are therefore not managed by version. You simply specify
which files to archive, and a retention period. You can create a description of
each archive package so you can search these descriptions when you have to
retrieve files.

Efficient use of storage space


You can define tiered levels of backup storage, so that backups can be directed
first to a disk pool - for fast backup and restore. Data can be later automatically
migrated to tape or optical media, for most cost-effective storage.

This sequential media is automatically managed through the process of


reclamation. Space on a sequential volume becomes reclaimable as files expire
or are deleted from the volume. For example, files become obsolete because of
aging or limits on the number of versions of a file. In reclamation processing, the
server rewrites files on the volume being reclaimed to other volumes in the
storage pool, making the reclaimed volume for reuse. This helps to keep the
sequential volumes more efficiently utilized, again, to speed up the restore
process.

With collocation enabled, the server attempts to keep files belonging to a group
of client nodes, a single client node, client file space or the last active data for a
client node, on minimal number of sequential access storage volumes. You can
set collocation for each sequential access storage pool when you define or
update the pool. By using collocation, you can reduce the number of volumes
required when user restore, retrieve, or recall a large number of files from the
storage pool. Collocation thus reduces the amount of time required for these
operations.

Library and device support


Tivoli Storage Manager Basic Edition supports libraries with up to 3 tape drives
and up to 40 cartridges capacity. Larger libraries can be accommodated but with
only 3 devices and 40 slots enabled.

You can find more information on IBM Tivoli Storage Manager Basic Edition at
the Web site:
http://www.ibm.com/software/tivoli/products/storage-mgr/

Appendix A. Tivoli Storage Manager family of products 237


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

IBM Tivoli Storage Manager Extended Edition


The Extended Edition of IBM Tivoli Storage Manager expands on the features
and possibilities of the Basic Edition described in the previous section.

IBM Tivoli Storage Manager Extended Edition adds disaster recovery planning
capability for the server, NDMP (Network Data Management Protocol) control for
network-attached storage (NAS) filers, and support for larger capacity tape
libraries and more tape drives.

You can find more information at:


http://www.ibm.com/software/tivoli/products/storage-mgr-extended/

Disaster Recovery Manager


The Disaster Recovery Manager (DRM) component of IBM Tivoli Storage
Manager Extended Edition offers various options to configure, control, and
automatically generate a disaster recovery plan to reconstruct the original
environment. The plan contains the information, scripts, and procedures needed
to automate restoration and help ensure quick recovery of data after a disaster.
The scripts contain the commands necessary to rebuild theIBM Tivoli Storage
Manager server.

One of the key features of IBM Tivoli Storage Manager and Disaster Recovery
Manager is the ability to track media in all possible states, such as onsite, in
transit, or in a vault. The media movement features assist greatly with the daily
tasks of sending disaster recovery media offsite, and receiving expired media
onsite for reuse. With these features the system administrator can quickly locate
all available copies of data.

Disaster Recovery Manager functions help maintain business continuity by:


򐂰 Establishing and helping to automate a thorough server disaster recovery
plan — clients can then subsequently restore their data from the server if
required, and can continue their daily backup procedures.
򐂰 Ensuring that vital site-specific information is available in the same plan.
򐂰 Automating vital recovery steps to return the IBM Tivoli Storage Manager
server and backup environment to normal operation.
򐂰 Managing and identifying offsite media needed for recovery.
򐂰 Tracking and reporting destroyed systems in the event of a disaster.
򐂰 Storing client configuration information and assigning client recovery
priorities.

238 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

With Disaster Recovery Manager you can recover at an alternate site, on a


replacement computer hardware with a different hardware configuration, and with
people who are not familiar with the applications. The disaster recovery plan can
be periodically tested to certify the recoverability of the server. The disaster
recovery plan can (and should be) be recreated easily every day so that it stays
up to date.

NDMP backup for Network Attached Storage


For NAS devices, Tivoli Storage Manager Extended Edition uses Network Data
Management Protocol (NDMP) to perform high-performance, scalable backups
and restores. NDMP-based backups and restores minimize network traffic and
transfer data outboard of the Tivoli Storage Manager client and server. NDMP
enables a full and differential file-system image backup and restore of Network
Appliance file servers with operating system Data ONTAP® 6.1.1 or higher, and
EMC Celerra systems. Multiple backup and restore operations can be performed
simultaneously.

The NDMP backup and restore features are fully integrated with Tivoli Storage
Manager Extended Edition server and client. No extra software is required on the
server, client, or NAS appliance.

Extended library and device support


Tivoli Storage Manager Extended Edition supports larger tape libraries, thus
removing the 40-cartridge limit for library capacity, and allowing more than three
tape drives within a single library.

Optional additional products


IBM Tivoli Storage Manager can be integrated with a number of optional
applications that together form a powerful integrated storage management
solution. These include:
򐂰 IBM Tivoli Storage Manager for Space Management
򐂰 IBM Tivoli Storage Manager for Hierarchical Storage Manager (HSM) for
Windows
򐂰 IBM Tivoli Storage Manager for Storage Area Networks
򐂰 IBM Tivoli Continuous Data Protection for Files
򐂰 IBM Tivoli Storage Manager for System Backup and Recovery
򐂰 IBM System Storage Archive Manager

For a full product listing, visit:


http://www.ibm.com/software/tivoli/products/

Appendix A. Tivoli Storage Manager family of products 239


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

IBM Tivoli Storage Manager for Space Management


IBM Tivoli Storage Manager for Space Management provides hierarchical
storage management (HSM) to automatically migrate rarely-accessed files to
alternative storage, without disrupting the most frequently used files in local
storage. Migrated files are automatically and transparently recalled to primary
storage when needed by applications or users. Administrators and users are
freed from manual filesystem maintenance tasks, and more online disk space is
available for more important active data. IBM Tivoli Storage Manager for Space
Management can also help defer the need to purchase additional disk storage for
clients, by making optimal use of available client storage.

IBM Tivoli Storage Manager for Space Management is supported on AIX,


HP-UX, Solaris™, and Linux.

IBM Tivoli Storage Manager for HSM for Windows


IBM Tivoli Storage Manager for HSM for Windows provides hierarchical storage
management functionality to the Windows platform. As with IBM Tivoli Storage
Manager for Space Management, HSM for Windows automatically migrates
rarely-accessed files to alternative storage, without disrupting the most frequently
used files in local Windows file systems. Similarly, migrated files are
automatically and transparently recalled to their original location when needed by
applications or users.

HSM for Windows allows various levels of granularity for migration of files. Files
can be migrated individually, and file systems can be partially or fully migrated,
based on a comprehensive set of policy options.

IBM Tivoli Storage Manager for Storage Area Networks


IBM Tivoli Storage Manager for Storage Area Networks software enables
SAN-connected IBM Tivoli Storage Manager servers and client computers to
make maximum use of their SAN connection to storage. Both servers and client
computers are able to perform the majority of their backup/restore and
archive/retrieve data transfers over the SAN instead of the LAN. Data transfers
via the SAN can be either directly to tape or disk storage pools. The impact of
data protection on the LAN is greatly reduced, as is CPU utilization on both client
and server. For computers running Windows, some SAN configurations allow
specific SAN devices to perform data movements directly to and from some tape
devices, further reducing client and server CPU utilization.

240 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

IBM Tivoli Continuous Data Protection for Files


According to industry surveys, almost 70 percent of corporate data exists on
laptop (mobile computer) or desktop machines, and less than 8 percent of it is
backed up regularly. For laptop, desktop, and file server machines that contain
important, critical, or sensitive data that is constantly being updated, a typical
24-hour backup cycle may not be sufficient to provide adequate data protection.
The addition of Tivoli Continuous Data Protection for Files provides a client
machine with the capability of being able — transparently, in real time — to back
up a file to a IBM Tivoli Storage Manager server as soon as the file is saved. Files
that are backed up by this method are managed in the same ways as other
corporate data by the IBM Tivoli Storage Manager server.

Tivoli Continuous Data Protection for Files was developed with laptop (mobile
computer) and desktop users in mind, but can be applied to any client with a high
rate of change of data on its file systems.

Tivoli Continuous Data Protection for Files provides clients with true point-in-time
recoverability. It is supported on Windows platforms. For more information, see:
http://www.ibm.com/software/tivoli/products/continuous-data-protection/

IBM Tivoli Storage Manager for System Backup and Recovery


IBM Tivoli Storage Manager for System Backup and Recovery (SysBack™)
provides a flexible backup tool for AIX systems (System p) to help protect data
and provide bare machine recovery capabilities. It offers comprehensive system
backup, restore, and reinstallation methods.

V5.6 and higher of Sysback are integrated with IBM Tivoli Storage Manager,
allowing backups to be stored on a IBM Tivoli Storage Manager server.

Sysback provides the following features and benefits:


򐂰 Backup and recovery options:
– Full system installation image, known to AIX administrators as a mksysb.
– Volume group backup.
– File system backup.
– File or directory backup.
– Raw logical volume backup.
– Recovery of all or part of the system.

Appendix A. Tivoli Storage Manager family of products 241


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

– Allows a system installation image (mksysb) from one system to be


installed onto another system with either identical or different hardware
configurations (also known as cloning).
򐂰 Central management and automation tools:
– Utilities for creation of backup scripts and schedules for easier task
automation.
– Backup, list, and verify operations are quickly assessed via a completion
status-tracking log.
– “Pull” client backup feature enables the administrator to manage backup
operations centrally from a single server (remote or local).
򐂰 Network boot and install features in:
– Network boot via remote SysBack functions (Classic Boot).
– Network Installation Management (NIM) resources (NIM Resource Boot).
򐂰 Offline Mirror Backup options:
– Splits specified AIX mirrors to enable access to inactive (offline) copies of
data, allowing simultaneous user and system access to the active copies.

IBM System Storage Archive Manager


IBM System Storage Archive Manager (SSAM) facilitates compliance with
regulatory requirements. It helps manage and simplify the retrieval of the ever
increasing amount of data that organizations must retain for strict records
retention regulations. Many of the regulations demand the archiving of records,
e-mails, design documents and other data for many years, in addition to requiring
that the data is not changed or deleted.

SSAM's existing policy-based data management capabilities help organizations


meet many of the regulatory requirements of various government and industry
agencies. But some new regulations require additional safeguards on data
retention. IBM System Storage Archive Manager provides data retention policies
that help meet these new regulations.

SSAM makes the deletion of data before its scheduled expiration extremely
difficult. Short of physical destruction to storage media or server, or deliberate
corruption of data or deletion of the Archive Manager database, Archive Manager
will not allow data on the storage managed by the SSAM server to be deleted
before its scheduled expiration date. Content management and archive
applications can apply business policy management for ultimate expiration of
archived data at the appropriate time.

242 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

SSAM hierarchical storage capabilities provides policies, so that data is stored


on the type of media that best meets that data's longevity, access speed, and
cost needs.

Movement of the data from one media type to another (as media needs change,
or as new types of media become available) is achieved by migration. Migration
automates moving of the data to help ensure data longevity, and also allows for
data to be stored on the type of media that best meets its speed of access and
cost needs.

Other SSAM features include:


򐂰 Expiration policies
Expire the data when it is no longer needed, thus freeing up the storage
media, and providing cost effectiveness.
򐂰 Off-site data protection
Is standard — off-site copies can be created onto any of the hundreds of
types of media supported, and like the primary copy, is policy managed to
allow for expiration.
򐂰 Archive client program
Permits users to archive files from their workstations or file servers to archive
retention protected storage, and also retrieve archived copies of files to their
local workstations
򐂰 Expiration and deletion suspension
Allows you to place an unconditional hold on data. It means that data cannot
be deleted or modified until the deletion hold is released.
򐂰 Event-based retention management
Data is retained based subject to a time interval which is calculated after a
retention-initiating event occurs. The data can then not be deleted until the
time limit has expired. For example you can specify to keep records for a
particular employee for one year after the employee leaves the organization.
򐂰 Data retention protection
Data will not be deleted until the retention criteria for the object is satisfied.

For more information, visit the Web page:


http://www.ibm.com/software/tivoli/products/storage-mgr-data-reten/

Appendix A. Tivoli Storage Manager family of products 243


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

Data Protection product family


Using its Data Protection components, IBM Tivoli Storage Manager provides
data protection for a wide variety of applications, databases, mail, and hardware,
ensuring that data is safe and secure no matter where it is located or how it is
stored. These products interface directly with the applications using their
backup-certified utilities and interfaces, simplifying online backup and restore
procedures. These products are now called:
򐂰 IBM Tivoli Storage Manager for Databases
򐂰 IBM Tivoli Storage Manager for Enterprise Resource Planning
򐂰 IBM Tivoli Storage Manager for Mail
򐂰 IBM Tivoli Storage Manager for Microsoft SharePoint
򐂰 IBM Tivoli Storage Manager for Copy Services
򐂰 IBM Tivoli Storage Manager for Advanced Copy Services

IBM Tivoli Storage Manager for Databases


IBM Tivoli Storage Manager for Databases is an optional software module that
works with Tivoli Storage Manager to protect a wide range of application data via
the protection of the underlying database management systems holding that
data. Tivoli Storage Manager for Databases exploits the backup-certified utilities
and interfaces provided for Oracle, Microsoft SQL Server, and Informix®. In
conjunction with IBM Tivoli Storage Manager, IBM Tivoli Storage Manager for
Databases automates data protection tasks and allows database servers to
continue running their primary applications while they back up and restore data
to and from offline storage.

IBM DB2 Universal Database™ includes the same functionality, enabling it to


work directly with Tivoli Storage Manager without the need to buy any additional
modules. Regardless of which database is used, Tivoli Storage Manager for
Databases allows the centralized and automated data protection capabilities of
Tivoli Storage Manager to be applied to up-and-running database servers.

Data Protection for Informix


Informix-certified Data Protection for Informix provides centralized, online,
incremental backup capabilities for restoring and managing Informix server
databases and logical logs. It provides both parallel backup and restore and
automatic backup of logical logs via the Informix ON-Bar utility. ON-Bar uses the
X/Open Backup Services Application Program Interface (XBSA) to communicate
with the Tivoli Storage Manager, where backups are stored.

Data Protection for Informix is supported on AIX, HP/UX, and Solaris up to V5.2
of IBM Tivoli Storage Manager for Databases. Beginning with Informix V10, the

244 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

Tivoli Storage Manager backup interface is included with the Informix database
product itself - no add-on is required. This is similar to the situation with IBM DB2
UDB.

Data Protection for Oracle


Data Protection for Oracle provides an interface between IBM Tivoli Storage
Manager and Oracle Recovery Manager (RMAN) for Oracle 8i, Oracle 9i, and
Oracle Database 10g databases. The data may be stored on the wide variety of
storage devices supported by IBM Tivoli Storage Manager. Particular version
support varies according to the underlying operating system of the Oracle server.
For specific supported versions, see:
http://www.ibm.com/software/tivoli/products/storage-mgr-db/platforms.html

RMAN functions and features include:


򐂰 Full or table space backup of a database while it is online or offline
򐂰 Full database restore while it is online or offline
򐂰 Table space restore while database is offline
򐂰 Backups of archive log files
򐂰 Block-level incremental backup of changed database pages
򐂰 Ability to use the “duplex copy” feature of RMAN 2.0, making it possible to
send a backup to two separate storage tapes simultaneously
򐂰 Optimized performance with tunable multi-buffer caching during backups
򐂰 Synchronization utility to reconcile inventory between the Tivoli Storage
Manager server and the RMAN catalog

Data Protection for Microsoft SQL Server


Data Protection for Microsoft SQL Server enables online backups of the SQL
databases to Tivoli Storage Manager storage. Data Protection for Microsoft SQL
Server features:
򐂰 Full and transaction-log backup support
򐂰 The ability to maintain multiple versions of SQL database and transaction logs
򐂰 GUI and command line interfaces to simplify usage
򐂰 Support for Tivoli Storage Manager’s automatic expiration and version control
by policy, which frees users from having to explicitly delete SQL Server
backup objects in the Tivoli Storage Manager server
򐂰 Support for Microsoft SQL Server 7.0, SQL Server 2000, and SQL Server
2005
򐂰 MSCS support for failover

Appendix A. Tivoli Storage Manager family of products 245


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Differential backup and restore of SQL databases


򐂰 Backup and restore of individual file groups and individual database files
򐂰 SQL data striping for high performance
򐂰 The ability to restore to a standby SQL Server
򐂰 The ability to restore to a different SQL Server or to different physical file
names

IBM Tivoli Storage Manager for Enterprise Resource Planning


IBM Tivoli Storage Manager for Enterprise Resource Planning (ERP) is an
optional software module that integrates with Tivoli Storage Manager to protect
infrastructure and application data, and improve the availability of SAP® servers.

Tivoli Storage Manager for ERP offers the following features:


򐂰 It is specifically designed and optimized for SAP environments.
򐂰 It is SAP certified for heterogeneous environments.
򐂰 It reduces the performance impact of backup and restore operations on
mySAP™ servers.
򐂰 It allows multiple mySAP servers to utilize a single IBM Tivoli Storage
Manager server.
򐂰 It can handle large-volume backups and restores, and data cloning.
򐂰 Multiple path and session support provides one path or session per tape
device, thus maximizing backup and restore performance.
򐂰 Multiple server operations enable multiple Tivoli Storage Manager servers to
be used in parallel for backup and restore, thus eliminating capacity
bottlenecks.
򐂰 Multiplexing merges multiple data streams into one data stream, thereby
leveraging the full write bandwidth of storage devices and minimizing backup
window times.
򐂰 Multiple log files store log files in two management classes, thus providing
additional security through redundancy of log files.
򐂰 SAN support and integration allows the use of SAN fiber channels with high
bandwidth for LAN-free backups and restores.
򐂰 Support for FlashCopy and split mirror technology creates an additional disk
for backup purposes, leaving mySAP applications and performance
unaffected during the backup.

246 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

򐂰 Adaptive file sequencing sorts and sequences files to be backed up according


to the overall status of the path and session load, thereby optimizing resource
usage and decreasing total backup and restore times.

IBM Tivoli Storage Manager for Mail


IBM Tivoli Storage Manager for Mail is an optional software module for IBM Tivoli
Storage Manager that automates the data protection of e-mail servers running
either Lotus® Domino® or Microsoft Exchange. IBM Tivoli Storage Manager for
Mail utilizes the application program interfaces (APIs) provided by Lotus and
Microsoft to perform online hot backups without shutting down the e-mail server.
Tivoli Storage Manager for Mail enables 24x7x365 operation of e-mail servers
while performing data backups and restores.

For Lotus Domino databases, IBM Tivoli Storage Manager for Mail exploits
Domino’s “transaction logging” feature, enabling the capture of just the database
changes for logged databases. Thus, full database backups are not required as
frequently as in previous Domino releases.

For Microsoft Exchange, Tivoli Storage Manager for Mail supports both Microsoft
Exchange Server 5.5, Microsoft Exchange Server 2000 and Microsoft Exchange
Server 2003. It uses Microsoft’s backup APIs to create a copy of the Exchange
server storage group databases along with the associated transaction logs. Tivoli
Storage Manager for Mail can produce the different types of backups specified by
Microsoft backup APIs: full backups, incremental backups, differential backups,
copy backups and database copy backups.

Data Protection for Lotus Domino


Data Protection for Lotus Domino, helps protect and manage Lotus Domino
Release 6.5, 7, or 8 servers. Features include:
򐂰 Performs centralized, online, incremental backup of Lotus Domino databases
򐂰 Integrates with Tivoli Storage Manager Web client
򐂰 Maintains multiple versions of Domino databases maintained
򐂰 Archives Domino transaction log files, when archival logging is in effect
򐂰 Restores backup versions of a Domino database and apply changes made
since the backup from the transaction log
򐂰 Restores Domino databases to a specific point in time
򐂰 Recovers to same or different Domino server
򐂰 Performs expiration database backups automatically based on version limit
and retention period

Appendix A. Tivoli Storage Manager family of products 247


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Expires archived transaction logs when they are no longer needed


򐂰 Provides online documentation: context-sensitive, task, and conceptual help
򐂰 Performs automated scheduled backups
򐂰 Recovers one or more archived transaction logs independent of a database
recovery
򐂰 Recovers from the loss of the transaction log
򐂰 Archives the currently filling transaction log file
򐂰 Supports Domino Individual Mailbox Restore

Data Protection for Lotus Domino provides two types of database backup,
incremental and selective, and a log archive function. Incremental backup
provides a conditional backup function that creates a full online backup of
Domino databases when necessary. The specific conditions that determine when
a new backup is necessary vary depending on whether the database is logged or
not. Selective backup unconditionally backs up the specified databases, unless
they are excluded from backup through exclude statements. When archival
logging is in effect, changes to logged databases can be captured between full
backups by archiving the transaction log.

Data Protection for Microsoft Exchange Server


Data Protection for Microsoft Exchange Server provides complete integration
with Microsoft Exchange APIs, featuring:
򐂰 Centralized online backups (full, copy, incremental, and differential) of
Exchange Directory and Information Stores to Tivoli Storage Manager server
storage
򐂰 Auto-detection of the Recovery Storage Group facility of Exchange 2003 to
provide restoration of mailbox databases without dismounting or affecting the
existing mailboxes
򐂰 Automatic expiration and version control by policy
򐂰 Failover for MSCS
򐂰 Parallel backup sessions for high performance
򐂰 Automated transaction log file management
򐂰 LAN-free backup
򐂰 Windows GUI
򐂰 The ability to restore objects to a specified directory

Data Protection for Exchange Server supports Microsoft Exchange individual


mailbox restore in conjunction with the Tivoli Storage Manager backup-archive
client and the Microsoft ExMerge tool.

248 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax01-prod.fm

IBM Tivoli Storage Manager for Microsoft SharePoint


IBM Tivoli Storage Manager for Microsoft SharePoint, allows you to quickly and
confidently restore your Microsoft SharePoint business data and content due to a
business interruption of almost any kind.

IBM Tivoli Storage Manager for Microsoft SharePoint is a policy-based backup


and recovery solution that provides full, incremental, or differential backup at the
site-level, subsite-level, and item-level for Microsoft SharePoint Portal 2003,
Microsoft Office SharePoint Server 2007, and Windows SharePoint Services
V2.0 and V3.0 environments.

For more information, visit the Web page:


http://www-306.ibm.com/software/tivoli/products/storage-mgr-sharepoint/

IBM Tivoli Storage Manager for Advanced Copy Services


IBM Tivoli Storage Manager for Advanced Copy Services (formerly known as
IBM Tivoli Storage Manager for Hardware) is an optional software module for AIX
that integrates with IBM Tivoli Storage Manager Extended Edition. Tivoli Storage
Manager for Advanced Copy Services protects mission-critical data that must be
available 24x7, and integrates hardware- and software-based snapshot
capabilities with IBM Tivoli Storage Manager and its Data Protection components
for DB2 UDB, Oracle, and mySAP.

Tivoli Storage Manager for Advanced Copy Services supports a wide range of
hardware:
򐂰 IBM DS6000
򐂰 IBM DS8000
򐂰 SAN Volume Controller (SVC) and all IBM and non-IBM devices supported by
the SVC.
򐂰 IBM Enterprise Storage Server® (ESS)

For a complete list, see:


http://www.ibm.com/servers/storage/software/virtualization/svc/interop.html

Tivoli Storage Manager for Advanced Copy Services also provides the following
functionality:
򐂰 FlashCopy support for ESS for Oracle
򐂰 FlashCopy support for ESS for DB2
򐂰 FlashCopy support for ESS for mySAP on DB2 UDB
򐂰 FlashCopy support for ESS for mySAP on Oracle
򐂰 Snapshot support for DS8000, DS6000 and SVC for DB2 UDB

Appendix A. Tivoli Storage Manager family of products 249


6148ax01-prod.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Snapshot support for DS8000, DS6000 and SVC for Oracle


򐂰 Snapshot support for DS8000, DS6000 and SVC for mySAP on DB2 UDB
򐂰 Snapshot support for DS8000, DS6000 and SVC for mySAP on Oracle
򐂰 Multiple snapshot versions managed by Tivoli Storage Manager policy
򐂰 Coordinated FlashCopy backup of multi-partition DB2 UDB databases
distributed across multiple host systems.

Support of FlashCopy and snapshot functionality allows for “Zero Impact”


backups and instant recovery. Data transfer to the Tivoli Storage Manager server
is handled from a separate storage server, allowing the primary production data
to remain online and undisturbed.

IBM Tivoli Storage Manager for Copy Services


IBM Tivoli Storage Manager for Copy Services is a optional module for Windows
that integrates with IBM Tivoli Storage Manager or IBM Tivoli Storage Manager
Extended Edition. It is designed to leverage Microsoft’s Volume Snapshot
Services (VSS) on Windows 2003. Tivoli Storage Manager for Copy Services
provides similar functionality to Tivoli Storage Manager for Advanced Copy
Services, supporting Windows VSS with Microsoft Exchange Server 2003 and
Microsoft SQL Server 2005.

Tivoli Storage Manager for Copy Services features:


򐂰 Single command-line interface (CLI) for performing legacy and VSS snapshot
backup, restore, and query operations
򐂰 Single GUI for performing legacy and VSS snapshot backup, restore, and
query operations
򐂰 Support for both hardware and software VSS providers that strictly adhere to
Microsoft VSS provider requirements
򐂰 Support for a clustered Exchange environment
򐂰 Support for a clustered SQL Server environment

As with Tivoli Storage Manager for Advanced Copy Services, zero impact
backups and instant recovery allow the primary production data to remain online
and undisturbed. Data movement to IBM Tivoli Storage Manager storage can be
off-loaded to a secondary machine via a VSS hardware provider that supports
transportable shadow copy volumes.

250 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

Appendix B. Microsoft SQL Server


overview for Tivoli Storage
Manager administrators
A successful implementation of Tivoli Storage Management products to protect
an SQL Server environment requires that both the SQL Server and Tivoli Storage
Management administrators have a certain level of knowledge of both
environments. This chapter is meant to facilitate the understanding of SQL
Server for Tivoli Storage Manager administrators.

SQL Server is a relational database management system (RDBMS) platform


from Microcosft, used for online transaction processing (OLTP), data
warehousing and e-commerce applications. It also provides functionality for data
integration, analytical processing and reporting solutions.

It uses Transact SQL and XML to send requests between the client and the SQL
Server. Transact SQL is a programming and query language which allows data to
be accessed, queried, updated and managed. Microsoft SQL Server runs only
on Windows platforms, and has 32-bit and 64-bit editions.

© Copyright IBM Corp. 2008. All rights reserved. 251


6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

SQL Server 2005 components


SQL Server 2005 consists of the following components:
򐂰 Database Engine
The SQL Server Database Engine is the core component of the SQL Server
platform. It is a service used to store, manage and secure data. It is also
known as the SQL Server itself, or the SQL Server RDBMS.
򐂰 Analysis Services
Analysis Services is the component used to support online analytical
processing (OLAP) and data mining functionality in business intelligence
applications.
򐂰 Integration Services
Integration Services is the component used to integrate different sources of
information to provide extract, transform and load (ETL) capabilities to SQL
Server. Integration Services is a replacement for Data Transformation
Services (DTS, that was available in SQL Server releases 7 and 2000.
򐂰 Reporting Services
Reporting Services is the component used to create reports from several data
sources, allowing to publish Web-based reports in several formats.
򐂰 Notification Services
Notification Services is the component to develop and deliver notifications.
򐂰 Full Text Search
Full Text Search is the component used to submit full-text queries against
plain text documents stored in SQL Server tables.
򐂰 Replication
Replication is the component used to distribute and replicate data from one
database to another.
򐂰 Service Broker
Service Broker is a component used to implement message queuing in SQL
Server.

Several SQL Server components store their information in SQL Server


databases, while others use operating system files. From the point of view of
backup needs for a SQL Server platform, it is necessary to implement a solution
containing both SQL Server databases and operating system files backup. 2.3,
“Microsoft SQL Server backup planning” on page 40 provides a detailed
discussion about all requirements to protect all SQL Server components.

252 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

SQL Server Database Engine (RDBMS)


The SQL Server Database Engine is the component used to manage data. It is
commonly known as the SQL Server itself.

Similar to IBM DB2, SQL Server RDBMS has a concept of instance and
database, as shown in Figure B-1.

Figure B-1 SQL Server instance and database concept

SQL Server instance


An SQL Server instance is a set of operating system processes. It can be started
either as a Windows service, or, for certain maintenance operations, via a
command line interface using the SQL Server binaries. The SQL Server instance
configuration parameters are stored in the Windows registry files and in some
SQL Server databases.

Until SQL Server release 7, it was possible only to have one SQL Server
instance per machine - since SQL Server 2000 it is possible to have several
instances per machine.

SQL Server database


An SQL Server database is a physical structure stored on disk, which is
accessed by an SQL Server instance. It is made up of a collection of tables and
objects that stores data in a structured way.

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager administrators 253
6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

There are two types of SQL Server databases, system databases and user
databases:

System databases
A system database stores information about the system - about the SQL Server
itself, about all other databases, and about SQL Server components other than
the Database Engine component.

SQL Server has five system databases:


򐂰 master
The master database manages the SQL Server and user databases, and
contains information about all databases residing on the SQL Server. The
master database is very important, and it must be backed up every time you
perform certain operations or system stored procedures that modify it
automatically. Without a current backup of the master database, in the case of
failure, you must completely rebuild all of the system databases. The master
database can be backed up only as a full database backup operation.
򐂰 model
The model database is a template for new user databases. All modifications
made to the model database are applied to any database created afterward. If
the model database is modified, then it must be backed up. When rebuilding
the master database, subsequent changes to the model databases will be
lost, and must be restored from the backup.
򐂰 msdb
The msdb database is used as storage area for scheduling information and
job history. If you do not have a backup for this database, you must rebuild all
of the system databases and then recreate each job, alert and operator.
򐂰 tempdb
The tempdb table is used for temporary tables and other temporary working
storage needs. You cannot back up this database - it is recreated each time
the SQL Server is restarted.
򐂰 resource
The resource database is a new system database for SQL Server 2005, and
contains system objects that are included with SQL Server 2005. The system
objects logically appear in the sys schema of every database, but are
physically stored in the resource database. The resource database is
read-only, and cannot be modified without Microsoft Customer Support
Services (CSS) specialist support. The resource database cannot be backed
up by Data Protection for SQL Server - instead, use the Tivoli Storage
Manager backup-archive client to back up the file as an operating system file,

254 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

similar to the SQL Server binaries. The resource database datafiles are
located in the same place as the datafiles for the master database, and if you
move, or restore the master database to a different location, you must also
move or restore the resource datafiles to the same location as the master
database datafiles. The resource database data file and log file are named
mssqlsystemresource.mdf and mssqlsystemresource.ldf respectively.
For more information about the resource database, refer to Microsoft Books
On Line:
http://msdn2.microsoft.com/en-us/library/ms190940.aspx.

SQL Server does not support directly updating the information stored in the
system databases. To manage and modify the information stored in the system
databases you must use one of the SQL Server administrative tools provided
within the SQL Server installation.

User databases
A user database stores user information. You create and store tables, indexes,
procedures, triggers and other objects in user databases.They must be backed
up regularly, especially after an index has been created of after a load operation.
It is a good practice to create different user databases for different applications.

Each database, including the master database, contains a database catalog,


which is a collection of system tables containing metadata about the database.
System tables store metadata, which is information about the data. The master
database contains a collection of system tables that store information about the
entire system and all other databases.

Database files
SQL Server databases have three types of files:
򐂰 Primary data file: This file contains the database catalog tables. It can also
contains user data and objects. The recommended file name extension for
primary files is .mdf.
򐂰 Secondary data file: This optional file contains user data and objects only,
and is used to spread the data across different files and/or drives. The
recommended file name extension for secondary files is .ndf.
򐂰 Transaction log file: This file records all database transactions, and it is used
to recover the database in case of failures. The recommended file name
extension for transaction log files is .ldf.

Each SQL server database has at least two operating system files: a primary
data file and a transaction log file. By default, the data and transaction log files

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager administrators 255
6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

are stored in the same location, however, for production environments, it is


recommended whenever possible to put data files and transaction log files on
different disks. You can have up to 32,767 files in a database.

The location of all datafiles in a database are recorded in the master database
and also in the database primary data file. Most of the time, SQL Server uses the
information stored in the master database to identify the datafiles, but, in some
situations, such as a recover from the master database, SQL Server uses the
information stored in the primary data file to initialize the database.

All files have a logical name and a physical name. The logical name is the name
that the file is referenced inside SQL Server, and the physical name is the
operating system file name. SQL Server datafiles can be stored in either FAT or
NTFS file systems.

Database filegroups
For administrative and allocation purposes, you can group database objects and
files in filegroups. There are two types of filegroups:
򐂰 Primary filegroups: The primary filegroup contains the primary data file and
any other data files that are not specifically assigned to an user-defined
filegroup. The primary filegroup is created automatically during the database
creation.
򐂰 User-defined filegroups: All other filegroups except the primary filegroup are
known as user-defined filegroups.

Note: Transaction log files are not part of a filegroup.

Each data file is member of only one filegroup, and a database object can be
stored in only one filegroup. For each database, one filegroup is designated as
the default filegroup. When a database object is created without the filegroup
specification, the object will be stored in the default filegroup. If no default
filegroup is specified, the primary filegroup becomes the default filegroup.

Example B-1 shows how to create a database with several files and filegroups

Example: B-1 Database creation with filegroups


USE master;
GO

CREATE DATABASE OLTP


ON PRIMARY
( NAME='OLTP_PRI_Dat',

256 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

FILENAME=
'd:\MSSQL\OLTP\data\OLTP_Primary.mdf',
SIZE=100MB,
MAXSIZE=200MB,
FILEGROWTH=20MB),
FILEGROUP OLTP_FG1
( NAME = 'OLTP_FG1_Dat1',
FILENAME =
'E:\MSSQL\OLTP\data\OLTP_FG1_DF1.ndf',
SIZE = 1000MB,
MAXSIZE=2000MB,
FILEGROWTH=100MB),
( NAME = 'OLTP_FG1_Dat2',
FILENAME =
'F:\MSSQL\OLTP\data\OLTP_FG1_DF2.ndf',
SIZE = 1000MB,
MAXSIZE=2000MB,
FILEGROWTH=100MB)
LOG ON
( NAME='OLTP_log',
FILENAME =
'G:\MSSQL\OLTP\log\OLTP_LOG_DF1.ldf',
SIZE=400MB,
MAXSIZE=1000MB,
FILEGROWTH=100MB);
GO

The command executed in Example B-1 will create a database with similar
structure to Figure B-2 on page 258.

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager administrators 257
6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

Figure B-2 OLTP database structure example

Database recovery model


Before we discuss about database recovery models, a brief introduction to how
transactions are handled by SQL Server is necessary.

The SQL Server recovery model relies on a transaction log to record all
transaction activities in the database. When data is modified, this modification is
first written to the log cache and to the transaction log file. The information
recorded for the transaction contains the modification being executed by the
transaction, the necessary information to undo, or rollback, the transaction and
restore the data to the state before the operation - the before image, and also the
value of the data after the transaction - the after image. Some transactions will
record the entire row, while others will record only the bytes that have changed
during the transaction.

Transactions from the transaction log are periodically committed to the database
data files and written to the disk. At this point, the transaction log records for
these transactions become inactive - in other words, all such transaction

258 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

information is already written in the database data files and the transaction log
records will be used only if a database restore from a backup taken prior to this
moment is performed.

The transaction log architecture allows SQL Server to perform three operations:
򐂰 Recover from a single transaction
When an application submits a ROLLBACK command, or when there is a
connection failure between the client and the server, the log records stored in
the transaction log are used to roll back the modifications made by the
incomplete transactions.
򐂰 Recover all transactions when a database is started
When a database is restarted after a failure, the transaction log records are
used to roll forward committed transactions that are not written in the
database data files, and to roll back any uncommitted transactions, ensuring
database integrity.
򐂰 Rolling forward a database in a recovery scenario
After a database restore, SQL Server uses the transaction log records to
reapply all transactions performed in the database what were recorded, and
to roll back any uncommitted transactions.

The SQL Server transaction log architecture also allows standby-server


solutions, database mirroring, and log shipping. These SQL Server capabilities
are not in the scope of this book - for more information, see the SQL Server
documentation.

Multiple log files are treated as if they were concatenated into a single file.

As more transactions are performed against a database, more information will be


recorded in the transaction log file. This could lead to a scenario where a
transaction log could grow indefinitely, filling all available space on the disks
holding the physical log files. However, older transactions recorded in the
transaction log may have become inactive, not being necessary to recover or
restore the database, and can be deleted. The process of deleting the old
records and reusing the space is called truncating the log. The active portion of
the transaction log can never be truncated, because it contains information
required to recover the database at any time, allowing the database to roll back
the transactions.

Note: Truncating the transaction log does not reduce the size of a physical log
file, it only reduces the size of the logical log file. To reduce the size of a
physical log file, it is necessary to shrink the file, using, for example, the DBCC
SHRINKFILE command.

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager administrators 259
6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

When a log truncation occurs, all inactive transactions are deleted from the
transaction log. However, this information is still required to roll forward a
database during a recovery process. To address this situation, SQL Server
allows you to perform transaction log backups. A transaction log backup copies
all information recorded in the transaction log to a backup file, and then performs
a truncate log to liberate space for new transactions.

Note: The backup database strategies are discussed in 2.3, “Microsoft SQL
Server backup planning” on page 40.

Another important aspect is that recording all database transactions could cause
severe performance impacts in the environment, specially for operations that
demand a high amount of data manipulation, such as an index creation or a data
warehouse load process, and also can consume a large amount of disk space.

For this situation, SQL Server allows you to reduce the amount of information to
be recorded in the transaction log files. The trade-off is, as not all information will
be recorded in the transaction log file, you may not be able to fully restore a
database since you will not have all required information recorded.

To give the flexibility to the administrators to choose the right option for their
specific needs, SQL Server implements three database recovery models, which
are mutually exclusive, and, with some limitations, can be changed when
needed.

Simple recovery model


In a simple recovery model databases, if the database is lost you will lose all
modifications performed since the last full backup or last differential backup and
the point of failure.

With the simple recovery model, you cannot perform transaction log backups.
Log space is automatically reclaimed, keeping the transaction log file space
small. This model permits high-performance bulk-copy operations, because only
page allocations are logged instead of row insertions, increasing performance
and reducing log space consumption.

Note: The simple recovery model is similar to setting the trunc. log on chkpt.
database option in SQL Server 7.0 or earlier.

Generally, the simple recovery model is not used for read-write user databases in
production environments.

260 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

Full recovery model


The full recovery model allows you to recover a database to a specific point in
time, provided the backups are complete up to that point in time.

This recovery model requires more disk space for the transaction log files than
other recovery models. Under this model, transaction log backups are essential,
and must be executed periodically to ensure database recovery and to keep
transaction log disk usage at normal levels.

Note: Even the full recovery model does not guarantee no data loss. In an
event of complete hardware crash, you can have information stored in the tail
of the log file that was not backed up before the failure. In this case, you must
redo all changes after the last transaction log backup.

Recovering a database in a full recovery model usually requires a combination of


database backups and transaction log backups. 2.3, “Microsoft SQL Server
backup planning” on page 40 provides a detailed discussion about different
strategies to backup databases.

Generally, this is the recommended recovery model for user databases in a


production environment.

Bulk-logged recovery model


The bulk-logged recovery model is an adjunct to the full recovery model. It should
be used only during large-scale bulk process, such as an index creation or a
batch load. The bulk-logged recovery model permits high-performance bulk-copy
operations, because only page allocations are logged instead of row insertions,
increasing performance and reducing log space consumption.

For databases using the bulk-logged recovery model, it is still necessary to


backup the transaction log.

As for full recovery model databases, it is possible to recover a bulk-logged


database to the end of the transaction logs, however, point in time recovery is not
supported for bulk-logged databases.

SQL Server security


Securing a SQL Server involves three areas:

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager administrators 261
6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 Platform and network, including the physical hardware, the operating system
and the remote systems communicating with the SQL Server,
򐂰 Principals and database object security, that includes users authentication
and authorization,
򐂰 Application security, that is related to the security of applications accessing
SQL Server databases.

The platform and network security considerations, as well application security


considerations, are beyond the scope of this book. We give an introduction to
principals and database object security here.

SQL Server 2000 and earlier


Until SQL Server 2000, two levels of security were used to control access to SQL
Server:

Authentication
The user must have an account in order to be able to connect to the SQL server.
There are two authentication modes:
򐂰 Windows authentication mode: SQL Server relies on Windows
authentication to verify the username and password credentials. SQL Server
logins are not allowed to connect to the SQL Server when Windows
authentication mode is configured.
򐂰 Mixed mode authentication: Provided for backward compatibility, mixed
mode authentication allows users to connect to SQL Server using either their
Windows login accounts or an SQL Server login account. When an SQL
Server login account is used, the username and password data are verified
against the SQL Server.

The users connected to SQL Server using their login accounts are called trusted
connections. The SQL server administrator specifies which kind of authentication
is used, and the default and recommended setting is Windows authentication
only.

Authorization
After a user has been authenticated, in order to perform any activity in the SQL
Server, the user must have proper permissions, which show what kind of activity
the user can perform. The are two authorization levels:
򐂰 Login permissions: The login permissions are related to activities the user can
perform at the SQL Server instance level, such as create a database, modify
a SQL Server instance parameter, or create a SQL Server login, for example.

262 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

The login permissions are granted through the use of fixed server roles, and
each role has a predefined set of permissions. Some examples of fixed server
roles are the sysadmin role, that can perform any activity in the SQL Server,
or the serveradmin role, that can set server wide configuration options, and
shutdown the server.
򐂰 Database permissions: The database permission are related to activities the
user can perform at the database level, such as create a table, read any table
in the database, manage object permissions and also backup the database.
The database permissions are configured through the use of fixed database
roles or directly to users using the GRANT, REVOKE and DENY commands.
As the fixed server roles, each fixed database role has a predefined set of
permissions. Examples of fixed database roles are the role, that can perform
any activity in the database, the db_backupoperator, that has permission to
back up the database, and the db_datareader, that can access data from all
user tables in the database.

SQL Server 2005


In order to provide more granular control over security components, SQL Server
2005 introduces a new concept for security, based on principals. securables and
permissions. This concept can be understood as an extension to the previous
authentication and authorization concepts.

Principals
Principals are users, groups and applications granted access to SQL Server.
There are three different types of principals:
򐂰 Windows-based principals:
Examples of windows-based principals are Windows domain logins and
Windows user logins
򐂰 SQL Server-level principal:
An example of SQL Server-level principal is the sa SQL Server account.
򐂰 Database-level principal:
Examples of database-level principals are database users, database roles
and application roles.

The principals connects to the SQL Server database using SQL Server
authentication or Windows authentication methods.

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager administrators 263
6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

Securables
Securables are resources that have authorization access controlled either by
SQL Server or by the Windows operating system. At the Windows level, the
securables include files and registry keys used by SQL Server, and at the SQL
Server level, securables are resources, such as the server itself, the databases
and the objects stored within a database, that have the authorization access
controlled by SQL Server.

There are three scope levels for the SQL Server securables:
򐂰 Server
Examples of server securables are SQL Server Endpoints, logins and
databases.
򐂰 Database
Examples of database securables are database users, database roles, full
text catalogs and certificates.
򐂰 Schema
Examples of schema securables are types, objects, such as tables, views and
procedures, and XML schema collections.

Permissions
Permissions are the rights granted to principals to perform some activity against
the securables. At the Windows securable level, permissions are controlled
through Windows Access Control Lists (ACL). The GRANT, REVOKE and DENY
statements are used to control the permissions that principals can perform on
SQL Server securables. Each SQL Server securable has a set of permissions
associated to them. Some examples of permissions are SELECT, INSERT,
UPDATE and DELETE permissions applicable to TABLE objects, EXECUTE
permission related to PROCEDURE objects and BACKUP permission related to
the DATABASE securable.

For a detailed description about principals, securables and permissions, refer to


the SQL Server documentation.

SQL Server services


An SQL Server installation creates several Windows services. Some of them are
instance-aware, meaning that the service is associated with a specific SQL
Server instance, while other services are instance-unaware, when the service is

264 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148ax02-mssql.fm

shared among all SQL Server instances installed on the machine. The
instance-unaware services are installed only once, and cannot be installed
side-by-side, while an instance-aware service can be installed multiple times,
each one using its own SQL Server binaries.

In default SQL Server installation the instance-aware services are:


򐂰 SQL Server (MSSQLSERVER) - service name: MSSQLSERVER
The service for the SQL Server Database Engine (RDBMS) component.
򐂰 SQL Server Agent (MSSQLSERVER) - service name: SQLSERVERAGENT
The service for the SQL Server Agent process, responsible for execute jobs,
monitors SQL Server, fires alerts and allows administrative tasks. It is
dependent on SQL Server Server service.
򐂰 SQL Server Analysis Services (MSSQLSERVER) - service name:
MSSQLServerOLAPService
The service responsible for the Analysis Server component.
򐂰 SQL Server FullText Seach (MSSQLSERVER) - service name: msftesql
The service responsible for the FullText Search component.
򐂰 SQL Server Reporting Services (MSSQLSERVER) - service name:
ReportServer
The service responsible for the Reporting Services component.

In the Windows Services utility display names, the string MSSQLSERVER


between parenthesis identifies the instance of SQL Server. For the default
instance, it will be MSSQLSERVER. For named instances, it will be replaced by
the named instance name. Moreover, for named instances the service name
itself also receives the instance identifier. For a named instance called
SQLNAMED1, for example, the instance-aware services will be:
򐂰 SQL Server (SQLNAMED1) - service name: MSSQL$SQLNAMED1
򐂰 SQL Server Agent (SQLNAMED1) - service name: SQLAgent$SQLNAMED1
򐂰 SQL Server Analysis Services (SQLNAMED1) - service name:
MSOLAP$SQLNAMED1
򐂰 SQL Server FullText Seach (SQLNAMED1) - service name:
msftesql$SQLNAMED1
򐂰 SQL Server Reporting Services (SQLNAMED1) - service name:
ReportServer$SQLNAMED1

The instance-unaware services are:


򐂰 SQL Server Active Directory Helper - service name: MSSQLServerADHelper
The SQL Server Active Directory Helper is responsible for publishing and
managing SQL Server services in the Active Directory.

Appendix B. Microsoft SQL Server overview for Tivoli Storage Manager administrators 265
6148ax02-mssql.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 SQL Server Browser - service name: SQLBrowser


The SQL Server Browser service allows name resolution that provides SQL
Server connect information for client computers.
򐂰 SQL Server Integration Services - service name: MsDTSServer
This service ris esponsible for the Integration Services component. It provides
management support for SSIS packages storage and execution.
򐂰 SQL Server VSS Writer - service name: SQLWriter
The SQL Server VSS Writer service is responsible to integrate backup and
restore applications to operate in the Volume Shadow Copy Service (VSS)
framework.

Each SQL Server account has its own registry, file system and operating system
security requirements to operate properly, and these requirements are
configured by the SQL Server installer during SQL Server installation.

SQL Server administrative tools


SQL Server provides several management tools to help administrators to
minimize and automate daily tasks. Table B-1 shows a list of some SQL Server
2000 and SQL Server 2005 tools, and their functionality.

Table B-1 SQL Server administrative tools

SQL Server 2000 SQL Server 2005 Functionality

Enterprise Manager SQL Server Management Studio Execute most administrative tasks
for SQL Server databases.

Query Analyzer Code editor in SQL Server GUI tool to execute ad hoc queries
Management Studio

Server Network Utility SQL Server Configuration Configure server network


Manager protocols and parameters

Client Network Utility SQL Server Configuration Configure client network protocols
Manager and parameters

Service Manager SQL Server Configuration Start and stop SQL Server
Manager databases

osql command prompt tool osql is still supported Start and stop SQL Server
sqlcmd databases

Books on Line Books on Line SQL Server Documentation

266 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148abrv.fm

Abbreviations and acronyms


ACL Access Control Lists SAN storage area network
API application programming SDD Subsystem Device Driver
interface SMO Server Managed Objects
CAD Client Acceptor Daemon SNMP Simple Network Management
CIM Common Interface Model Protocol
CLI command-line interface SSAM System Storage Archive
CSS Customer Support Services Manager

DRM Disaster Recovery Manager SSIS SQL Server 2005 Integration


Services
ERP Enterprise Resource Planning
SVC SAN Volume Controller
ESS Enterprise Storage Server
VCS VERITAS Cluster Server
ETL extract, transform and load
VDS Virtual Disk Service
GUI graphical user interface
VSS Volume Shadow Copy Service
HSM Hierarchical Storage Manager
WAN wide area network
IBM International Business
Machines Corporation
IIS Internet Information Services
ITSO International Technical
Support Organization
LAN local area network
LUN logical unit
LVSA Logical Volume Snapshot
Agent
MSCS Microsoft Cluster Server
NAS network-attached storage
NDMP Network Data Management
Protocol
NIM Network Installation
Management
OLAP online analytical processing
OLTP online transaction processing
PTF Program Temporary Fix
RDBMS relational database
management system
RMAN Recovery Manager

© Copyright IBM Corp. 2008. All rights reserved. 267


6148abrv.fm Draft Document for Review April 30, 2008 1:21 pm

268 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148bibl.fm

Related publications

The publications listed in this section are considered particularly suitable for a
more detailed discussion of the topics covered in this book.

IBM Redbooks
For information about ordering these publications, see “How to get Redbooks” on
page 270. Note that some of the documents referenced here may be available in
softcopy only.
򐂰 IBM Tivoli Storage Manager Implementation Guide, SG24-5416
򐂰 IBM Tivoli Storage Management Concepts, SG24-4877
򐂰 Using IBM Tivoli Storage Manager to Back Up Microsoft Exchange with VSS,
SG24-7373

Other publications
These publications are also relevant as further information sources:
򐂰 IBM Tivoli Storage Manager for Databases Data Protection for Microsoft SQL
Server Installation and User’s Guide, SC32-9059
򐂰 IBM Tivoli Storage Manager for Windows Backup-Archive Clients Installation
and User’s Guide, SC32-0146
򐂰 IBM Tivoli Storage Manager for AIX Administrator's Guide, SC32-0117
򐂰 IBM Tivoli Storage Manager for AIX Administrator's Reference, SC32-0123
򐂰 IBM Tivoli Storage Manager for HP-UX Administrator's Guide, SC32-0118
򐂰 IBM Tivoli Storage Manager for HP-UX Administrator's Reference,
SC32-0773
򐂰 IBM Tivoli Storage Manager for Linux Administrator's Guide , SC32-0119
򐂰 IBM Tivoli Storage Manager for Linux Administrator's Reference, SC32-0125
򐂰 IBM Tivoli Storage Manager for Sun Solaris Administrator's Guide,
SC32-0120

© Copyright IBM Corp. 2008. All rights reserved. 269


6148bibl.fm Draft Document for Review April 30, 2008 1:21 pm

򐂰 IBM Tivoli Storage Manager for Sun Solaris Administrator's Reference,


SC32-0126
򐂰 IBM Tivoli Storage Manager for Windows Administrator's Guide, SC32-0121
򐂰 IBM Tivoli Storage Manager for Windows Administrator's Reference,
SC32-0127
򐂰 IBM Tivoli Storage Manager for z/OS Administrator's Guide, SC32-0122
򐂰 IBM Tivoli Storage Manager for z/OS Administrator's Reference, SC32-0128

Online resources
These Web sites are also relevant as further information sources:
򐂰 Description1
http://????????.???.???/
򐂰 Description2
http://????????.???.???/
򐂰 Description3
http://????????.???.???/

How to get Redbooks


You can search for, view, or download Redbooks, Redpapers, Technotes, draft
publications and Additional materials, as well as order hardcopy Redbooks, at
this Web site:
ibm.com/redbooks

Help from IBM


IBM Support and downloads
ibm.com/support

IBM Global Services


ibm.com/services

270 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148IX.fm

Index
sqlservr.exe 180
A stgpool 199
Access Control Lists, see ACL
tdpsql 133
ACL 264
tdpsqlc 63, 103–104, 147
Agent node 61
vshadow 67, 230–231
Analysis Services 55, 252
VSSADMIN 230
API 5, 232
vssadmin 67, 229
Application Programming Interface client 5
communications parameters 5
Application Programming Interface, see API
COMPRESSION 100
application programming interface, see API
copy group destination 79
archive package 237
Copy Services 6
ascsql.lic 6
Copy-only backup 27
asynchronous 53
copy-only backup 27
ator 269
copy-on-write method 10
CSS 254
B Customer Support Services, see CSS
BACKDELete 60
Backup Destination BOTH 59
Backup-archive client 5
D
Data Protection client 5
backup-archive node 115
Data Protection components 244
BEGIN command 226
Data Protection for Informix 244
BUFFERSIZE parameter 64
Data Protection for Lotus Domino 247
Data Protection for Microsoft Exchange 248
C Data Protection for Oracle 245
CAD 67, 73–74, 111 database 253
Client Acceptor Daemon, see CAD Database Engine 252
client options file 5 db_backupoperator 263
client settings 5 db_datareader 263
clientaction 202 dbcc command 50
CLUSTERNODE 100 DESTINATION 59
clusternode 66 Disaster Recovery Manager, see DRM
collocation 237 DRM 238
commands dsm.opt 60
BEGIN 226 DSMAGENT 73
dbcc 50 dsmcutil command 112
dsmcutil 112 dsmcutil.txt 100
GRANT 72, 118–119 dsmsched.log 63
INACTIVATE 168
move 65
QUERY 167
E
EMC TimeFinder 12
query 172
ENABLELANFREE 65, 100
REGISTER 64, 72
Enterprise Manager 266
RESTORE 178
Enterprise Resource Planning, see ERP

© Copyright IBM Corp. 2008. All rights reserved. 271


6148IX.fm Draft Document for Review April 30, 2008 1:21 pm

Enterprise Storage Server , see ESS L


ERP 246 LAN 234
ESS 249 LASTPRUNEDATE 124
ETL 252 legacy restore 28
extract, transform and load, see ETL LNGTAPEPOOL 78
local area network, see LAN
localdsmagentnode 62
F
file localdsmagentnode parameter 61, 67, 73
ascsql.lic 6 log shipping 52
dsm.opt 60 logfile 63
dsmcutil.txt 100 logical unit 12
dsmsched.log 63 Logical Volume Snapshot Agent, see LVSA
pihdw.dll 6 Lotus Domino R6 247
pisnaphdw.dll 6 LVSA 11
tdpsql.cfg 74
fixed server roles 263 M
FlashCopy 12 management classes 79
FREQuency 59 MAXNUMMP 64
Full Text Search 252 merge replication 52
Microsoft Cluster Server, see MSCS
Microsoft Exchange Server 248
G
GENERATE 100 mirror server 53
GRANT command 72, 118–119 mirrored backup media set 51
graphical user interface, see GUI MODE 59
graphical user interfaces, see GUI move command 65
Group backup 27 MSCS 23, 25
GUI 7, 121, 171 msdb 56
msftesql 265
MSSQLSERVER 265
H MSSQLServerOLAPService 265
Hierarchical Storage Manager, see HSM mssqlsystemresource.ldf 255
HSM 5, 233, 239–240 mssqlsystemresource.mdf 255

I N
IBM FlashCopy 12 named-marks restore 30
IBM Tivoli Storage Manager client 4 NAS 238
IBM Tivoli Storage Manager for Enterprise Re- NDMP 239
source Planning 246 network attached storage, see NAS
IBM Tivoli Storage Manager for Space Management Network Data Management Protocol, see NDMP
240 nocopy 12
IIS 56 nodename option 60
INACTIVATE command 168 nodename parameter 61
Informix 244 Notification Services 252
instance 253
Integration Services 56, 252
Internet Information Services, see IIS O
Offline backup 27
OLAP 252

272 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
Draft Document for Review April 30, 2008 1:21 pm 6148IX.fm

OLTP 251 server role 63


online analytical processing, see OLAP serveradmin 263
online transaction processing, see OLTP Service Broker 252
Oracle Recovery Manager, see RMAN Set backup 27
Shadow Copies 13
Shared Folders 13
P smart selection 30
partial restore 30
SMO 228
PASSWORDACCESS 63, 97
snapshot 9
pihdw.dll 6
snapshot replication 52
pisnaphdw.dll 6
Space Manager client 5
point-in-time copy 9
space reclamation 237
point-in-time restore 30
split mirror 11
principal server 53
SQL Server 251
PROMPT 100
Analysis Services 252
Database Engine 252
Q Full Text Search 252
QUERY command 167 Integration Services 252
query command 172 Notification Services 252
Replication 252
Reporting Services 252
R
RDBMS 251 Service Broker 252
reclamation 237 SQLBUFFERSIZE parameter 64
Redbooks Web site 270 SQLDISKPOOL 78
Contact us xiii SQLSERVERAGENT 265
redirect-on-write 11 sqlservr.exe command 180
REGISTER command 64, 72 SQLTAPEPOOL 78
Registry Replication 208 SSAM 242
relational database management system, see SSIS 56
RDBMS stand by database 52
remotedsmagentnode 62 stgpool command 199
remotedsmagentnode parameter 74 Stripes 138
Replication 252 SVC 37
Reporting Services 55, 252 synchronous 53
ReportServer 265 sysadmin 263
reportserver 55 System Storage Archive Manager, see SSAM
reportservertempdb 55
RESTORE command 178 T
RETExtra 59 Target node 61
RETOnly 59 TCPCLIENTADDRESS 62
RMAN 245 TCPCLIENTPORT 62
root registry key 208 tdpsql command 133
tdpsql.cfg 74, 123
tdpsqlc command 63, 103–104, 147
S
SAN Volume Controller, see SVC Transact SQL 251
SCHEDLOGNAME 63 transactional replication 52
SERialization 59 trusted connections 262
Server Managed Objects, see SMO TSM client 4

Index 273
6148IX.fm Draft Document for Review April 30, 2008 1:21 pm

V
VCS 25
VDS 19
VERDeleted 59
verexists 58
VERITAS Cluster Server, see VCS
Virtual Disk Service, see VDS
Volume Shadow Copy Service, see VSS
Volume Snapshot Services, see VSS
vshadow command 67, 230–231
VSS 1, 8, 228, 250
VSS instant restore 29
VSS Integration Module 6
VSS restore 28
VSS_FULL_TSM 79
VSS_LOCAL 79
VSS_RESERVED 120
VSSADMIN command 230
vssadmin command 67, 229
VSSALTSTAGINGIDIR 98
VSSPOLICY statement 73
VSSPOLICY statements 104

W
WAFL 38
WAN 234
warm backup 52
wide area network, see WAN
Write Anywhere File Layout, see WAFL

X
X/Open Backup Services API, see XBSA
XBSA 244

274 Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
To determine the spine width of a book, you divide the paper PPI into the number of pages in the book. An example is a 250 page book using Plainfield opaque 50#
smooth which has a PPI of 526. Divided 250 by 526 which equals a spine width of .4752". In this case, you would use the .5” spine. Now select the Spine width for
the book and hide the others: Special>Conditional Text>Show/Hide>SpineSize(-->Hide:)>Set . Move the changed Conditional text settings to all files in your
book by opening the book file with the spine.fm still open and File>Import>Formats the Conditional Text Settings (ONLY!) to the book files.
Draft Document for Review April 30, 2008 1:21 pm 6148spine.fm 275
Backing up Microsoft SQL
Server with IBM Tivoli Storage
Manager
(1.5” spine)
1.5”<-> 1.998”
789 <->1051 pages
Backing up Microsoft SQL Server
with IBM Tivoli Storage Manager
(1.0” spine)
0.875”<->1.498”
460 <-> 788 pages
Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
(0.5” spine)
0.475”<->0.875”
250 <-> 459 pages
Backing up Microsoft SQL Server with IBM Tivoli Storage Manager
(0.2”spine)
0.17”<->0.473”
90<->249 pages
(0.1”spine)
0.1”<->0.169”
53<->89 pages
To determine the spine width of a book, you divide the paper PPI into the number of pages in the book. An example is a 250 page book using Plainfield opaque 50#
smooth which has a PPI of 526. Divided 250 by 526 which equals a spine width of .4752". In this case, you would use the .5” spine. Now select the Spine width for
the book and hide the others: Special>Conditional Text>Show/Hide>SpineSize(-->Hide:)>Set . Move the changed Conditional text settings to all files in your
book by opening the book file with the spine.fm still open and File>Import>Formats the Conditional Text Settings (ONLY!) to the book files.
Draft Document for Review April 30, 2008 1:21 pm 6148spine.fm 276
Backing up Microsoft
SQL Server with IBM
Tivoli Storage Manager
(2.5” spine)
2.5”<->nnn.n”
1315<-> nnnn pages
Backing up Microsoft
SQL Server with IBM
Tivoli Storage Manager
(2.0” spine)
2.0” <-> 2.498”
1052 <-> 1314 pages
Back cover ®
Draft Document for Review April 30, 2008 1:21 pm

Backing up Microsoft SQL


Server with IBM Tivoli
Storage Manager ®

Strategic planning This IBM Redbooks publication describes how to plan,


and implementation install, and implement backup and restore for Microsoft SQL INTERNATIONAL
considerations for Server using Tivoli Storage Manager products. TECHNICAL
effective backup SUPPORT
The book is aimed for Tivoli Storage Manager professionals ORGANIZATION
who are responsible for the backup and restore of an
Tivoli Data
Microsoft SQL Server installation using Tivoli Storage
Protection for SQL
Manager.
Server V5.5 VSS BUILDING TECHNICAL
backups We discuss planning, installation and operation of Tivoli INFORMATION BASED ON
PRACTICAL EXPERIENCE
Storage Manager with Microsoft SQL Server.
SQL Server overview
for TSM We also provide an overview of Tivoli Storage Manager IBM Redbooks are developed by
administrators family of product. We describe some essential information the IBM International Technical
regarding Microsoft SQL Server aimed to assist Tivoli Storage Support Organization. Experts
Manager administrator to understand the database from IBM, Customers and
Partners from around the world
middleware platform. create timely technical
information based on realistic
scenarios. Specific
recommendations are provided
to help you implement IT
solutions more effectively in
your environment.

For more information:


ibm.com/redbooks

SG24-6148-01 ISBN

You might also like