SQL BackTrack

2,439 views

Published on

  • Be the first to like this

SQL BackTrack

  1. 1. SQL-BackTrack for Sybase 高正宗 System Consultant Manager 黃仁政 System Consultant
  2. 2. Agenda <ul><ul><li>資料庫的可用性 </li></ul></ul><ul><ul><li>系統架構 </li></ul></ul><ul><ul><li>產品功能說明 </li></ul></ul><ul><ul><li>實機展示 </li></ul></ul><ul><ul><li>產品比較 </li></ul></ul>
  3. 3. 資料可用性的策略 Severity of Database Downtime Planned Unplanned Catastrophic Latency of Database Recovery No Downtime High Availability Continuous Availability Disaster Recovery Online Maintenance Offline Maintenance High Availability Clusters Switching and Warm Standby Replication Cold Standby
  4. 4. <ul><li>80% of all unplanned downtime is caused by software or human error* </li></ul><ul><li>70% of recovery is &quot;think time&quot; ! </li></ul>復原作業的問題 *Source: Gartner, “Aftermath: Disaster Recovery”, Vic Wheatman, September 21, 2001
  5. 5. 確保復原作業 SQL-BackTrack automates the entire process! Analysis Source Preparation Restore Recover Post-op Identify location of and retrieve backup data Issues the appropriate commands needed to prepare the database for the recovery process Copies backup data to the correct destination Issues the appropriate command in the correct sequence Perform appropriate post-recovery clean-up processes Investigate data loss/ corruption and discover what information must be replaced
  6. 6. Why SQL-BackTrack? An example of a recovery of a Sybase database using the native utility <ul><li>Determine which database to recover </li></ul><ul><li>Determine where backups are located </li></ul><ul><li>If the backups are striped locate all the stripes </li></ul><ul><li>Order the backups in the required sequence to be applied. </li></ul><ul><li>Determine the recovery type: physical, transaction log , is there a specific point in time for the recovery </li></ul><ul><li>If it is a point in time recovery determine the transaction log backups to be applied. </li></ul><ul><li>Start an isql session </li></ul><ul><li>Issue load database </li></ul><ul><li>Issue load transaction for all the transaction log backups </li></ul><ul><li>If the recovery is PIT issue load transaction with until_time </li></ul><ul><li>Issue online database or online for standby access </li></ul><ul><li>Determine if the database and application are ready for production use. </li></ul>
  7. 7. Why SQL-BackTrack? An example of a recovery of a Sybase database using the native utility <ul><li>Determine which database to recover </li></ul><ul><li>Determine where backups are located </li></ul><ul><li>If the backups are striped locate all the stripes </li></ul><ul><li>Order the backups in the required sequence to be applied. </li></ul><ul><li>Determine the recovery type: physical, transaction log , is there a specific point in time for the recovery </li></ul><ul><li>If it is a point in time recovery determine the transaction log backups to be applied. </li></ul><ul><li>Start an isql session </li></ul><ul><li>Issue load database </li></ul><ul><li>Issue load transaction for all the transaction log backups </li></ul><ul><li>If the recovery is PIT issue load transaction with until_time </li></ul><ul><li>Issue online database or online for standby access </li></ul><ul><li>Determine if the database and application are ready for production use. </li></ul>SQL-BackTrack reduces this effort to 2 STEPS!!
  8. 8. Agenda <ul><ul><li>資料庫的可用性 </li></ul></ul><ul><ul><li>系統架構 </li></ul></ul><ul><ul><li>產品功能說明 </li></ul></ul><ul><ul><li>實機展示 </li></ul></ul><ul><ul><li>產品比較 </li></ul></ul>
  9. 9. 備份作業
  10. 10. 復原作業
  11. 11. OBSI 模組整合 ASE SQL-BackTrack BT Module Server Program Media/ Client Program Tape Devices Juke Boxes <ul><ul><li>IBM Tivoli Storage Manager </li></ul></ul><ul><ul><li>VERITAS NetBackup DataCenter </li></ul></ul><ul><ul><li>Legato NetWorker </li></ul></ul>
  12. 12. OBSI 模組整合
  13. 13. Agenda <ul><ul><li>資料庫的可用性 </li></ul></ul><ul><ul><li>系統架構 </li></ul></ul><ul><ul><li>產品功能說明 </li></ul></ul><ul><ul><li>實機展示 </li></ul></ul><ul><ul><li>產品比較 </li></ul></ul>
  14. 14. Common SQL-BackTrack Features <ul><ul><li>Dry run backup and recovery </li></ul></ul><ul><ul><li>Table recovery from physical backup </li></ul></ul><ul><ul><li>Unattended on-line and off-line backup </li></ul></ul><ul><ul><li>Incremental backups </li></ul></ul><ul><ul><li>Compression and encryption </li></ul></ul><ul><ul><li>Storage management integration </li></ul></ul><ul><ul><li>Guided recovery </li></ul></ul>
  15. 15. Unique SQL-BackTrack Features for Sybase <ul><ul><li>Master database recovery </li></ul></ul><ul><ul><ul><li>Needs to be rebuilt, if lost or damaged </li></ul></ul></ul><ul><ul><ul><li>Generates Master Database Recovery template script to recover </li></ul></ul></ul><ul><ul><li>Remote administration </li></ul></ul><ul><ul><li>Warm stand-by server support </li></ul></ul><ul><ul><li>Table level recovery includes recovery of dependent objects (triggers, etc.) </li></ul></ul>
  16. 16. Unique SQL-BackTrack Features over Sybase Native Utilities <ul><ul><li>Logical Object extraction features: </li></ul></ul><ul><ul><ul><li>DDL Only </li></ul></ul></ul><ul><ul><ul><li>DDL + Data </li></ul></ul></ul><ul><ul><ul><li>Specific objects or object types like: stored procedures only or tables only … </li></ul></ul></ul><ul><ul><ul><li>Will add objects to database in dependency order. For instance, will compile stored procedures into database in dependency order. </li></ul></ul></ul><ul><ul><ul><li>Can exclude specific objects like: exclude sysusers, sysalternates tables when copying database to another server. Or you can exclude a type of object like exclude all triggers. </li></ul></ul></ul><ul><ul><ul><li>Extract/restore database object and all of it’s dependent objects </li></ul></ul></ul><ul><ul><ul><li>Default is fast bcp in, unless told to do otherwise. Automatically takes care of rebuilding indexes. </li></ul></ul></ul>
  17. 17. Unique SQL-BackTrack Features over Sybase Native Utilities <ul><ul><li>Logical restore options make shrinking your database much easier. 1 step - do a logical restore to a smaller database. </li></ul></ul><ul><ul><li>Warm Stand-by Server Support </li></ul></ul><ul><ul><li>Master database info, writes a text file of useful information about the master database such as device, configuration, database, sysusages, and syslogin information taken from a physical backup. Very useful in recovering the master database. </li></ul></ul>
  18. 18. Unique SQL-BackTrack Features over Sybase Native Utilities <ul><ul><li>Can restore data to a database using full sql insert statements -- useful if “select into/bulk copy” option is turned off </li></ul></ul><ul><ul><li>Can restore data to a different segment. Useful if you want to eliminate segments or move data from one segment to another </li></ul></ul><ul><ul><li>Prints database allocation info. (sysusages) from a physical backup. Useful if you have to manually recreate the database. </li></ul></ul><ul><ul><li>Supports calling SQL-BackTrack log dump commands from a stored procedure. Useful for thresholds. </li></ul></ul>
  19. 19. Agenda <ul><ul><li>資料庫的可用性 </li></ul></ul><ul><ul><li>系統架構 </li></ul></ul><ul><ul><li>產品功能說明 </li></ul></ul><ul><ul><li>實機展示 </li></ul></ul><ul><ul><li>產品比較 </li></ul></ul>
  20. 20. SQL-BackTrack Components SQL-BackTrack Control Directory (with Control Files) sbacktrack Executables (main BT program) . dtoptions file . dtoptions file . dtoptions file SQL Server SQL Server SQL Server Backup device OBSI Software Backup device OBSI Software Backup device OBSI Software
  21. 21. SQL-BackTrack Executables (lower-level SQL-BackTrack programs) sbacktrack (main BT program) dtsbackup dtsrecover dtsload dtsdump dtscheck dtscreate
  22. 22. SQL-BackTrack Control Directory sbackups.logical sbackups.physical /usr/sbt/ Server1 Server 2 Server 1 Server 2 .dtoptions DB1 DB2
  23. 23. Special Recovery Situations <ul><ul><li>Copying a database to a different machine / Migrating a database </li></ul></ul><ul><ul><li>Object extraction from physical backups </li></ul></ul><ul><ul><li>Resizing a database </li></ul></ul><ul><ul><li>Generating recovery templates(Master) </li></ul></ul>
  24. 24. Agenda <ul><ul><li>資料庫的可用性 </li></ul></ul><ul><ul><li>系統架構 </li></ul></ul><ul><ul><li>產品功能說明 </li></ul></ul><ul><ul><li>實機展示 </li></ul></ul><ul><ul><li>產品比較 </li></ul></ul>
  25. 25. SQL-BackTrack for Sybase vs Competition ASE and extension are limited to scripts. SBT obtains relevant logs at backup time automatically. Limited Limited YES  Transaction Log Backup Automation SBT’s Logical Extraction feature can recover tables, stored procedures, triggers, etc. directly from a physical backup NO NO YES  Logical object recovery from a physical backup NO NO YES  Logical database backup ASE and extensions will only migrate data . SBT backups up table schema, dependencies, and data. (SBT unique) Limited Limited YES  Logical object backup <ul><ul><li>NO </li></ul></ul><ul><ul><li>YES </li></ul></ul>Extensions (VERITAS & Legato) YES YES Physical database backup (full) NO ASE 12.0/ 12.5 <ul><ul><li>SBT’s intelligent incremental backup feature writes only physical data blocks that have changed since last backup </li></ul></ul>YES  Physical database backup (Incremental) Comments SBT Function  Unique/noteworthy feature
  26. 26. SQL-BackTrack for Sybase vs Competition SBT allows users to recover information to alternate locations (Powerful DR support tool) NO NO YES  Recover to alternate host, database NO NO YES  Dry Run Recovery <ul><ul><li>ASE (BCP utility) and extensions will logically backup data but not schema and is limited to environments with same OS and ASE levels. SBT will migrate data between differing ASE and OS versions as well as between varying database page sizes. </li></ul></ul><ul><ul><li>Limited </li></ul></ul>Limited YES  Migration Limited Extensions (VERITAS & Legato) <ul><ul><li>ASE automation limited to commands included in scripts created by DBA. Extensions allow ASE scripts to be scheduled for execution. SBT provides guided recovery to automate backup & recovery as well as generate scripts automatically for use in scheduler. </li></ul></ul>Limited YES  Automation ASE 12.0/ 12.5 Comments SBT Function  Unique/noteworthy feature
  27. 27. SQL-BackTrack for Sybase vs Competition Master Database recovery is a tedious, manual process. SBT greatly simplifies process by generating template with relevant information in support of recovery. Limited Limited YES  Master Database Recovery Template Extensions (VERITAS & Legato) ASE 12.0/ 12.5 Comments SBT Function  Unique/noteworthy feature Limited NO Extensions provide vendor specific support. SBT Modules provide seamless integration with IBM Tivoli Storage Manager (TSM), VERITAS NetBackup DataCenter, and Legato NetWorker NO YES  Storage Manager Integration NO SBT can recover tables, stored procedures, triggers, etc. directly from a physical backup YES  Encryption
  28. 28. Questions and Discussion

×