Wednesday, January 27, 2010

installing SQL Server 2008 Express from a configuration file

One of the applications we develop uses SQL Server Express as the database. This database is oftentimes installed for a single user on a single machine, and rarely is there anyone with any SQL Server knowledge around to help with the install.

Here's some tips on how to get a customized automated SQL Server 2008 Express install ready to be put on a CD and distributed:

- Start by walking through the installation manually on your test machine. When you get to the final screen before you push "install" there is a path to a generated ConfigurationFile.ini file with the settings you have just chosen. Handy! You can then cancel the installation, grab this configuration file and use it.

- Check the configuration file for any paths that may be referencing your local machine and fix them.

- Run the installer with the /CONFIGURATION file manually i.e. don't use the quiet install for testing. The installer will give you warnings as you go along about missing or incorrect values.

- Read Microsoft's How To install from the command line (the same parameters get used in the configuration file):
http://msdn.microsoft.com/en-us/library/ms144259.aspx#Install
It pretty much gives you all the information you will need about what should be in the configuration file.