Hello everyone,
I'm David from Toulouse, France and this is my first question on this forum, it's already two years that I'm playing with linux, and almost twenty more others that I use unix at work.
My question may seem easy or stupid to some of you, but I found discussions relative to the problem I encounter or close to it.
I want to run a linux qemu-virtual machine within a text console. (to be able to see it working across an ssh text link)
So, first I create a virtual disk :
$ /usr/bin/qemu-img create qemu-dsk.img 2G
Then I mount the iso CD image that I want to run : (one that I know is working correctly)
# mount -o loop /home/david/SUSBlive/debian-live-505-i386-lxde-desktop.iso /media/cdrom1
And last I issue the qemu command about which is my question :
$ qemu -kernel /media/cdrom1/live/vmlinuz -initrd /media/cdrom1/live/initrd.img ./qemu-dsk.img -append "root=/ console=ttyS0" -nographic -m 324
(here is how it splits
qemu -kernel /media/cdrom1/live/vmlinuz # this is the kernel located within the iso image mounted on /media/cdrom1
-initrd /media/cdrom1/live/initrd.img # this is the initrd located within the iso image mounted on /media/cdrom1
-hda ./qemu-dsk.img # this is the virtual HD created by "qemu-img create" as shown above
-append "root=/ console=ttyS0" #-----THIS IS WHAT IS PROBABLY WRONG-----
-nographic -m 324 # this is to run in a console on my poor machine
And here it goes :
[ 0.000000] Initializing cgroup subsys cpuset
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Linux version 2.6.26-2-686 (Debian 2.6.26-24) (dannf@debian.org)
[.../...] (something like two hudred lines)
[ 43.208166] hda: unknown partition table
[ 43.453892] hdc: ATAPI 4X CD-ROM drive, 512kB Cache
[ 43.455613] Uniform CD-ROM driver Revision: 3.20
done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Waiting for root file system ...
(and I would be still waiting if I did not kill qemu)
-If ever the '-append "root=/ console=ttyS0"' part of my command was :
-append "root=/root console=ttyS0"
Then it finishes like :
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Running /scripts/local-premount ... done.
mount: mounting / on /root failed: No such device
Begin: Running /scripts/local-bottom ... done.
done.
Begin: Running /scripts/init-bottom ... mount: mounting /dev on /root/dev failed: No such file or directory
done.
mount: mounting /sys on /root/sys failed: No such file or directory
mount: mounting /proc on /root/proc failed: No such file or directory
Target filesystem doesn't have /sbin/init.
No init found. Try passing init= bootarg.
(and then it drops to a shell within initramfs, and "exit" gives
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(1,0)
-I found other examples that I do not completely understand either :
-append "root=/dev/hda console=ttyS0"
-append root="/dev/nfs nfsroot=<host-ip>:/mnt/ARM_FS rw ip=dhcp"
-append root="0800"
-append "root=/dev/ram init=/linuxrc console=ttyS0"
-Well, my questions and my tries may show that I do not yet understand everything in that domain, but please help me making work my qemu by it finding its root file system.
At least, please give me some links where I could learn how to understand that, which is still messy for me.
Thank'you,
David
(Long post, sorry, but I'm completely lost)