Change the Farm Passphrase


Scenario/Problem: You want to change the farm passphrase.


Solution: Use the Set-SPPassPhrase cmdlet with the PassPhrase parameter.

The Set-SPPassPhrase cmdlet is used solely to change the SharePoint farm passphrase. This passphrase was initially entered during the installation of the SharePoint farm. Provide a secure string value with the PassPhrase parameter, as shown in Listing 4.5.

Listing 4.5. Changing the Farm Passphrase


Set-SPPassPhrase -PassPhrase (ConvertTo-SecureString -asplaintext
-force -string "SharePoint1")


For scripting purposes, if you do not want to be prompted to confirm the passphrase entry, include the ConfirmPassPhrase parameter and switch off the general confirmation, as shown in Listing 4.6.

Listing 4.6. Changing the Farm Passphrase Without Prompts


Set-SPPassPhrase -PassPhrase (ConvertTo-SecureString -asplaintext
-force -string "SharePoint1") -ConfirmPassPhrase
(ConvertTo-SecureString -asplaintext -force -string "SharePoint1")
-Confirm:$false



Tip

The default operation performs the passphrase modification for the entire farm. If you run into issues, use the LocalServerOnly switch parameter to perform the modification on only the current server. Continue on each server in the farm to pinpoint the problem.


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.133.137.17