Watch out! They are everywhere…

Silent install of SQL Server 2008

Are you having trouble installing SQL Server 2008 from the command prompt? I tried installing SQL Server Express 2008 by looking at the reference on MSDN. The trouble was it kept failing time and again and the screen disappeared faster than you can see what the error message was. Fortunately, the installer creates a Summary.txt file in the folder C:\Program Files\Microsoft SQL Server\100\Setup Bootstrap\Log. Opening the file will tell you exactly what the error message is.

But sometimes even this isn’t enough. In my case, I was quickly able to find that I needed PowerShell for installing SQL Server Express with Advanced Services – which was quickly fixed, but it kept failing with this exception -

Exception type: Microsoft.SqlServer.Setup.Chainer.Workflow.NoopWorkflowException
Message:
No features were installed during the setup execution.The requested features may already be installed. Please review the summary.txt log for further details.

Our friend Google wasn’t of much help, so I decided to do a non-command line install to see if it was installing in the machine. It turns out, once you manually set all the configuration information, the installer creates a file called ConfigurationFile.ini and puts those settings there. This shows up in the Ready to Install step -

The installer then uses this file to do the actual install. Now, if you open the configuration file, you will find that these are the same settings you can set from the Command line. It looks something like this -

There you have it – the right command line parameters to install SQL Server 2008 Express with Advanced Services silently from the command prompt. You can choose to remove some of the parameters that have default values or just leave them as they are – it doesn’t really matter.

Like this:

Related

29 responses

I have tried what have you told here.Like i took the configuration file from my manual installation. But could you give me command to install. I tried by the command “C:\SQLEXPR.EXE /qb /settings c:\SQL2005.ini” Dint work gave some setting syntax error. Could you give me a solution for this. I am attaching my summary File.

Hi,
Thanks for the tip on the configuraton.ini file.
I have attempted to use this method, but each time I receive an error advising that the configuration file is not located in the temporary folder that the SQL Install creates to install from.

Checking install:
the key place to check is %Programfiles%\Microsoft sql server\100\Setup bootstrap\Log\. To begin, open the Summary__.txt file to see an overview of the results. If that doesn’t help, consider reviewing one of the Detail*.txt files. These errors are all addressed in KB909967 – How to troubleshoot SQL Server 2008 Setup issues.

With the release of SQL Server 2008 R2, by default the ConfigurationFile.ini is not created when installing the Express version. Check out this blog entry for a solution on how to get the installer to generate the ConfigurationFile.ini:

Same here, I don’t see a Ready To Install step and I can’t find a Configuration.ini file anywhere. Furthermore, when I attempt to hand create a config file I get an error when I attempt to execute SQLEXPR32_x86_ENU.exe /CONFIGURATIONFILE=”Install.ini”: error: The configuration file ‘c:\____\Install.ini’ does not exist. Specify a valid configuration file. Error code 0x84B40000. Not sure why it can’t find the file. There must be a way to specify a file that is not in the root of the C:\ drive. What a stupid default path for config files.

Many of my customers have already some version of SQL Server on their computer. The installation is therefor often aborted, because the installer wants you the update the current installation. This means the already partly installed new SQL Server remains installed (including my own INSTANCE). In order to install my own instance of SQL Server (latest version) I have to manually uninstall the previous installation and even remove some registry entries pointing to my instance. Then I can upgrade the old SQL Server and after that I can install my own instance.
I would be nice if this could be handled by the initial installer (ask if current server must be updated).
Or maybe there is a way to ignore all of this and just install the instance of the newer version of SQL Server.

; Specify the Instance ID for the SQL Server features you have specified. SQL Server directory structure, registry structure, and service names will reflect the instance ID of the SQL Server instance.

INSTANCEID=”SQLExpress”

; Specifies a Setup work flow, like INSTALL, UNINSTALL, or UPGRADE. This is a required parameter.

ACTION=”Uninstall”

; Specifies features to install, uninstall, or upgrade. The list of top-level features include SQL, AS, RS, IS, and Tools. The SQL feature will install the database engine, replication, and full-text. The Tools feature will install Management Tools, Books online, Business Intelligence Development Studio, and other shared components.

FEATURES=SQLENGINE,REPLICATION,FULLTEXT,RS,BIDS,SSMS,SNAC_SDK,OCS

; Displays the command line parameters usage

HELP=”False”

; Specifies that the detailed Setup log should be piped to the console.

INDICATEPROGRESS=”True”

; Specifies that Setup should install into WOW64. This command line argument is not supported on an IA64 or a 32-bit system.

X86=”False”

; Detailed help for command line argument ROLE has not been defined yet.

ROLE=”AllFeatures_WithDefaults”

; Detailed help for command line argument ENU has not been defined yet.

