< Back

Set-SmbServerConfiguration

Wed Jan 30, 2019 6:00 pm

NAME Set-SmbServerConfiguration



SYNOPSIS

Sets the SMB Service configuration.





SYNTAX

Set-SmbServerConfiguration [-AnnounceComment <String>] [-AnnounceServer <Boolean>] [-AsynchronousCredits <UInt32>] [-AutoDisconnectTimeout <UInt32>]

[-AutoShareServer <Boolean>] [-AutoShareWorkstation <Boolean>] [-CachedOpenLimit <UInt32>] [-CimSession <CimSession[]>]

[-DurableHandleV2TimeoutInSeconds <UInt32>] [-EnableAuthenticateUserSharing <Boolean>] [-EnableDownlevelTimewarp <Boolean>] [-EnableForcedLogoff

<Boolean>] [-EnableLeasing <Boolean>] [-EnableMultiChannel <Boolean>] [-EnableOplocks <Boolean>] [-EnableSecuritySignature <Boolean>]

[-EnableSMB1Protocol <Boolean>] [-EnableSMB2Protocol <Boolean>] [-EnableStrictNameChecking <Boolean>] [-EncryptData <Boolean>] [-Force] [-IrpStackSize

<UInt32>] [-KeepAliveTime <UInt32>] [-MaxChannelPerSession <UInt32>] [-MaxMpxCount <UInt32>] [-MaxSessionPerConnection <UInt32>] [-MaxThreadsPerQueue

<UInt32>] [-MaxWorkItems <UInt32>] [-NullSessionPipes <String>] [-NullSessionShares <String>] [-OplockBreakWait <UInt32>]

[-PendingClientTimeoutInSeconds <UInt32>] [-RejectUnencryptedAccess <Boolean>] [-RequireSecuritySignature <Boolean>] [-ServerHidden <Boolean>]

[-Smb2CreditsMax <UInt32>] [-Smb2CreditsMin <UInt32>] [-SmbServerNameHardeningLevel <UInt32>] [-ThrottleLimit <Int32>] [-TreatHostAsStableStorage

<Boolean>] [-ValidateAliasNotCircular <Boolean>] [-ValidateShareScope <Boolean>] [-ValidateShareScopeNotAliased <Boolean>] [-ValidateTargetName

<Boolean>] [-Confirm] [-WhatIf] [<CommonParameters>]





DESCRIPTION

The Set-SmbServerConfiguration cmdlet sets the Server Message Block (SMB) Service configuration.





PARAMETERS

-AnnounceComment [<String>]

Specifies the announce comment string.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-AnnounceServer [<Boolean>]

Indicates that this server announces itself by using browser announcements.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-AsynchronousCredits [<UInt32>]

Specifies the asynchronous credits.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-AutoDisconnectTimeout [<UInt32>]

Specifies the auto disconnect time-out.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-AutoShareServer [<Boolean>]

Indicates that the default server shares are shared out.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-AutoShareWorkstation [<Boolean>]

Indicates whether the default workstation shares are shared out.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-CachedOpenLimit [<UInt32>]

Specifies the maximum number of cached open files.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-CimSession [<CimSession[]>]

Runs the cmdlet in a remote session or on a remote computer. Enter a computer name or a session object, such as the output of a New-CimSession or

Get-CimSession cmdlet. The default is the current session on the local computer.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-DurableHandleV2TimeoutInSeconds [<UInt32>]

Specifies the durable handle v2 time-out period, in seconds.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableAuthenticateUserSharing [<Boolean>]

Indicates whether authenticate user sharing is enabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableDownlevelTimewarp [<Boolean>]

Indicates whether down-level timewarp support is disabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableForcedLogoff [<Boolean>]

Indicates whether forced logoff is enabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableLeasing [<Boolean>]

Indicates whether leasing is disabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableMultiChannel [<Boolean>]

Indicates whether multi-channel is disabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableOplocks [<Boolean>]

Indicates whether the opportunistic locks are enabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableSecuritySignature [<Boolean>]

