Overview
Backup and Restore
New & Recent Features
Backup Options Restore Options Best Practices
Onbar Improvements
Backup Types
Serial Backup
Archives the entire system at a single point in time using only one data stream
Parallel Backup
Archives the requested dbspace one at a time to N data streams
External Backup
Allows a third party application to backup the database server while maintain logical consistency
Physical Backup
Overview
Backup and Restore
New & Recent Features
Backup Options Restore Options Best Practices
Restore Options
Cold Restore
Restoring the server when the database engine is offline
Warm Restore
Restore of dbspaces which occur while the database engine is online
Mixed Restore
A cold restore of set dbspaces followed by a warm restore of other dbspaces
Logical Restore
Follows physical restore Required After onbar restore from parallel backup Warm Restore
Restore Options
Point-in-time Table and/or column Level Restore Imported Restore
Transferring an archive taken on one computer and restoring it on a second computer
Point-in-Time Restore
Restoring the entire system to a single point in time
Suspended Restore
Ability to continue the restore if a restore client fails
Restartable Restore
Allows the DBA to pickup the restore from the failure point
Re-Directed Restore
Allows chunk pathnames to be changed while doing the restore
ontape
On-Bar
External Backup and Restore archecker
10
Benefits
Extract a table or set of tables
Filter the retrieved data Retrieve just a subset of columns Repartition the data Data may be placed in the same version database or on a different database version with a different machine architecture
11
database test1; create table tlr ( a_serial serial, b_integer integer, c_char char(20), d_decimal decimal ) in dbspace1; insert into tlr select * from tlr;
12
13
Distributed Restore
Extracts a table called test:source_tab from the most recent backup of dbspace1 and places the data on the database server rem_srv in the table target_dbs:tlr_1 database target_dbs; create table target_tab ( columns );
database test; create table source_tab ( columns ) in dbspace1; insert into target_dbs@rem_srv.target_tab select * from source_tab;
14
Ontape Features
Backup at the Server level Support for incremental backups Manual or continuous logical log backup Restore entire system or single dbspace Backup is self describing All data backup is from the archive start time or before No longer required to set TAPESIZE Backup & Restore using STDIO
Large file support in ontape Support of External Backup & Restore New option to salvage log using ontape
15
Ontape
Database server
Physical Log
Logical Logs
online log
16
On-Bar Features
Parallel backup and restore System and dbspace level backup and restore Support for incremental backups Manual or automatic backup of logical logs Instance point-in time recovery Open interface for communication with storage managers (XBSA) Re-Directed Restore
17
OnBar Architecture
onbar Storage Manager
Backup Media onconfig
X B S A
onbar_d
Database server
debug log
activity log
sysutils
online log
18
EBR allows administrators to make a consistent copy of their dbspaces using external tools
Used with many 3rd party backup products Allows for both cold and warm restores
Basic Steps
Block server at checkpoint Backup dbspace(s) using third party tools Unblock server
19
Flash Copy
Requires Storage System Capability Use EBR technique to block server for copy
Informix Host
IDS IDS IDS on-bar
FlashCopy Backups
20
21
Fla s h Co p y E ...
St o r a g e Lo g i c a l Lo g s Sp a c e s
I SM Lo g s
Fla s h Co p y
P r o d u ctio n Se r ve r A
Fl a s h Co p y
P P RC
P P R C Co p y C Fla s h Co p y B
22
Overview
Backup and Restore
New & Recent Features
Backup Options Restore Options Best Practices
23
Best Practices
1.Planning
2.Planning
3.Planning
24
25
26
Choose Two!
27
Recovery Strategy
Select Tools
Overview
Backup and Restore
New & Recent Features
Backup Options Restore Options Best Practices
29
Secondary server
Read only server : allows read only query Always in recovery mode Receives logs from primary and replay them to keep in sync with primary
When Primary server goes down, secondary server takes over as Standard server
30
Limitations
Indexes are locked when created on primary (till they are shipped to secondary) No Replication of Blobspace blobs (only) Non logged databases are not replicated
31
HDR Setup
Primary Secondary
B
Logs onmode d p / onbar r -p ontape secondary Server-A
Primary
1) Backup made of primary server 2) Notify primary server identity of secondary 3) Physical restore backup on secondary server 4) Notify secondary server identity of primary 5) Logical log transmission begins
32
Primary
Secondary
Can be Updated
AcctTable
LogRecvr
drsecapply
Recovery Buffer
HDR Buffer DRINTERVAL Sets maximum time lag in seconds for HDR buffer transmission Set to -1 for synchronous.
Reception Buffer
Primary
Secondary
34
Primary Down
onmode d standard
Secondary Standard
Standard Primary
A
onmode d secondary Server-B
1) Switch Server-B to primary mode 2) Physical restore of failed system (if media failure) or restart Server-A to last checkpoint time 3) Notify Secondary server-A identity of Primary server 4) Possibly restore offline/backed up logs 5) Automatically transfers current logs from primary and resume
36
DRTIMEOUT
Actual value is 4 times of this
DRAUTO
Controls how the secondary should changes modes
DRLOSTFOUND
37
HDR Threads
Main thread
Primary: dr_prsend Secondary: dr_secrecv Primary: dr_prping Secondary: dr_secping Primary: dr_idx_send (dr_btsend) Secondary: dr_idx_recv(dr_btrecv)
Ping thread
Index thread
38
Overview
Backup and Restore
New & Recent Features
Backup Options Restore Options Best Practices
39
Validating Archives
Does not have to be run on the same computer as the archive was taken
Uses very little space ~50MB Both onbar and ontape
40
Validation
onbar -v [ other options ]
Are my backups usable?
Run a verification before you need to restore
41
42
onbar -v
(IUS 9.X)
Sample Output:
1999-06-28 105444 23595 23594 /spare2/9.20/bin/onbar_d -v Successfully connected to Storage Manager. Begin backup verification of level 0 for rootdbs (Storage Manager copy ID 102). Completed level 0 backup verification successfully. /spare2/9.20/bin/onbar_d complete, returning 0 (0x00)
43
Overview
Backup and Restore
New & Recent Features Backup Options Restore Options Best Practices
44
External Directives
The ability to add directives to SQL statements without modifying the program
Re-Send Index
In an HDR environment copy an index from the primary to correct a corrupted index on the secondary
ER auto resync
Automatically resync or repair tables in ER
45
Other HA Features
Database mirroring
Thread suspension Online configuration tuning Online index checking Dynamic lock table allocation (avoiding out of locks) Event Alarms automatic notification of database events Enterprise Replication
46
Questions
47