Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
QEMU - cannot start
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
fidel
Guru
Guru


Joined: 16 Jul 2004
Posts: 407
Location: CH

PostPosted: Fri Dec 04, 2015 9:56 pm    Post subject: QEMU - cannot start Reply with quote

I am still pretty new to virtualization in general and I would like to get familiar with QEMU, especially for emulating ARM machines. The reason behind this is mainly because I cannot chroot into such a system from within my Intel PC. Therefore I started using the contents of a pre-built linux for the Raspberry Pi, the raspbian. This system is installed on the SD card and runs fine on the Raspberry. So I tought I'll take the image and the kernel within in order to boot that with QEMU.

Therefore I have the kernel lying around as a file called kernel.img and the raw image (created with dd) of the corresponding SD card where the system is installed beside that. Then I issue the following command:
Code:
exec qemu-system-arm \
    -display gtk \
    -cpu arm1136 \
    -m 512 \
    -drive file=raspbian.img,if=virtio \
    -machine versatilepb \
    -netdev user,id=vmnic -device virtio-net,netdev=vmnic \
    -kernel kernel.img \
    -append  "dwc_otg.lpm_enable=0 console=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline rootwait"


No matter how I try (with or without the commandline, with different machine types, with re-compiled QEMU, re-compiled kernel so it contains about all of the virtio-xxx stuff), I always get the following message:
Code:
Guest has not initilialized the display (yet).


I guess that I do something completely wrong or I understood something wrong but even after hours of trying and searching I cannot find out what the real problem is. If the root device on the above command line cannot be mounted, I would expect the kernel to boot but stop at a certain point with a kernel panic, telling me that it cannot mount the root device. I am stuck and don't know how to proceed or where to search for the problem.

Do you by any chance have an idea?

Thanks for any hints!
Back to top
View user's profile Send private message
TigerJr
Guru
Guru


Joined: 19 Jun 2007
Posts: 519
Location: /dev/x0

PostPosted: Fri Dec 04, 2015 11:40 pm    Post subject: Reply with quote

i think the problem in -display gtk on versatilepb, there is not display driver on this platform!? Try to use -display none
_________________

Do not update portage without hotdog!

Xenogentooway?
Back to top
View user's profile Send private message
szatox
Veteran
Veteran


Joined: 27 Aug 2013
Posts: 1774

PostPosted: Sun Dec 06, 2015 5:09 pm    Post subject: Reply with quote

-drive file=raspbian.img,if=virtio
Does the kernel in your image support virtio? If it's been built for PI, I'd expect it to support the PI hardware and not support a lot of other things. You may need to play a bit with emulated hardware.
It's possible your kernel doesn't have modules for emulated GPU either.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum