The Set-WmsScheduledUpdate cmdlet sets the schedule for Windows updates and custom maintenance scripts for a computer running MultiPoint Server with disk protection enabled and configured for discard mode.
Examples
Example 1: Enable Windows updates on MultiPoint Server
This command configures the local MultiPoint Server to check for available Windows updates at 2:00 AM, apply the updates, and return the computer to the power state it was in before updates were applied.
To update the MultiPoint Server, the command performs these operations:
Restart the computer to disable disk protection.
Apply pending Windows updates.
Restart the computer to enable disk protection and to return it to the previous power state.
Parameters
-AutomaticUpdateMode
Specifies the type of automatic updates to process.
The acceptable values for this parameter are:
None
WindowsOnly
WindowsAndOtherPrograms
Parameter properties
Type:
EAutomaticUpdateMode
Default value:
None
Accepted values:
None, WindowsOnly, WindowsAndOtherPrograms
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-CustomScript
Specifies the full path of a user-supplied command to run at update time.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-HourToScheduleUpdates
Specifies the hour at which to run automatic updates.
The acceptable values for this parameter are: 0-23.
Parameter properties
Type:
UInt32
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-MaxTimeAllowedForCustomScript
Specifies the maximum amount of time that the custom script is allowed to run.
After this amount of time expires, the process is stopped and the system is restarted to re-enable disk protection.
Parameter properties
Type:
UInt32
Default value:
None
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-ReturnState
Specifies the state in which to place the computer after updates are complete.
The acceptable values for this parameter are: Shutdown and PreviousState.
Parameter properties
Type:
EScheduleUpdateReturnState
Default value:
None
Accepted values:
Shutdown, PreviousState
Supports wildcards:
False
DontShow:
False
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
-Server
Specifies the fully qualified host name of the MultiPoint Server that is the target of the command.
The default is localhost.
Parameter properties
Type:
String
Default value:
None
Supports wildcards:
False
DontShow:
False
Aliases:
ComputerName
Parameter sets
(All)
Position:
Named
Mandatory:
False
Value from pipeline:
False
Value from pipeline by property name:
True
Value from remaining arguments:
False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters.