【问题标题】:How to create/add dvd drive of iso in Xen Server virtual machine using powershell如何使用 powershell 在 Xen Server 虚拟机中创建/添加 iso 的 dvd 驱动器
【发布时间】:2018-07-24 00:22:59
【问题描述】:

我正在尝试创建一个 powershell 脚本,该脚本将在 Xen Server 中创建所需配置的 VM 并启动 VM。在其中一个步骤中,我必须创建/添加 ISO 的 DVD 驱动器。 (网络驱动器)。我尝试过,但找不到这样做的 powershell 等效命令。虽然我可以将存储添加为磁盘,但无法创建 VM 将启动并加载 ISO 的 DVD。

【问题讨论】:

    标签: windows powershell virtual-machine citrix xen


    【解决方案1】:

    我找到了类似的解决方案HERE

    这是有帮助的代码:

    Get-XenVM -Name vmName | select -ExpandProperty VBDs | Get-XenVBD | where {$_.type -eq "CD"} | Invoke-XenVBD -XenAction Insert -VDI (Get-XenVDI -Name "$BootISOName" | select -ExpandProperty opaque_ref)
    

    【讨论】:

    • 我试过这个。我没有看到控制台中创建的 DVD 设备。
    猜你喜欢
    • 1970-01-01
    • 2021-11-19
    • 1970-01-01
    • 1970-01-01
    • 2010-09-08
    • 2010-11-08
    • 1970-01-01
    • 1970-01-01
    • 2011-07-12
    相关资源
    最近更新 更多