Indicates whether the security signature is enabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableSMB1Protocol [<Boolean>]

Indicates whether the SMB1 protocol is enabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableSMB2Protocol [<Boolean>]

Indicates whether the SMB2 protocol is enabled.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EnableStrictNameChecking [<Boolean>]

Indicates whether the server should perform strict name checking on incoming connects.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-EncryptData [<Boolean>]

Indicates whether the sessions established on this server are encrypted.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-Force [<SwitchParameter>]

Forces the command to run without asking for user confirmation.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-IrpStackSize [<UInt32>]

Specifies the default IRP stack size.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-KeepAliveTime [<UInt32>]

Specifies the keep alive time.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-MaxChannelPerSession [<UInt32>]

Specifies the maximum channels per session.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-MaxMpxCount [<UInt32>]

Specifies the maximum MPX count for SMB1.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-MaxSessionPerConnection [<UInt32>]

Specifies the maximum sessions per connection.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-MaxThreadsPerQueue [<UInt32>]

Specifies the maximum threads per queue.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-MaxWorkItems [<UInt32>]

Specifies the maximum SMB1 work items.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-NullSessionPipes [<String>]

Specifies the null session pipes.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-NullSessionShares [<String>]

Specifies the null session shares.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-OplockBreakWait [<UInt32>]

Specifies how long the create caller waits for an opportunistic lock break.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-PendingClientTimeoutInSeconds [<UInt32>]

Specifies the pending client time-out period, in seconds.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-RejectUnencryptedAccess [<Boolean>]

Indicates whether the client that does not support encryption is denied access if it attempts to connect to an encrypted share.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-RequireSecuritySignature [<Boolean>]

Indicates whether the security signature is required.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-ServerHidden [<Boolean>]

Indicates whether the server announces itself.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-Smb2CreditsMax [<UInt32>]

Specifies the maximum SMB2 credits.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-Smb2CreditsMin [<UInt32>]

Specifies the minimum SMB2 credits.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-SmbServerNameHardeningLevel [<UInt32>]

Specifies the SMB Service name hardening level.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-ThrottleLimit [<Int32>]

Specifies the maximum number of concurrent operations that can be established to run the cmdlet. If this parameter is omitted or a value of 0 is

entered, then Windows PowerShell???? calculates an optimum throttle limit for the cmdlet based on the number of CIM cmdlets that are running on the

computer. The throttle limit applies only to the current cmdlet, not to the session or to the computer.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-TreatHostAsStableStorage [<Boolean>]

Indicates whether the host is treated as the stable storage.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-ValidateAliasNotCircular [<Boolean>]

Indicates whether the aliases that are not circular are validated.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-ValidateShareScope [<Boolean>]

Indicates that the existence of share scopes is checked during share creation.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-ValidateShareScopeNotAliased [<Boolean>]

Indicates whether the share scope being aliased is validated.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-ValidateTargetName [<Boolean>]

Indicates whether the target name is validated.



Required? false

Position? named

Default value none

Accept pipeline input? false

Accept wildcard characters? false



-Confirm [<SwitchParameter>]

Prompts you for confirmation before running the cmdlet.Prompts you for confirmation before running the cmdlet.



Required? false

Position? named

Default value false

Accept pipeline input? false

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]

Shows what would happen if the cmdlet runs. The cmdlet is not run.Shows what would happen if the cmdlet runs. The cmdlet is not run.



Required? false

Position? named

Default value false

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

None









OUTPUTS

None









Example 1: Set the SMB Service configuration



PS C:\\>Set-SmbServerConfiguration -MaxChannelPerSession 16

Confirm

Are you sure you want to perform this action?

Performing operation 'Modify' on Target 'SMB Service Configuration'.

[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Y"):



This command sets the SMB Service configuration.





Example 2: Set the SMB Service configuration without confirmation



PS C:\\>Set-SmbServerConfiguration -MaxChannelPerSession 32 -Force



This command sets the SMB Service configuration without user confirmation.







RELATED LINKS

Get-SmbServerConfiguration