[wix-users] localized names for NT AUTHORITY\NETWORK SERVICE and BUILTIN\Administrators

Evan Ross eross99 at yahoo.com
Wed Nov 17 20:17:08 PST 2021


Hi all,
New to the list and I'm trying to solve a problem with a SQL Server bootstrapper install on a PC that might not be English Language.
Because of this I need to be able to refer to the NT AUTHORITY\NETWORK SERVICE and BUILTIN\Administrators accounts in the InstallCommand line in their localized names on the machine. (for example
NT-AUTORITÄT\NETZWERKDIENST on a German language machine)


I have the following fragment after my bundle to handle the SQL install
<Fragment>
    <PropertyRef Id="WIX_ACCOUNT_ADMINISTRATORS"/>
    <PropertyRef Id="WIX_ACCOUNT_NETWORKSERVICE"/>

    <PackageGroup Id="SQLSERVER">
      <ExePackage Id="Sql2019Express"
                 DisplayName="SQL Server 2019 Express"
                 Cache="yes"
                 Compressed="yes"
                 PerMachine="yes"
                 Permanent="no"
                 Vital="yes"
                 Name="SQLEXPR_x64_ENU.exe"
                 SourceFile="Resources\SQLEXPR_x64_ENU.exe"
                 InstallCommand="/ACTION=Install 
                                 /INSTANCENAME=$(var.InstanceName) 
                                 /FEATURES=SQL 
                                 /SECURITYMODE=SQL 
                                 /SAPWD=[SqlVariable] 
                                 /TCPENABLED=1 
                                 /SQLSVCACCOUNT="[WIX_ACCOUNT_NETWORKSERVICE]"
                                 /SQLSVCSTARTUPTYPE=Automatic 
                                 /SQLSYSADMINACCOUNTS=[WIX_ACCOUNT_ADMINISTRATORS]
                                 /ADDCURRENTUSERASSQLADMIN=FALSE 
                                 /Q 
                                 /IAcceptSQLServerLicenseTerms"
                 UninstallCommand="/Action=Uninstall /INSTANCENAME=$(var.InstanceName) /FEATURES=SQL /Q ">

        <ExitCode Value ="3010" Behavior="forceReboot" />
      </ExePackage>
    </PackageGroup>
  </Fragment>

For whatever reason the values for WIX_ACCOUNT_NETWORKSERVICE and WIX_ACCOUNT_ADMINISTRATORS are returning nothing as seen in the install log (see SQLSVCACCOUNT and SQLSYSADMINACCOUNTS )

C:\ProgramData\Package Cache\004A55528A3D38224B71C2DE0D1A3291DAEF5E0F\SQLEXPR_x64_ENU.exe, arguments: '"C:\ProgramData\Package Cache\004A55528A3D38224B71C2DE0D1A3291DAEF5E0F\SQLEXPR_x64_ENU.exe" /ACTION=Install /INSTANCENAME=***** /FEATURES=SQL /SECURITYMODE=SQL /SAPWD=***** /TCPENABLED=1 /SQLSVCACCOUNT="" /SQLSVCSTARTUPTYPE=Automatic /SQLSYSADMINACCOUNTS= /ADDCURRENTUSERASSQLADMIN=FALSE /Q /IAcceptSQLServerLicenseTerms'

Am I not getting the PropertyRef at the right time?  I'm probably a little confused about how it works and what it should refer to.

Any help or ideas here will be greatly appreciated.  Thanks!







More information about the wix-users mailing list