dcsimg

SMS Site Recovery Overview

By ServerWatch Staff (Send Email)
Posted Nov 25, 2001


by Dana Daugherty

Be prepared before failure happens. This article will help you become familiar with the process of site recovery.

Dana Daugherty's latest contribution helps you become more familiar with the process of SMS site recovery. The article specifically focuses on repairing and resynchronizing tasks that you should perform on recovered sites.

Microsoft describes a SMS recovery as installing a SMS site with the same site code and server name of a site that was previously used in that hierarchy. The central tasks of a recovery include repairing and resynchronizing data. These tasks are extremely important for minimizing down time and ensuring that data is not corrupted.

 If any of these scenarios occur the entire site will need to be recovered:

  • The computer on which the site server or the SMS site database is installed fails.
  • The drive containing Microsoft Windows. NT 4.0 operating system, Microsoft SQL Server, or SMS fails.
  • Windows NT fails and must be restored.
  • The file system becomes corrupted.
  • SQL Server fails and must be restored.
  • The SQL Server database (or databases) becomes corrupted.

 

Why a Full Recovery is Necessary in These Scenarios

SMS has pieces in many locations of a server. Registry settings, Windows NT\2000 operating system, SMS directory and SQL database all contain site specific information that changes based on several factors. The information located at these locations use codes to ensure synchronization. If the codes get out of synch, the results could stop your SMS site dead in its tracks.

For example, let's say you need to restore the registry of the primary server. One location of the SMS key holds the Transaction ID. If this number gets out of sync, the site wont be able to replicate data.

The phases of a recovery are:

  1. Planning for maximum uptime
  2. Implementing procedures
  3. Backing up data
  4. Failure
  5. Rebuilding servers
  6. Restoring data (optional)
  7. Repairing/Resynchronizing
  8. Verifying success
  9. Understanding the cause of failure
  10. Loop back to step 1

Recovery\Resynchronization Tasks

This article focuses on step 7, repairing/resynchronizing. Below are two of several tasks that you should perform on recovered sites:

Increment the Transaction ID - Sites send transactions both up and down the hierarchy. The recovering sites transaction ID needs to be higher than any .trs files on sites that will receive transactions from the recovering site. (SMS\inboxes\replmgr.box\history)

The recovering site's transaction ID is stored in the site's registry in
  HKEY_LOCAL_MACHINE
    Software
      Microsoft
        SMS
          COMPONENTS
            SMS_REPLICATION_MANAGER
              Transaction ID

Increment Serial Numbers in the Site Database (SQL 7.0)

Run this query from Query Analyzer:

Use SmS_Site_Code

Select * From NextIDS

Calculate the new values for the serial numbers NextCollectionId, NextOfferId, and NextPackageId using the method appropriate to your situation:


X      Site database never failed, not restored. Add 20 to the values found in the NextIDS table for NextCollectionID, NextOfferID, and NextPackageID; this will prevent collisions.


X      Site restored from an SMS backup. Child sites store these values in \SMS\Inboxes\Replmgr.box\history\Site_Code.TRS. Take a sampling of child site .TRS files and compare the highest values for NextCollectionId, NextOfferId, and NextPackageId to the values in the site database's NextIDS table. Add 20 to the highest of the two values.


X      No SMS backup, but child sites are available. Take a sampling of child site .TRS files (as described above), and then add 20 to the highest values found.

 

Changing Values in the NextIDS Table

 In the following examples, replace value with the new decimal values you have calculated. Queries are executed by clicking the green arrow on the toolbar:

On the site database computer, open Microsoft SQL Server 7.0, Query Analyzer.

Make the site database the current database by running the following query:

USE SMS_Site_Code

Run the following query:

UPDATE NextIds SET IdValue = value WHERE IdName = 'NextCollectionId'

Run the following query:

UPDATE NextIds SET IdValue = value WHERE IdName = 'NextPackageId'

Run the following query:

UPDATE NextIds SET IdValue = value WHERE IdName = 'NextOfferId'

 

For more information on Site Repair\Recovery click on the link and scroll down to the Repair section:

http://www.microsoft.com/smsmgmt/techdetails/recovery/RecoveryExpert/Topics/ZAllTasks.htm

Page 1 of 1


Comment and Contribute

Your name/nickname

Your email

(Maximum characters: 1200). You have characters left.