[SOLVED] Building SlackBuilds KVM doesn't work, 2.6.35.4 kernel
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Note that the virtio interface requires a customized kernel with the virtio-blk module, you'd have to replace it for scsi or ide if you don't want to customize the installer.
I don't recompile the host kernel to use virtio drives with the guests. I use the generic kernel on the host and guests. I get virtio working using a roundabout process that installs the initrd on the guest with the virtio_pci and virtio_blk drivers. Roundabout is a kind description, it's a pain in the butt and I've screwed it up more than a few times.
I don't recompile the host kernel to use virtio drives with the guests. I use the generic kernel on the host and guests. I get virtio working using a roundabout process that installs the initrd on the guest with the virtio_pci and virtio_blk drivers. Roundabout is a kind description, it's a pain in the butt and I've screwed it up more than a few times.
I was talking about the guest, not the host. The kernel used by 13.1 and -current installer needs to be recompiled because virtio-blk isn't enabled by default for whatever reason.
tbh i prefer the roudabout process over customizing the installer kernel, after all i don't deal with installations very often because I just make a snapshot after the installation per se and if i need a new box i just copy the disk image, revert to the "post-inst" snapshot and carry on.
Hmm... If I start qemu-system-x86_64 without a running kvm-amd daemon it prints
Quote:
Could not initialize KVM, will disable KVM support
But even if kvm-amd is running qemu is still veeeeeeeery slow. Probably my mainboard doesn't support it as mentioned before? I looked in the BIOS configuration but I couldn't find anything about virtualization.
I have an Asus M4N75TD mainboard.
The kernel used by 13.1 and -current installer needs to be recompiled because virtio-blk isn't enabled by default for whatever reason.
What I'm saying is that you never need to recompile a host or guest kernel to get virtio_blk working. In a nutshell...
Phase 1:
standard install of guest generic kernel using /dev/sd# drives, change fstab from /dev/sda# to /dev/vda#, do mkinitrd using /dev/sda# drives and add the virtio_pci and virtio_blk drivers, run lilo,
Phase 2:
reboot but add boot=/dev/vda root/dev/vda# at the lilo prompt (use 5 second delay option), make many changes to lilo.conf (I'll list if interested), redo mkinitrd using /dev/vda# drives and add again virto_pci and virtio_blk drivers, run lilo
You are good to go unless you screw it up like I do regularly!
Hmm... If I start qemu-system-x86_64 without a running kvm-amd daemon
kvm-amd is a module, not a daemon. You definitely need to load kvm-amd before launching qemu-system-x86_64 otherwise it falls back to super slow qemu only mode.
What I'm saying is that you never need to recompile a host or guest kernel to get virtio_blk working. In a nutshell...
Sure you can do a lot of stuff to work around the kernel compilation - i do it myself, pretty much like you described - but my point was that using a stock kernel won't work as in "just install and use it, like an ide or scsi disk".
kvm-amd is a module, not a daemon. You definitely need to load kvm-amd before launching qemu-system-x86_64 otherwise it falls back to super slow qemu only mode.
Of course, you're right. I was tired while I was writing this post. I meant module.
Have you added your user to the 'kvm' group? You need to be a member of the said group to access /dev/kvm and thus use the kvm capabilities.
The name 'kvm' may be different in your setup, it is the group you listed in $KVMGROUP when you ran the slackbuild. If you have not created the 'kvm' group nor set $KVMGROUP to anything different, create it and add your user to it:
Code:
groupadd -g 221 kvm
gpasswd -a yourusername kvm
# log out and log in now
The GID 221 is suggested by the UID/GID list maintained by slackbuilds.org [1].
this is a one time creation. you should use udev to create the device on each reboot
ala
KERNEL=="kvm", GROUP="kvm", MODE="0660"
this should be in /lib/udev/rules.d
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.