如何远程关闭或重新启动Windows PC

image

Windows includes Shutdown.exe, a simple utility for remotely shutting down or restarting Windows computers on your local network. To use Shutdown.exe, you must first configure the PCs you want to shut down or restart remotely.

Windows包含Shutdown.exe,这是一个用于远程关闭或重新启动本地网络上Windows计算机的简单实用程序。 要使用Shutdown.exe,必须首先配置要关闭或远程重新启动的PC。

Once you’ve configured the PCs, you can use a graphical user interface or command to restart the PCs from another Windows system. You can even remotely shut down or restart the PCs from a Linux system.

一旦配置了PC,就可以使用图形用户界面或命令从另一个Windows系统重新启动PC。 您甚至可以从Linux系统远程关闭或重新启动PC。

组态 (Configuration)

The remote registry service must be enabled on each computer you want to shut down remotely – it’s disabled by default.

必须在要远程关闭的每台计算机上启用远程注册表服务-默认情况下处于禁用状态。

To enable it, first launch the Services control panel on the computer you want to shut down remotely. To do this, click the Start button, type services.msc into the Start menu and press Enter.

要启用它,请首先在要远程关闭的计算机上启动“服务”控制面板。 为此,请单击“开始”按钮,在“开始”菜单中键入services.msc ,然后按Enter。

Locate the “Remote Registry” service in the list, right-click it and select Properties.

在列表中找到“远程注册表”服务,右键单击它,然后选择“属性”。

image

From the properties window, set the Startup type to Automatic and click the Start button to launch the service.

在属性窗口中,将“启动类型”设置为“自动”,然后单击“启动”按钮以启动服务。

image

Next, you’ll have to open the required port in the computer’s firewall. Click Start, type “Allow a program” and press Enter. In the window that appears, click the “Change settings” button. Scroll down in the list and enable the “Windows Management Instrumentation (WMI)” exception.

接下来,您必须在计算机的防火墙中打开所需的端口。 单击开始,键入“允许程序”,然后按Enter。 在出现的窗口中,单击“更改设置”按钮。 在列表中向下滚动并启用“ Windows Management Instrumentation(WMI)”例外。

image

Your user account must also have administrator permissions on the remote computer. If it doesn’t, the shutdown command will fail due to lack of permissions.

您的用户帐户还必须在远程计算机上具有管理员权限。 否则,由于缺少权限,shutdown命令将失败。

远程关机 (Remote Shut Down)

To shut down the computer, launch a Command Prompt window on another computer (click Start, type Command Prompt, and press Enter). Type the following command into the command prompt window for a graphical interface:

要关闭计算机,请在另一台计算机上启动“命令提示符”窗口(单击“开始”,键入“ 命令提示符” ,然后按Enter)。 在图形界面的命令提示符窗口中键入以下命令:

shutdown /i

关闭/ i

From the remote shutdown dialog window, you can add one or more computer names and specify whether you want to shut down or restart the system. You can optionally warn users and log a message to the system’s event log.

在远程关闭对话框窗口中,您可以添加一台或多台计算机名称,并指定要关闭还是重新启动系统。 您可以选择警告用户,并将消息记录到系统的事件日志中。

image

Not sure what the name of the remote computer is? Click Start on the remote computer, right-click Computer in the Start menu, and select Properties. You’ll see the computer’s name.

不确定远程计算机的名称是什么? 单击远程计算机上的“开始”,右键单击“开始”菜单中的“计算机”,然后选择“属性”。 您会看到计算机的名称。

image

You can also use a command instead of the graphical interface. Here’s the equivalent command:

您也可以使用命令代替图形界面。 这是等效的命令:

shutdown /s /m \\chris-laptop /t 30 /c “Shutting down for maintenance.” /d P:1:1

关闭/ s / m \\ chris-laptop / t 30 / c“关闭以进行维护。” /天P:1:1

image

从Linux关闭 (Shut Down From Linux)

Once you’ve set up the computer, you can also shut it down from a Linux system. This requires the samba-common package installed – you can install it on Ubuntu with the following command:

设置计算机后,您也可以从Linux系统中将其关闭。 这需要安装samba-common软件包–您可以使用以下命令将其安装在Ubuntu上:

sudo apt-get install samba-common

sudo apt-get install samba-common

Once you have, use the following command from a terminal:

拥有后,从终端使用以下命令:

net rpc shutdown -I ip.address -U user%password

净rpc关闭-I ip.address -U用户%password

Replace “ip.address” with the numerical address of the Windows computer, “user” with the username of an account that has administrator privileges on the remote computer, and “password” with the user account’s password. You can add a “-r” option to the command if you want the computer to restart instead of shutting down.

将“ ip.address”替换为Windows计算机的数字地址,将“ user”替换为在远程计算机上具有管理员特权的帐户的用户名,并将“ password”替换为该用户帐户的密码。 如果希望计算机重新启动而不是关闭,则可以在命令中添加“ -r”选项。

image


If you have remote desktop access, you can also access the desktop and shut down or restart that way. The shutdown.exe command is a faster way of doing the same thing designed for system administrators – you can shut down or reboot multiple computers much faster than you could by logging into them one-by-one.

如果您具有远程桌面访问权限 ,则还可以访问桌面并以这种方式关闭或重新启动。 shutdown.exe命令是一种为系统管理员设计的执行相同操作的更快方法-与一台计算机一次登录相比,关闭或重新启动多台计算机的速度要快得多。

翻译自: https://www.howtogeek.com/109655/how-to-remotely-shut-down-or-restart-windows-pcs/

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值