AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / server / 问题 / 852144
Accepted
montooner
montooner
Asked: 2017-05-25 22:54:24 +0800 CST2017-05-25 22:54:24 +0800 CST 2017-05-25 22:54:24 +0800 CST

如何通过 Windows 10 独立远程管理 Hyper-V 2016?

  • 772

如何通过 Windows 10 笔记本电脑独立连接到 Hyper-V 2016?

背景:我将其设置为家庭实验室。我遵循 了 一些 指南,但我还没有找到似乎适用于 Hyper-V 2016 免费版的指南/Youtube 教程。这是 Hyper-V 独立版的“hello world”,我可以找不到适用于 2016 年的指南。(Hyper-V 2012 + Windows 8 似乎有一些自动化脚本可以解决问题,但不适用于 Hyper-V 2016。)

语境

  • 服务器:Hyper-V server 2016(免费,独立),fqdn:server.local,
  • 客户端:Windows 10 专业版
  • 补充说明
    • 客户端的 etc/hosts 文件包含服务器的 fqdn 条目
    • 客户端或服务器都不在工作组或域上
  • 我的目标:使用客户端的 Hyper-V 管理器远程管理服务器

错误

An error occurred while attempting to connect to server "server.local". Check that the 
Virtual Machine Management service is running and that you are authorized to
connect to the server. 

Hyper-V encountered an error trying to access an object on computer 'server.local' because 
the object was not found. The object might have been deleted. Verify that the Virtual 
Machine Management service on the computer is running.

我在服务器上做了什么

# sconfig.cmd: Enable "Configure Remote Management"
# sconfig.cmd: Add Local Administrator
# sconfig.cmd: Enabled Remote Desktop
Enable-PSRemoting
Enable-WSManCredSSP -Role server
sc start vmms                                  # Is this the "missing object"?
netsh advfirewall set currentprofile state off # Let's try disabling firewall

我在客户端做了什么

Set-Item WSMan:\localhost\Client\TrustedHosts -Value "server.local"
Enable-WSManCredSSP -Role client -DelegateComputer "server.local"
# Changed group policy: "Computer Configuration > Administrative Templates > System > Credentials Delegation > Allow delegating fresh credentials with NTLM-only server authentication" by doing: "Click Enable and add wsman/fqdn-of-hyper-v-host."
# Disabled firewall
# dcomcnfg > COM SECURITY > Access Permissions > Edit Limits > Anonymous Login > ALLOW Remote Access
cmdkey /add:YOURSERVERNAME /user:USERNAMEONTHESERVER /pass:THEPASSWORDOFTHATUSER

我是如何触发错误的

在客户端:

  1. 启动“连接到服务器”
    1. 尝试一个:“将'另一台计算机:'设置为'192.168.10.2'”
    2. 尝试二:“将‘另一台计算机:’设置为‘server.local’”
  2. 点击“确定”
  3. (错误:“尝试连接到服务器'server.local'时发生错误......)
hyper-v
  • 1 1 个回答
  • 54046 Views

1 个回答

  • Voted
  1. Best Answer
    montooner
    2017-05-28T21:48:11+08:002017-05-28T21:48:11+08:00

    找到了我的具体问题:) 我使用了无效的主机名,并且 DNS 没有正确解析。

    • 错误:server-1.local
    • 右:server-1-local

    但另一方面,我还发现 Microsoft 文档(使用 Hyper-V 管理器远程管理 Hyper-V 主机)没有记录我使事情正常进行所需的所有说明。它大部分是正确的,但缺少一步。所以我附上了我的手动设置说明。

    有关通过 Windows 10 Professional 远程管理 Hyper-V 2016 的完整设置说明,请参见下文。我的设置涉及两台独立的物理机器——我从头开始安装这两个系统。

    在 Hyper-V 服务器上

    1. 安装Hyper-V Server 2016(通过 GUI)
    2. 设置密码注意:在终端gui运行中更改以下内容sconfig
    3. 设置计算机名称(例如 server-1);注意:不要使用句号
    4. 配置远程管理(禁用 => 启用)
    5. 远程桌面(禁用 => 启用)
    6. 在 Powershell 窗口中,以管理员身份运行:

    Powershell 命令:

    Enable-PSRemoting
    Enable-WSManCredSSP -Role server
    

    在台式机/笔记本电脑上,您将远程管理 Hyper-V

    1. 安装 Windows 10 专业版/您的驱动程序/您的应用程序 (GUI)
    2. 更改网络适配器设置
      • 如果在 Windows 10 的旧补丁上
        • 单击开始>搜索“家庭组”>启动“家庭组”
        • 单击链接更改网络类型(公共 => 私有)
      • 如果在 Windows 10 的较新补丁上
        • 试试这个:转到“开始菜单>(类型)'以太网'>(单击)以太网适配器>(单击)私有”
    3. 在您的主机文件中添加一个 DNS 条目(以管理员身份运行记事本)
      • 编辑“C:\Windows\System32\drivers\etc\hosts”
      • 添加类似“192.168.100.2 server-1”的条目
    4. 在 Powershell 窗口中,以管理员身份运行:

    Powershell 命令:

    Enable-PSRemoting
    Set-Item WSMan:\localhost\Client\TrustedHosts -Value server-1
    Enable-WSManCredSSP -Role client -DelegateComputer server-1
    Enable-WindowsOptionalFeature -Online -FeatureName:Microsoft-Hyper-V -All
    cmdkey /add:server-1 /user:Administrator /pass
    

    笔记

    微软官方文档缺少cmdkey指令,该指令注册进入 Hyper-V 服务器所需的登录信息。我在一个单独的文档中找到了它。

    • 21

相关问题

  • Hyper-V 企业许可 - 包含的 CAL 是否应用于每个 VM 或每个 VM?[复制]

  • Hyper-V 和 Drobo Pro

  • 小型企业的服务器虚拟化/RAID 配置

  • 交换服务器 2003 在 hyper-v 上

  • 在同一台机器上将域控制器作为 1 个 VM 和一个 RODC 作为另一个 VM 运行,它会工作吗?

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve