Home > SQL Server Tips > Database Administration > Setting up and maintaining standby servers
SQL Server Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 

DATABASE ADMINISTRATION

Setting up and maintaining standby servers


Baya Pavliashvili, Contributor
03.14.2006
Rating: -4.50- (out of 5)


Expert advice on database administration
Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us    Add to Google


Standby servers are a great mechanism for ensuring the high availability of your enterprise applications. In this tip I'll define standby server and offer options and recommendations for configuring and maintaining such servers.

A standby server is a computer that is located in close proximity to the production server(s). A standby server can be used to temporarily replace a production server if it experiences a hardware failure. It could also be used to verify that you can recover databases from their full backups.

Important considerations when setting up a standby server

I will discuss this list of questions to ask yourself in greater detail below.

1. Will your standby server be used to verify backups or log shipping? Will it be used for both?

2. If the standby server is used strictly to verify production backups, what is the total size of all databases that you must verify?

3. How many production servers do you intend to replace with the standby server in case of a catastrophic event? What is the most powerful server you would need to replace with the standby server?

4. How much disk space would you need to restore all databases currently residing on production servers to be replaced with the standby server?

5. How much transaction log space is used when you perform index maintenance on your servers?

6. How many SQL Server logins do you use in your applications?

7. If your data must be available 100% of the time, even in the case of a natural disaster, do you have a safe, geographically separate location for storing your standby server?

8. Does your operating system and database management system have the same service packs on production and standby servers?

Using a standby server to ensure that database backups are valid

Let's say you're an enterprise DBA responsible for numerous mission-critical servers. You feel great about your disaster recovery strategy be


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us    Add to Google


RELATED CONTENT
Database Administration
Top load balancing methods for SQL Server
Performance implications of transaction log autogrowth in SQL Server
The keys to database backup protection for SQL Server
Understanding transparent data encryption in SQL Server 2008
Working with sparse columns in SQL Server 2008
Determining the source of full transaction logs in SQL Server
Implementing SQL Server 2008 FILESTREAM functionality
Improving SQL Server full-text search performance
Using the OPENROWSET function in SQL Server
New replication features in SQL Server 2008 and what they mean to you

SQL Server Backup and Recovery
The keys to database backup protection for SQL Server
Choosing a SQL Server disaster recovery solution
Licensing a standby server for SQL Server replication
Can I encrypt and restore a database backup in SQL Server 2005?
SQL Server errors, failures and other problems fixed from the trenches
Get SQL Server log shipping functionality without Enterprise Edition
SQL Server 2008 backup compression pros and cons
SQL Server backups using SAN database snapshots
Tips for scheduling and testing SQL Server backups
Code to restore SQL Server databases in VB.NET
SQL Server Backup and Recovery Research

Microsoft SQL Server 2005 (Yukon)
SQL Server Reporting Services Fast Guide
SQL Server Service Broker Tutorial and Reference Guide
Tips for tuning SQL Server 2005 to improve reporting performance
SQL Server consolidation: Why it's an optimization technique
Parent-child dimensions in SQL Server 2005 with Analysis Services MDX
Enforcing data integrity in a SQL Server database
SSIS error message due to installation problem on SQL Server 2005
Should you upgrade to SQL Server 2005 or SQL Server 2008?
Basics for working with DATETIME and SMALLDATETIME in SQL Server 2005
How to configure Database Mail in SQL Server 2005 to send mail
Microsoft SQL Server 2005 (Yukon) Research

RELATED GLOSSARY TERMS
Terms from Whatis.com − the technology online dictionary
rollback  (SearchSQLServer.com)

RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary


cause all of your backups seem to complete in a reasonable timeframe and your jobs never fail. Then one of your mission critical servers dies and you're left with a tape containing the full backup from the night before the failure. You quickly transfer the backup to the server you want to use in place of the one that is no longer available, fire up Enterprise Manager, choose "Restore Database" and … oops, you get an error similar to the following: "The backup set isn't valid." Murphy's Law never fails: Your backups may be useless when you need them most.

What can you do to avoid such situations? Make sure you can always restore databases from your backups. Fortunately SQL Server has come a long way from its humble beginnings. If you advise it to verify backups upon completion (as you absolutely should by using the RESTORE VERIFYONLY command), it will alert you to a backup problem. RESTORE VERIFYONLY was available in previous releases of SQL Server but wasn't always dependable. This statement has been enhanced with SQL Server 2005 to perform additional checking and increase the probability of detecting errors. However, the only true way to be 100% sure your backups are valid is to actually restore them and check the data on a standby server. Why, you would need a full-time employee to verify every single backup, you may complain. Judge for yourself: Would you prefer to lose mission critical data or hire an additional DBA to verify backups? In fact, if you automate the process of copying backups and restoring them to a standby server, you might not need an additional full-time DBA.

Using a standby server to continuously ship transaction log backups to a server replacing the production server in the event of a catastrophic failure

SQL Server provides a great mechanism for setting up a standby server – log shipping. Configuring log shipping is easily accomplished by using the Maintenance Plan Wizard. Note that log shipping is only supported in SQL Server Enterprise Edition. Any other edition requires you to configure log shipping manually, but you should be able to figure out how to copy and restore production database log backups to a standby server. Fortunately SQL Server 2005 supports log shipping with Standard Edition and Workgroup Edition as well as Enterprise Edition.

Whether you use the standby server to verify database backups or for log shipping you must ensure that the operating system and the database engine have the same service pack level as the production server. For example, if your production server is running Windows Server 2003 Service Pack 1, so should your standby server. This way if you fail over to the log shipping server, you can be sure your application will behave exactly the same as it does against the production server. The fewer variables you have to work with the easier it will be to switch over to the log shipping server when need arises.

About the author: Baya Pavliashvili is a DBA manager with Healthstream - the leader in online healthcare education. In this role, Baya oversees database operations supporting over one million users. Baya's primary areas of expertise include performance tuning, replication and data warehousing. He can be reached at baya.pavliashvili@healthstream.com.


More information from SearchSQLServer.com

  • Tip: Log shipping a replicated database
  • Tip: How to restore from a transaction log
  • Tip: Worst practices for SQL Server backup and recovery


  • Rate this Tip
    To rate tips, you must be a member of SearchSQLServer.com.
    Register now to start rating these tips. Log in if you are already a member.




    DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



    SQL Server Development - .NET, C#, T-SQL, Visual Basic
    HomeNewsTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersIT Downloads
    About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
    SEARCH 
    TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

    TechTarget Corporate Web Site  |  Media Kits  |  Site Map




    All Rights Reserved, Copyright 2005 - 2009, TechTarget | Read our Privacy Policy
      TechTarget - The IT Media ROI Experts