|
|
Line 1: |
Line 1: |
| {{Fancynote | This article is still in development}} | | {{Person |
| | | |Full name=Richard Yao |
| Funtoo is [[KVM]]/[[wikipedia:Qemu | Qemu]] ready.
| | |Email=ryao@gentoo.org |
| | | |Nick=ryao |
| In order for it to work, you need to make sure that you've enabled Virtio support on the kernel.
| | |Geoloc=40.9955012, -74.3439009 |
| | | |Location name=Stony Brook, New York, United States of America |
| == Pre-Requisites ==
| | |Roles= |
| * You are following the [[Funtoo_Linux_Installation | Funtoo Linux Installation]] Guide.
| | |Maintains= |
| * You figured out how to use [[Genkernel]] by reading the [[Genkernel_Quick_Start_Tutorial | Genkernel Quick Start Tutorial]].
| | |Blogs={{Blog |
| * You are using the most current vanilla-sources
| | |Name=Richard Yao's Blog |
| | | |URL=http://blogs.gentoo.org/ryao |
| == Procedure ==
| | }} |
| Carry on until you reach the [[Funtoo_Linux_Installation#Configuring_and_installing_the_Linux_kernel | Configuring and installing the linux kernel]] section.
| | }} |
| | |
| === Step 1: Install Genkernel === | |
| emerge sys-kernel/genkernel
| |
| | |
| === Step 2: Install the vanilla sources ===
| |
| emerge sys-kernel/vanilla-sources
| |
| | |
| === Step 3: Start configuring and building the kernel ===
| |
| genkernel --menuconfig all
| |
| | |
| === Step 4: Search and enable the essential Virtio drivers ===
| |
| To be able to search for all Virtio options, just type ''/'' on the ''TUI'' (Terminal User Interface) and, then, type 'virtio'. Please, consult: [http://www.linux-kvm.org/page/Virtio KVM's website] in order to get a list of options available in the Kernel's config.
| |
| | |
| {{Note | The console will let you know what is available. Pay special attention to the location section.}}
| |
| | |
| === Step 5: Continue with [[Funtoo_Linux_Installation#Installing_a_Bootloader | Funtoo Linux Installation]] Guide === | |
| | |
| == Testing ==
| |
| === Boot the Guest ===
| |
| You should be able to boot the guest without problems. If you're using virt-manager, then just hit "play" on the Guest. If you're a commandline dude, please, issue the following command:
| |
| | |
| qemu-kvm -boot c -drive file=/var/lib/libvirt/images/funtoo.img,if=virtio -m 512
| |
| | |
| == Troubleshooting ==
| |
| | |
| === Determining root device fails === | |
| For some reason, on kernel 3.4.5, it fails to load the modules automatically. You can workaround it by adding:
| |
| | |
| doload=virtio_pci,virtio_blk
| |
| | |
| to the kernel line; at the grub prompt; at boot time. It should look something like this:
| |
| | |
| <pre>
| |
| set timeout=3
| |
| set default=0
| |
| | |
| menuentry "Funtoo Linux genkernel - kernel-genkernel-x86_64-3.4.5" {
| |
| insmod part_gpt
| |
| insmod ext2
| |
| set root=(hd0,2)
| |
| search --no-floppy --fs-uuid --set 22b809f0-86be-422a-8bdd-6f4362da83ed
| |
| linux /kernel-genkernel-x86_64-3.4.5 real_root=/dev/vda4 doload=virtio_pci,virtio_blk
| |
| initrd /initramfs-genkernel-x86_64-3.4.5
| |
| set gfxpayload=keep
| |
| }
| |
| </pre>
| |
| | |
| Once you boot, a permanent workaround should look like this:
| |
| <pre>
| |
| mount /dev/vda2 /boot
| |
| | |
| cat /boot/grub/grub.cfg
| |
| set timeout=3
| |
| set default=0
| |
| | |
| menuentry "Funtoo Linux genkernel - kernel-genkernel-x86_64-3.4.5" {
| |
| insmod part_gpt
| |
| insmod ext2
| |
| insmod virtio_pci
| |
| insmod virtio_blk
| |
| insmod virtio_net
| |
| set root=(hd0,2)
| |
| search --no-floppy --fs-uuid --set 22b809f0-86be-422a-8bdd-6f4362da83ed
| |
| linux /kernel-genkernel-x86_64-3.4.5 real_root=/dev/vda4 doload=virtio_pci,virtio_blk
| |
| initrd /initramfs-genkernel-x86_64-3.4.5
| |
| set gfxpayload=keep
| |
| } | |
| </pre>
| |
| | |
| == Reference ==
| |
| * [[wikipedia: KVM]]
| |
| * [[wikipedia: Qemu]]
| |
| * http://www.linux-kvm.org/page/Virtio
| |