Skip to main content
SnapCenter 6.0 cmdlets

Set-SmHost

Contributors

Modifies either the port or the group Managed Service Account (gMSA) or the credential name of the host.

Syntax

Set-SmHost [-HostName]  <String>  [-Port]  <UInt16>  [-CredentialName]  <String>  [-UseGMSA]  <Boolean>  [-GMSAName]  <String>  [-PushServerCredentialsToSCV]  <SwitchParameter>  [-Force]  <SwitchParameter>

Detailed Description

Modifies either the port or the group Managed Service Account (gMSA) or the credential name of the host. Only one parameter can be modified at a time.

Parameters

Name Description Required? Pipeline Input Default Value

HostName

The name of the host whose port or credential name will be modified.

true

true (ByPropertyName)

Port

The port to be modified.

false

true (ByPropertyName)

CredentialName

The credential name to be modified.

false

true (ByPropertyName)

UseGMSA

Modify the plug-in services logon from gMSA to domain or LocalSystem.

false

true (ByPropertyName)

GMSAName

The group Managed Service Account (gMSA) name to be modified.

false

true (ByPropertyName)

PushServerCredentialsToSCV

Push the credentials to the SCV host.

false

true (ByPropertyName)

Force

false

true (ByPropertyName)

Examples

Example 1: Modifying port from 8145 to 8185

 Set-SmHost -HostName h1 -Port 8185

This example modifies the port of host h1 to 8185.

Example 2: Modifying credential name from RunAs1 to RunAs2

 Set-SmHost -HostName h1 -CredentialName RunAs2

This example modifies the credential name of host h1 to RunAs2.

Example 3: Modifying group Managed Service Account (gMSA) name from NewDomain\gMSAName1$ to NewDomain\gMSAName2$

 Set-SmHost -HostName h1.NewDomain.com -UseGMSA:$true -GMSAName NewDomain\gMSAName2$

This example modifies the gMSA name for host h1.NewDomain.com to NewDomain\gMSAName2$.

Example 4: Disabling group Managed Service Account (gMSA)

 Set-SmHost -HostName h1.NewDomain.com -UseGMSA:$false

This example disables the gMSA and modifies the plug-in services to Domain or LocalSystem for host h1.NewDomain.com.