The Database Design Resource Center

Uninstall SQL Server

There may be occasions when you want to uninstall SQL Server. Some of the reasons for uninstalling include:
  • Failed installation and unable to solve through troubleshooting – if you have chosen to re-install SQL Server as a last resort ling remember to always uninstall first.
  • You want to change the collation of your instance.
  • You may simply want upgrade your hardware, move SQL Server to a new box and take the license with it.
  • There may also be times when you need to reconfigure/restore your master database, you don’t have to uninstall SQL Server to do this as SQL Server comes with a utility to allow you do this and we also cover this in this article.

We will first look at how to uninstall SQL Server and then look at rebuilding the master database.

Step by Step Guide

To uninstall an existing installation of SQL Server 7.0 or SQL Server 2000 (default or named instance):

  • Insert the Microsoft SQL Server compact disc in your CD-ROM drive. If the compact disc does not autorun, double-click Autorun.exe in the root directory of the compact disc.
  • Select SQL Server 2000 Components, select Install Database Server, and then setup will prepare the SQL Server Installation Wizard. At the Welcome screen, click Next.
  • In Computer Name dialog box, select Local Computer or Remote computer.
  • In the Installation Selection dialog box, click Upgrade, Remove, or Add Components to an existing instance of SQL Server, and then click Next.
  • In the Instance Name dialog box, Default is selected if you have the Default instance installed. If you want to uninstall a named instance, select it from the Instance Name list box, and then click Next.
  • In the Existing Installation dialog box, click Uninstall your existing installation, and then click Next.
  • Setup removes the selected installation. In the Uninstalling dialog box, click Next, and then in the Setup Complete dialog box, click Finish.

You should now have managed to uninstall SQL Server completely.

Rebuilding the Master Database

If your master database has become corrupt then instead of reinstalling SQL Server you can use the rebuildm utility that come with SQL Server.


Once you have confirmed you have all the backup files and SQL scripts needed to restore to your SQL Server instance when the rebuild of the master has completed you can begin the rebuild of the master database procedure. The following tutorial will take you through rebuilding the master database for your SQL Server 2000 installation - the process is similar for SQL Server 7 but may vary for other versions:

  • Shutdown SQL Server - stop all necessary services, and then run Rebuildm.exe. This is located in the Program FilesMicrosoft SQL Server80ToolsBin directory.
  • In the Rebuild Master dialog box, click Browse. vIn the Browse for Folder dialog box, select the Data folder on the SQL Server 2000 compact disc or in the shared network directory from which SQL Server 2000 was installed, and then click OK – you may need to copy this to a local drive from the SQL Server CD. vClick Settings. In the Collation Settings dialog box, verify or change settings used for the master database and all other databases. The default collation settings will be select, but these may not match the collation selected during setup. You can select the same settings used during setup or select new collation settings. When done, click OK. vIn the Rebuild Master dialog box, click Rebuild to start the process. The Rebuild Master utility reinstalls the master database.

Once this has completed you will need to restore all other user databases and other objects that will now be missing since the master database has been restored, in affect you have rebuilt your SQL Server.

I would recommend, especially for your production environments, that you keep a detailed backup recovery plan in the event of server failure, this will include Backup files and transaction logs and scripts that can be used to recreate logins and other objects needed on your server, that falls outside the scope this article but there are other articles on this site that can help you formulate a backup recovery plan. Read much more about performing SQL Server DBA functions in another section of this site.


This article has talked about how to uninstall SQL Server and rebuilding the master databases in the event of failure. SQL Server today is a stable and reliable platform, but I can’t emphasise enough the importance of being familiar with these procedures, you never know when you will have to carry out the process in real live environment.

Return to installing SQL Server database

Exclusive interviews with:
Steven Feuerstein, PLSQL expert
Donald Burleson, Top IT consultant

Free eBook

Subscribe to my newsletter and get my ebook on Entity Relationship Modeling Principles as a free gift:

What visitors say...

"I just stumbled accross your site looking for some normalization theory and I have to say it is fantastic.

I have been in the database field for 10+ years and I have never before come across such a useful site. Thank you for taking the time to put this site together."

Mike, USA

Read more Testimonials

Database Normalization eBook:

Database Normalization eBook

Copyright © / Alf A. Pedersen
All rights reserved.
All information contained on this website is for informational purposes only.
Disclaimer: does not warrant any company, product, service or any content contained herein.

Return to top

Copyright acknowledgement note:

The name Oracle is a trademark of Oracle Corporation.
The names MS Access/MS SQL Server are trademarks of Microsoft Corporation.
Any other names used on this website may be trademarks of their respective owners, which I fully respect.