SQL Server 2014 Express Silent install without Choose directory prompt
Asked Answered
T

3

6

I would like to do a silent install with /qs command to install sql server 2014 express. I did many installations with 2008 express and it did not have this kind of issue.

When I try to install, by double clicking the setup file or by command line install, it shows Choose directory for extracted files prompt. I have searched alot but I cannot find any information about this.

My question is: Is there a way to specify the path to be extracted along with other commands?

I thought /qs (silent mode) should not accept any user input which looks like it's a flaw in 2014 version. Any ideas?

Tiptoe answered 18/2, 2015 at 21:20 Comment(2)
What command line have you tried? Did you see the doc on command line or configuration file installs?Kanter
There is no command for choose directory input option. It is not listed in the msdn pages. I'm surprised MS changed it without giving an option to set the path and must accept user inputTiptoe
S
22

There was a change in the self-extract Express packages in SQL Server 2014. The default location where payload is extracted was changed. That location can be specified on the UI or on the command line.

To preset the location on the UI run:
SQLEXPR_x64_ENU.exe /x:LocationToExtract

To extract payload to a specific location without prompt use and with the progress bar use: SQLEXPR_x64_ENU.exe /u /x:LocationToExtract

To extract payload to a specific location without prompt and silent use: SQLEXPR_x64_ENU.exe /q /x:LocationToExtract

There is an issue that /qs parameter is not recognized and cannot be used the same way as in SQL 2012. That issue will be addressed in SQL Server 2014 Service Pack 1.

Answered from a official representative from microsoft. Here

Secateurs answered 18/2, 2015 at 23:15 Comment(5)
Thank you for the info. I have looked at that link before but didn't realize it was from the official rep from MS. Do you happen to know when SP 1 will be released? I will use /u as I want to show the progress to the user.Tiptoe
The link to "Answered from a official representative from microsoft." is no longer working, but the info in quote is still valid. Thanks!Corettacorette
This still works with the self-extract Express packages of SQL Server 2016.Swinton
Still works for SQL Server Express 2019Germanium
Finally found it! Thanks a lot, it is very badly documented on MS website and also the extractor does not even have an help option available with /?. Everywhere I looked they suggested using /extract: which does not work anymoreBamako
H
3

The SQL Server Express edition (e.g. 2014) allows itself to be installed silently. Other earlier versions of SQL Expression edition do so to.

Once you download the Microsoft installer, e.g: SQLEXPR_x64_ENU.exe

And you extract it, as explained in accepted answer, you can go further and install the product silently. The following is an example of how to install SQL Server Expression 2014 on a dump dummy test location.

setup.exe /q   /Action=Install /IAcceptSQLServerLicenseTerms=True /Features=SQL /InstanceName=SQLExpressTest01  /SQLSYSADMINACCOUNTS="Builtin\Administrators" /SQLSVCACCOUNT="NT AUTHORITY\Network Service" /INSTANCEDIR="c:\dev\dump\SQLExpressInstanceDir" /INSTALLSHAREDDIR="c:\dev\dump\SQLExpressInstanceDir"

An overview of command options to setup.exe is given by the Microsoft official documentation: https://social.technet.microsoft.com/wiki/contents/articles/940.how-to-embed-sql-server-express-in-an-application.aspx#advInstall

In the preceding examples:

/q – specifies that Setup run in a quiet mode without any user interface.
/Action – specifies which action to perform. In this example, the action is Install.
/Hideconsole – specifies that the console window is hidden or closed during the install.
/IAcceptSQLServerLicenseTerms - indicates acceptance of the Microsoft SQL Server license terms.
/Features – specifies which parent features and features to install. In this example, the parent feature SQL is installed, which includes SQLEngine, Replication, and Fulltext components. The Tools feature installs all of the tools components.
/InstanceName – specifies a SQL Server instance name.
/SQLSYSADMINACCOUNTS –provisions logins to be members of the system administrators role.
/SQLSVCACCOUNT – specifies the startup account for the SQL Server service.
/SQLSVCPASSWORD – specifies the password for SQLSVCACCOUNT.

What you cannot do with Microsfot SQL Server, bundle it stand-alone, as you would do with HSQL or PostgresSQL. Microsoft SQL Server needs to be installed running its full fledged installer on the target machine where your intend to run your application. Not the most portable database in this regard.

Hullabaloo answered 19/4, 2017 at 13:57 Comment(0)
H
2

This option can be put in ConfigurationFile.ini also:

x="C:\share\sql_temp"

But putting 'q' option there for silent install didn't work. So I put path into ini file and q option in command string, for example:

setup.exe /SAPWD="pass" /ConfigurationFile="A:\ConfigurationFile.ini" /q
Hypophosphate answered 1/12, 2015 at 9:14 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.