ENU=”True”

; Specify if errors can be reported to Microsoft to improve future SQL Server releases. Specify 1 or True to enable and 0 or False to disable this feature.

; Specify that SQL Server feature usage data can be collected and sent to Microsoft. Specify 1 or True to enable and 0 or False to disable this feature.

SQMREPORTING=”False”

; Specify a default or named instance. MSSQLSERVER is the default instance for non-Express editions and SQLExpress for Express editions. This parameter is required when installing the SQL Server Database Engine (SQL), Analysis Services (AS), or Reporting Services (RS).

INSTANCENAME=”SQLEXPRESS”

; Agent account name

AGTSVCACCOUNT=”AUTORITE NT\SERVICE RÉSEAU”

; Auto-start service after installation.

AGTSVCSTARTUPTYPE=”Disabled”

; Startup type for Integration Services.

ISSVCSTARTUPTYPE=”Automatic”

; Account for Integration Services: Domain\User or system account.

ISSVCACCOUNT=”NT AUTHORITY\NetworkService”

; Controls the service startup type setting after the service has been created.

ASSVCSTARTUPTYPE=”Automatic”

; The collation to be used by Analysis Services.

ASCOLLATION=”Latin1_General_CI_AS”

; The location for the Analysis Services data files.

ASDATADIR=”Data”

; The location for the Analysis Services log files.

ASLOGDIR=”Log”

; The location for the Analysis Services backup files.

ASBACKUPDIR=”Backup”

; The location for the Analysis Services temporary files.

ASTEMPDIR=”Temp”

; The location for the Analysis Services configuration files.

ASCONFIGDIR=”Config”

; Specifies whether or not the MSOLAP provider is allowed to run in process.

ASPROVIDERMSOLAP=”1″

; A port number used to connect to the SharePoint Central Administration web application.

FARMADMINPORT=”0″

; Startup type for the SQL Server service.

SQLSVCSTARTUPTYPE=”Automatic”

; Level to enable FILESTREAM feature at (0, 1, 2 or 3).

FILESTREAMLEVEL=”0″

; Set to “1″ to enable RANU for SQL Server Express.

ENABLERANU=”True”

; Specifies a Windows collation or an SQL collation to use for the Database Engine.

SQLCOLLATION=”French_CI_AS”

; Account for SQL Server service: Domain\User or system account.

SQLSVCACCOUNT=”MyUserSQLSrv”

; Windows account(s) to provision as SQL Server system administrators.

SQLSYSADMINACCOUNTS=”MyUserAdm”

; The default is Windows Authentication. Use “SQL” for Mixed Mode Authentication.

SECURITYMODE=”SQL”

; Default directory for the Database Engine backup files.

SQLBACKUPDIR=”S:\VUR\MSSQL10_50.SQLEXPRESS\MSSQL\BACKUP”

; Default directory for the Database Engine user database logs.

SQLUSERDBLOGDIR=”J:\VUR\MSSQL10_50.SQLEXPRESS\MSSQL\Data”

; Directory for Database Engine TempDB files.

SQLTEMPDBDIR=”H:\VUR\MSSQL10_50.SQLEXPRESS\MSSQL\Data”

; Provision current user as a Database Engine system administrator for SQL Server 2008 R2 Express.

ADDCURRENTUSERASSQLADMIN=”True”

; Specify 0 to disable or 1 to enable the TCP/IP protocol.

TCPENABLED=”1″

; Specify 0 to disable or 1 to enable the Named Pipes protocol.

NPENABLED=”0″

; Startup type for Browser Service.

BROWSERSVCSTARTUPTYPE=”Automatic”

; Specifies which account the report server NT service should execute under. When omitted or when the value is empty string, the default built-in account for the current operating system.
; The username part of RSSVCACCOUNT is a maximum of 20 characters long and
; The domain part of RSSVCACCOUNT is a maximum of 254 characters long.

RSSVCACCOUNT=”MyUserSSRS”
RSSVCPASSWORD=”myPassword”

; Specifies how the startup mode of the report server NT service. When
; Manual – Service startup is manual mode (default).
; Automatic – Service startup is automatic mode.
; Disabled – Service is disabled

I am trying to run the script to install SQL Server 2008 R2 remotely, but it does not work. When I run the script locally on the machine the install starts, but not when I attempt to run the script remotely. Can you tell me what I am doing wrong or what I am missing in order to get this to work?

Hi! I know this is kinda off topic however , I’d figured I’d ask.
Would you be interested in trading links
or maybe guest authoring a blog article or
vice-versa? My website covers a lot of the same topics as yours
and I believe we could greatly benefit from each other. If you’re interested feel free to send me an e-mail. I look forward to hearing from you! Awesome blog by the way!