Monday, November 16, 2009

Backup and Restore the Update Server SQL 2005 Database and Storage Directory

Backup the PLUS and PLUS_Staging Databases
- Click Start, Run, and type [iisreset /stop] and press Enter to stop Internet Information Services.
- For 6.3 Update server, type [net stop "PatchLink Distribution Service"] to stop the PatchLink Distribution Service. In 6.4 update server, type [net stop "PatchLink Replication Service"] to stop the PatchLink Replication Service.
- Open SQL Server Management Studio (Express Edition can be downloaded for free on Microsoft's web site).
- Users can authenticate into the database by using "Windows Authentication."
- Drill down to the PLUS database.
- Right-click on PLUS and select Tasks > Backup
- In the General tab > Source section, click the drop down and choose PLUS
- Under Backup set, name the file to be backed up
- In the Destination section, click the remove button to remove the entry
- Click the Add button, click the Ellipse button to browse to where the backup file will be created. Once you choose a directory, type the same name into the File Name field as stated for the file name listed in the General > Backup set section.
- Click OK until you get back to the Back UP Database –PLUS screen.
- Click Options > Overwrite media, choose Overwrite all existing backup sets.

Backup the PLUS Storage Directory
Make a backup copy of the %Program Files%\Patchlink\Update Server\Storage directory on the same frequency as your PLUS Database backups.

Restore the PLUS and PLUS_Staging Databases
Use Microsoft SQL 2005 Management Studio or Express Edition to restore the Plus and Plus Staging databases.
Perform the steps which follow on the PLUS database, then follow the same procedure for the PLUS_Staging database, substituting PLUS_Staging for PLUS where appropriate.

- Open SQL Server Management Studio (Express Edition can be downloaded for free on Microsoft's web site).
- Drill down to the PLUS database.
- Right-click on PLUS and select Delete.
- In the Delete Object screen, uncheck Delete backup and restore history information for Databases and place a check mark for Close existing connections. Click OK.
- Right click on Databases, click New Database.
- In the General section, name the file PLUS. Click OK.
- Right click on the PLUS database. Click Tasks >Restore >Database.
- In the Destination for restore section, Choose the PLUS database. Under Source for restore, choose From device
- Under Source for restore, click the ellipse button. Click Add.
- For Files of type, click the drop down arrow, choose All Files. Locate the PLUS backup file and highlight that file. Click OK. Click OK again to the Specify Backup screen.
- In the Restore Database Plus screen, Place a check mark in the box under Select the Backup sets to restore
- Click Options. Under Restore options, place a check mark for "Overwrite the existing database".
- Under Recovery state, choose default "Leave the database ready to use by rolling back uncommitted transactions. Additional transaction logs cannot be restored. (RESTORE WITH RECOVERY)". Click OK.
- Once the restoring of the plus database is complete, a pop up message will state "The restore of database 'PLUS' completed successfully".
- From a CMD prompt, type [iisreset] to start Internet Information Services. Open service manager, start the World Wide Web Publishing Service
- For 6.3 Update server, Type [net start "PatchLink Distribution Service"] to start the PatchLink Distribution Service. In 6.4 update server, type [net start "PatchLink Replication Service"] to start the PatchLink Replication Service.