Archive for the tag 'SQL Server Administration'

MSSQL Compressed Backup 1.0 Released

I've just released version 1.0 of MSSQL Compressed Backup.  This is a command line utility that allows you to backup or restore your SQL Server 2005 databases to/from compressed files such as zip, bzip2, or gzip.

http://mssqlcompressed.sourceforge.net/

Renaming a SQL Server machine

Below are a collection of links on how to rename a SQL Server server.

Rename the SQL Server engine. This describes how to run

sp_dropserver 'old_name'
go
sp_addserver 'new_name', 'local'
go

Rename SQL Server Reporting Services server. This describes how to update a config file with the new server name.

Correct an issue with SQL Server SP2 and Sysprep. This is needed when you run sysprep to rename the machine. The short of it is you will need to delete some registry entries.

SQL Server 2005 Compressed Backup

I've been working on a way to backup SQL Server 2005 databases to a compressed file recently, but without using temporary files. I recently found that it is actually pretty easy. SQL Server has an interface for creating a virtual backup device so that the data is pumped to your application, not a real device. Once the application has the data, it can compress it, encrypt it, or do whatever it likes. Maybe DBAs would like to save the data to an FTP server. There are so many options.

The application I wrote is called MSQL Compressed Backup which you can find on Sourceforge. It is currently in beta, and I don't plan to release a 1.0 version for awhile until it has had some testing by other people. If you are interested in it, please download a copy and give it a try.

Documentation is currently lacking, but here are a couple of examples. I think they are self explanatory.

  • msbp.exe backup [model] gzip file:///c:\model.bak.gz
  • msbp.exe restore file:///c:\model.bak.gz gzip [model]
    Here, gzip knows to uncompress since it is in "restore" mode.
  • msbp.exe backup [model] bzip2(level=5) file:///c:\model.bak.bz2
    Each plugin in the pipeline can have parameters.
  • msbp.exe backup [model] rate(ratemb=5.0) bzip2(level=5) file:///c:\model.bak.bz2
    You can have any number of plugins in the pipeline. The rate plugin limits the impact of a backup on your server by restricting the speed of the backup (or restore).