概要:
通过服务器管理器安装远程桌面服务会报错一直没有办法解决
之后了解到安装组件可以通过powershell命令安装
 
powershell命令说明
https://docs.microsoft.com/en-us/windows-server/administration/server-manager/install-or-uninstall-roles-role-services-or-features#install-roles-role-services-and-features-by-using-windows-powershell-cmdlets
 
以管理员身份运行 powershell 
 
查看所有角色和组件
Get-WindowsFeature *
 
安装远程桌面会话主机和远程桌面授权两项组件
通过  (Get-WindowsFeature RSAT-RDS-Licensing-*).Name 调出了带有省略号的组件全称
Install-WindowsFeature Remote-Desktop-Services,RDS-RD-Server, RDS-Licensing,RSAT-RDS-Tools,RDS-Licensing-UI,RSAT-RDS-Licensing-Diagnosis-UI
 
用来删除角色和组件的命令
Uninstall-WindowsFeature -Name <feature_name> -computerName <computer_name> -Restart  
posted on 2023-01-11 16:20  06  阅读(133)  评论(0编辑  收藏  举报