I am trying to use boostrapper (Wix 3.11) to set up an installation, with SQL Server 2014 Express as a prerequisite.
It works well when I install setup.exe
or SQLEXPR_x64_ENU.exe
with command line.
The command line is the following :
SQLEXPR_x64_ENU.exe /q /ACTION=Install /FEATURES=SQL
/INSTANCENAME=MSSQLSERVER /SQLSVCACCOUNT="NT AUTHORITY\Network Service"
/SQLSYSADMINACCOUNTS="NT AUTHORITY\Network Service"
/AGTSVCACCOUNT="NT AUTHORITY\Network Service"
/IACCEPTSQLSERVERLICENSETERMS /SECURITYMODE=SQL SAPWD="TestPassWord"
However, it fails when I try to run it from boostrapper. It always throws the same error.
Error: Action "Microsoft.SqlServer.Configuration.SetupExtension.ValidateFeatureSettingsAction" threw an exception during execution.
Microsoft.SqlServer.Setup.Chainer.Workflow.ActionExecutionException: Value cannot be null.
Parameter name: userName ---> System.ArgumentNullException: Value cannot be null.
The following is the code I'm using to set up an installer:
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi" xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
<?define Account = 'NT AUTHORITY\Network Service'?>
<?define SAPassword = "TestPassWord"?>
<Bundle Name="Setup" Version="1.0.0.0" Manufacturer="Company" UpgradeCode="{GUID}">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense">
<bal:WixStandardBootstrapperApplication
LicenseUrl=""
ThemeFile="HyperlinkTheme.xml"
LocalizationFile="HyperlinkTheme.wxl"
SuppressOptionsUI="yes" />
</BootstrapperApplicationRef>
<Chain>
<ExePackage Id ="SQL_express" SourceFile="$(var.PreReqPath)\SQLExpress\SQLEXPR_x64_ENU.exe" Compressed="yes" Vital="no" InstallCommand="/q /ACTION=Install /FEATURES=SQL /INSTANCENAME=MSSQLSERVER /SQLSVCACCOUNT=$(var.Account) /SQLSYSADMINACCOUNTS=$(var.Account) /AGTSVCACCOUNT=$(var.Account) /IACCEPTSQLSERVERLICENSETERMS /SECURITYMODE=SQL /SAPWD=$(var.SAPassword)" />
</Chain>
</Bundle>
</Wix>
I have tried to add Permachine="Yes" to the ExePackage line but it doesn't solve the problem.
I have also tried to right-click on the installer and run it as administrator but it still doesn't work.
Hopefully someone can help me with this issue.