Reputation: 21
I am installing Sql server via NSIS. but while connecting to Sql by Sqlconnection object in C# It gives me error that "Network Related or instance specific error..."
I am using following code. I need to create named instance as SQLEXpress2
ExecWait '"$INSTDIR\SQLEXpress2\SQLEXPRWT_x64_ENU.exe" /q /action=Install /features=SQL,SSMS /instancename=SQLEXpress2/IACCEPTSQLSERVERLICENSETERMS="True" /enableranu=1 /AddCurrentUserAsSqlAdmin="True" /SQLSVCACCOUNT="NT AUTHORITY\SYSTEM" /SQLSYSADMINACCOUNTS="" /AGTSVCACCOUNT="NT AUTHORITY\SYSTEM" /skiprules=RebootRequiredCheck'
and I notices in Sql configuration manager the remote procedure call fails and named pipe , TCP ip protocols are disabled.
Upvotes: 0
Views: 438
Reputation: 851
I have installed SQL Express 2014 SP1 with silent installation using nsis script which works successfully.
Function InstallSQL
ExecWait '"$temp\SQLEXPRADV_x64_ENU.EXE" /Q /ACTION=Install /SkipRules=RebootRequiredCheck /IACCEPTSQLSERVERLICENSETERMS /FEATURES=SQL,SSMS /INSTANCENAME="SQLEXPRESS2014" /SQLSVCACCOUNT="NT AUTHORITY\Network Service" /SQLSVCStartupType=Automatic /AddCurrentUserAsSqlAdmin /ENABLERANU=1 /hideconsole /SECURITYMODE=SQL /SAPWD="Sql@1234" /AGTSVCSTARTUPTYPE=Manual /NPENABLED=1 /TCPENABLED=1'
FunctionEnd
Upvotes: 1