Can't run a guest OS using QEMU in host Ubuntu [closed]

我只是一个虾纸丫 提交于 2021-01-29 17:07:16

问题


I'd like to run a Debian OS .iso image for ARM processors using QEMU in a host running Ubuntu (over an x86 architecture).

I executed the following line in a terminal:

aaron@aaron-HP-ZBook-14:~/Descargas$ qemu-system-arm -machine sabrelite -cdrom debian-10.7.0-arm64-netinst.iso -m 1024

But then, the following window appears.

https://i.stack.imgur.com/rB2PZ.png

I don't know why Debian OS is not initiating after executing the previous line. Instead, a QEMU command line interface appears waiting for the user to enter some commands.

Thanks in advance!

Aarón.


回答1:


Generally if you try to run qemu and only see the monitor there is likely something wrong with your image.

In this case you are attempting to boot "debian-netinst" which is the debian network-install image. If you want to emulate a debian-arm image I would recommend following this tutorial to get debian-arm up and running.

Here is a script that will automate the process in that tutorial

The script runs two QEMU commands. The first is a lengthy install process that should extract a debian initrd/kernel. The second QEMU command will boot the actual image. After the second command runs you should see the QEMU monitor open in a window. Use ctrl+alt+(1 or 2) to switch to the terminal/gui display




回答2:


You're trying to boot a 64-bit Arm CDROM image on a board which is 32-bit only, so this is never going to work.

More generally, most Arm boards will not simply boot from a CDROM image passed via the -cdrom option, because they don't have firmware/BIOS images which will run on QEMU and do the handling of booting from CD. Many boards don't even have an IDE or SCSI interface that a CDROM drive could be plugged into!

You should decide whether you want (a) to boot an image on the sabrelite board, (b) to boot a 32-bit arm image, but you don't care which board (c) to boot an arm64 kernel, and find a suitable tutorial or set of instructions accordingly. Lenna's link is good for option (b); there's a similar tutorial also for option (c). I don't know of any sabrelite specific instructions.

It's worth reading the QEMU documentation section on choosing an Arm board model -- unless you have a strong reason why you want to use a particular board model and a kernel that you know works on that board model, then 'virt' is usually a better choice. Even 'virt' won't boot directly off a cdrom, though, unless you also pass it a suitable UEFI bios image.



来源:https://stackoverflow.com/questions/65506562/cant-run-a-guest-os-using-qemu-in-host-ubuntu

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!