【问题标题】:How do I pass the real/physical NVMe to a qemu machine? (Host MacOS, guest Windows)如何将真实/物理 NVMe 传递给 qemu 机器? (主机 MacOS,来宾 Windows)
【发布时间】:2020-02-07 11:41:21
【问题描述】:

我只想通过 Qemu 启动我的 Windows 安装(已经安装)。我能够通过 VMware Fusion 做到这一点。但它出了问题,几天后试图解决它。我放弃了,想到了Qemu。

我有这行

qemu-system-x86_64 -m 9072 -cpu Penryn,+invtsc,vmware-cpuid-freq=on,$MY_OPTIONS\
      -machine q35 \
      -smp 4,cores=2 \
      -usb -device usb-kbd -device usb-mouse \
      -smbios type=2 \
      -device ich9-ahci,id=sata \
      -drive id=WIN,format=raw,if=none,file="/dev/disk2s4",index=0,media=disk \
      -device ide-hd,bus=sata.4,drive=WIN \
      -monitor stdio \
      -vga vmware

这是“草稿”。我正在尝试。但我的问题是我想将我的 SSD NVMe 传递给这台机器。我在互联网上找不到任何对 MacOS 有用的东西,搜索了几个小时。这些线是我发现的。即使在 Qemu 文档中我也找不到任何东西。

我永远得到“从硬盘启动...”...

【问题讨论】:

    标签: macos qemu


    【解决方案1】:

    来自https://www.qemu.org/docs/master/system/qemu-block-drivers.html
    https://www.qemu.org/docs/master/system/images.html#nvme-disk-images

    应该是:

    qemu-system-x86_64 -drive file=nvme://0000:06:00.0/2

    dmesg | grep nvme 你在哪里看到 [1] 并且你想要 p2

    [1]

    nvme nvme0: pci function 0000:06:00.0
    nvme0n1: p1 p2 p3 p4
    

    但是对我来说还是不行……

    qemu-system-x86_64: -drive file=nvme://0000:06:00.0/0002: Failed to find iommu group sysfs path: No such file or directory
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2021-09-14
      • 1970-01-01
      • 2021-04-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2019-04-29
      • 2017-04-23
      相关资源
      最近更新 更多