PowerShell远程操作:会话、作业与远程执行全解析
1. 启用WinRM服务
在使用PowerShell进行远程操作之前,需要对WinRM(Windows Remote Management)服务进行配置,使其能够接收请求并允许远程访问。以下是具体的配置步骤:
1. 设置WinRM服务类型为延迟自动启动 :这将确保WinRM服务在系统启动后自动启动,但会有一定的延迟,避免影响系统启动速度。
2. 启动WinRM服务 :启动该服务后,它将开始监听并处理远程请求。
3. 配置LocalAccountTokenFilterPolicy :此配置可授予本地用户远程管理的行政权限。
4. 创建WinRM监听器 :在HTTP://*上创建监听器,以接受针对该机器任何IP的WS - Man请求。
以下是配置过程中的示例交互:
WinRM is not set up to receive requests on this machine.
The following changes must be made:
Set the WinRM service type to delayed auto start.
Start the WinRM service.
Configure LocalAccountTokenFilterPolicy to grant administrative rights
remotely to local u
超级会员免费看
订阅专栏 解锁全文
1

被折叠的 条评论
为什么被折叠?



