I am installing all-in-one machine having SQL and sharepoint. I am specifying the sql alias for the same machine and the port as I want to have TCP connection. however the script tries to create the shared memory connection .
my computer is DEV1
my config is
<Database>
<DBServer>SPSQL</DBServer>
<DBAlias Create="true" DBInstance="DEV1" DBPort="1433" />
<DBPrefix>SP</DBPrefix>
<ConfigDB>Config</ConfigDB>
</Database>
solution:
change function Add-SQLAlias
replace the line
If ((MatchComputerName $SQLInstance $env:COMPUTERNAME) -or ($SQLInstance.StartsWith($env:ComputerName +"\"))) {
with
If ((MatchComputerName $SQLInstance $env:COMPUTERNAME) -or ($SQLInstance.StartsWith($env:ComputerName +"\")) -and ($port-eq '')) {
my computer is DEV1
my config is
<Database>
<DBServer>SPSQL</DBServer>
<DBAlias Create="true" DBInstance="DEV1" DBPort="1433" />
<DBPrefix>SP</DBPrefix>
<ConfigDB>Config</ConfigDB>
</Database>
solution:
change function Add-SQLAlias
replace the line
If ((MatchComputerName $SQLInstance $env:COMPUTERNAME) -or ($SQLInstance.StartsWith($env:ComputerName +"\"))) {
with
If ((MatchComputerName $SQLInstance $env:COMPUTERNAME) -or ($SQLInstance.StartsWith($env:ComputerName +"\")) -and ($port-eq '')) {