无法在Mac OS主机的QEMU上安装ubuntu

时间:2020-04-03 12:14:18

标签: macos ubuntu virtual-machine qemu

我是QEMU虚拟机的新手。

我现在按照以下教程在Mac OS Catalina主机的QEMU虚拟机上安装ubuntu16.04: https://graspingtech.com/ubuntu-desktop-18.04-virtual-machine-macos-qemu/

但是,在我命令使用ubuntu ISO启动QEMU之后,我没有进入ubuntu安装程序。

我命令:

qemu-system-x86_64 \
  -m 2048 \
  -vga virtio \
  -show-cursor \
  -usb \
  -device usb-tablet \
  -enable-kvm \
  -cdrom  /Users/my_path/QEMU/ubuntu-16.04.6-desktop-amd64.iso \
  -drive file=/Users/mt_path/QEMU/ubuntu-16.04.6-live-server-amd64.qcow2,if=virtio \
  -accel hvf \
  -cpu host

,但是我在QEMU上获得了No bootable device

No bootalbe device

有人知道如何解决吗?

2 个答案:

答案 0 :(得分:0)

在启动虚拟机时也应指定启动驱动器

在我的计算机上运行qemu-system-x86_64 --help会产生有关引导顺序的信息:

-boot [order=drives][,once=drives][,menu=on|off]
      [,splash=sp_name][,splash-time=sp_time][,reboot-timeout=rb_time][,strict=on|off]
                'drives': floppy (a), hard disk (c), CD-ROM (d), network (n)
                'sp_name': the file's name that would be passed to bios as logo picture, if menu=on
                'sp_time': the period that splash picture last if menu=on, unit is ms
                'rb_timeout': the timeout before guest reboot when boot failed, unit is ms

对于您来说,-boot c应该是hard disk (c)

答案 1 :(得分:0)

问题已解决。 那是因为我对.qcow2文件做了一些虚拟。 我试图重新制作.qcow2并重新下载.iso,它可以工作。

相关问题