UserLock Documentation
UserLock Documentation
You are here: Reference > UserLock PowerShell > Cmdlet Help > Set-UserLockServerConfiguration

Set-UserLockServerConfiguration Cmdlet

Synopsis

Modifies the configuration of the UserLock server.

Syntax

Set-UserLockServerConfiguration [-Property] <string> [-Value] <string> [-UserLockServerName <string>] [-PassThru] [-Force] [-Confirm] [-WhatIf][<CommonParameters>]

Set-UserLockServerConfiguration [-InputObject] <ServerProperties> [-UserLockServerName <string>] [-PassThru] [-Force] [-Confirm] [-WhatIf][<CommonParameters>]

Description

The Set-UserLockServerConfiguration cmdlet modifies the configuration of the UserLock server. Caution: PowerShell 3.0 is required.

Parameters

-Property <string>

Specifies the name of the property to modify.

Required true
Position named
Accepts pipeline input false
Accepts wildcard characters false

-Value <string>

Specifies the new value of the property.

Required true
Position named
Accepts pipeline input false
Accepts wildcard characters false

-InputObject <ServerProperties>

Specifies a ServerProperties object representing the configuration of the UserLock server. Enter a variable that contains the object, or type a command or expression that gets the object. You can also pipe the objects to Set-UserLockServerConfiguration.

Required true
Position named
Accepts pipeline input true (ByValue)
Accepts wildcard characters false

-UserLockServerName <string>

Specifies the name of the UserLock server. The default is the localhost name.

Required false
Position named
Accepts pipeline input false
Accepts wildcard characters false
Default Value '.'

-PassThru <SwitchParameter>

Returns the concerned server property object (1st parameter set) or a ServerProperties object (2nd parameter set). By default, this cmdlet does not generate any output.

Required false
Position named
Accepts pipeline input false
Accepts wildcard characters false

-Force <SwitchParameter>

Modifies the configuration of the UserLock server with no confirmation.

Required false
Position named
Accepts pipeline input false
Accepts wildcard characters false

-Confirm <SwitchParameter>

Prompts you for confirmation before executing the command.

Required false
Position named
Accepts pipeline input false
Accepts wildcard characters false

-WhatIf <SwitchParameter>

Describes what would happen if you executed the command without actually executing the command.

Required false
Position named
Accepts pipeline input false
Accepts wildcard characters false

<CommonParameters>

For more information about common parameters, type "Get-Help about_commonparameters".

Input Type

ISDecisions.UserLockLibrary.ServerProperties

Return Type

None, Boolean, System.String, ISDecisions.UserLockLibrary.ServerMode or ISDecisions.UserLockLibrary.ServerProperties.

Notes

You can also refer to Set-UserLockServerConfiguration by its alias, "sulsc". For more information, see about_Aliases. To use Set-UserLockServerConfiguration, you must have the "Server properties" UserLock administrative access right.

Examples

Example 1

C:\PS>Set-UserLockServerConfiguration -Property MostRestrictive -Value True

Sets the MostRestrictive property of the localhost UserLock server to true, therefore the policy will be the most restrictive as possible.

Example 2

C:\PS>$ulsc = Get-UserLockServerConfiguration C:\PS>$ulsc.LogoffExceedingSessions = $true C:\PS>$ulsc.ExceedingSessionsOrder = 0 C:\PS>$ulsc | sulsc -Force

Get server properties into a local variable, modify LogoffExceedingSessions and ExceedingSessionsOrder properties of that variable, then sets all UserLock server properties with that variable as the input object, and with no confirmation prompt.

Related Links

Get-UserLockServerConfiguration

Set-UserLockAgentDistributionConfiguration

Get-UserLockCommand