Restart-Computer 参考 模块: Microsoft.PowerShell.Management 在本地和远程计算机上重启操作系统。 语法 PowerShell Restart-Computer[-WsmanAuthentication <String>] [[-ComputerName] <String[]>] [[-Credential]<PSCredential>] [-Force]
In the above PowerShell script, the Restart-Computer cmdlet has been used to restart multiple remote computers. Here, the -ComputerName parameter accepted DELL-computer_01 and DELL-computer_02 as names of remote computers that we want to restart. Have a look at another example: Use Restart-Co...
3] Restart a remote computer with shutdown.exe The shutdown.exe is the standard built-in executable that Windows offers to restart a system, and it’s not a PowerShell command but offers a robust series of options. An additional prerequisite for the command to work is, ensure that the re...
Restarts a network adapter by disabling and then re-enabling the network adapter.SyntaxPowerShell 复制 Restart-NetAdapter [-Name] <String[]> [-IncludeHidden] [-PassThru] [-CimSession <CimSession[]>] [-ThrottleLimit <Int32>] [-AsJob] [-WhatIf] [-Confirm] [<CommonParameters>]...
Use PowerShell to Restart a Computer The command below will immediately restart a remote computer. The -Force option will also force a restart even if a user is logged on: UNLOCK THE FULL SCRIPT Use Powershell to Restart a List of Computers in Your Company Network This command is handy ...
Restarts a network adapter by disabling and then re-enabling the network adapter.SyntaxPowerShell Copier Restart-NetAdapter [-Name] <String[]> [-IncludeHidden] [-PassThru] [-CimSession <CimSession[]>] [-ThrottleLimit <Int32>] [-AsJob] [-WhatIf] [-Confirm] [<CommonParameters>]...
public: property Microsoft::PowerShell::Commands::WaitForServiceTypes For { Microsoft::PowerShell::Commands::WaitForServiceTypes get(); void set(Microsoft::PowerShell::Commands::WaitForServiceTypes value); }; Property Value WaitForServiceTypes Attributes ParameterAttribute Applies to उत्प...
PowerShell.Commands Assembly: Microsoft.PowerShell.Commands.Management.dll Package: Microsoft.PowerShell.Commands.Management v7.4.0 Cmdlet to restart computer.C++ Copy public ref class RestartComputerCommand : System::Management::Automation::PSCmdlet, IDisposableInheritance Object InternalCommand Cmdlet ...
Applies To: Windows PowerShell 2.0 Restarts ("reboots") the operating system on local and remote computers. Syntax Copy Restart-Computer [[-ComputerName] <string[]>] [[-Credential] <PSCredential>] [-AsJob] [-Authentication {<Default> | <None> | <Connect> | <Call> | <Packet> | <Pack...
Example 1: Restart the specified network adapter PowerShell PS C:\>Restart-NetAdapter-Name"Ethernet 2"This command shows an alternate version of the above command that uses wildcard characters. PS C:\>Restart-NetAdapter-Name"E*2" This command restarts the network adapter named Ethernet 2. ...