If you plan on leveraging Sitecore 9.1 SIF to perform a distributed installation, there are few keys things to consider.
What is a Distributed SIF Installation
In a Distributed SIF Installation, which is a feature available starting with Sitecore 9.1, you can select the desired implementation level such as XM1 or XP1 and deploy “all at once” to your targets.
As an example, if you had a Virtual Machine (VM) for the CMS/Processing/Reporting roles, a VM for the Identity Server role, another VM for CDS role, and finally another VM for xConnect… you can install all the roles from a single server instead of installing a server at a time.
This server is referred to as the Distributor (Source) while the servers you are installing roles onto are the Target (Destination) servers.
PS-Remoting must be installed on all the target servers. As a matter of practice, I also like to install it on the distributor. This opens up WinRM and other communication aspects so you can deploy from source to target.
PS-Remoting is enabled by running the following PowerShell command on the desired servers:
A basic test to confirm connectivity is as follows:
Test-WSMan -ComputerName "scrusktarget1.sitecore.local"
SIF Deployment Account
An Active Directory account with local machine Administrator access is required to deploy across the targets. Without this, the remote servers can’t execute the required PowerShell as it needs Admin rights.
Create a single user in AD (making sure all your Sitecore Servers are domain joined) and add this account to the local admin group on each server. If you create an generic user with the same name on each server, it will fail as these are technically not the same user account.
In your Distributed SIF PowerShell, you should see the following section. This is where you will get prompted to add the name and password of your AD Deployment User.
#Getting Hosts User credentials: Write-Host "Hosts user name: " $HostsUserName = Read-Host Write-Host "Hosts user password: " $HostsUserPassword = Read-Host Clear-Host
Make Sure Prerequisites are Installed
You must install the Sitecore Prerequisites on every Sitecore and Solr Target
In the past, installing the Sitecore 9 Prereqs was painful and likely required you to develop or find your own script. In Sitecore 9.1, Sitecore provides a SIF Prereqs JSON file to automate this process.
Important: You will need to install SIF on each VM, noting the correct version before you run the SIF Prereqs. Please see the Sitecore Installation Guide for details (this can be downloaded from the Sitecore Downloads page.
One approach to installing SIF via PowerShell is as follows:
Register-PSRepository -Name sc-powershell -SourceLocation https://sitecore.myget.org/F/sc-powershell/api/v2 # Install Sitecore Fundamentals (Required for Standard Operations) Install-Module -Name "SitecoreFundamentals" -RequiredVersion "1.1.0" -Repository "sc-powershell" -Force # Install Sitecore Install Framework Install-Module -Name "SitecoreInstallFramework" -RequiredVersion "2.0.0" -Repository "sc-powershell"
Make Sure all WDP Packages and SIF Resources are Saved on the Target Servers
When you run a Distributed Installation, the Powershell executed on the target machine will look for its own file system for the WDP Packages and SIF Resources to complete its role deployment (ex. CDS).
To that end, Sitecore recommends that you use the same folder name and location on each target server, such as c:\resourcefiles
Can’t Install Roles Onto Itself (Distributor Can’t Deploy to Itself)
And now for the gotcha. Where you deploy from is critical. One might think that you can use one of your Sitecore servers as the Distributor. As an example, that you would execute the Distributed Installation from your CMS Server and target the other servers that have differing roles.
However, a Sitecore 9.1 SIF Distributed Installation cannot deploy to itself. As it is using PS-Remoting, you will be unable to install a role on the Distributor because it can’t remote to itself.
So, what options do you have? You need to have a machine (or VM) on the domain to act as the dedicated Distributed that will not have Sitecore or Solr roles installed on it. This can be a “Utility Server” for long term use, or a temporary machine used for installation purposes.