Guidelines for installing KQEMU kernel modules

Source: Internet
Author: User
Keywords installation kernel module http apt-get compiling
Tags .gz aliyun apt apt-get compiling free software gcc get

This is a guide to installing the Kqemu kernel module. Kqemu is not open source software, it is provided to http://www.aliyun.com/zixun/aggregation/29607.html "> free software qemu simulator used. It enables QEMU to virtual x86 systems on x86 (PC) systems.

Automatic installation

The script as well as the usage instructions are discussed in this link (http://ubuntuforums.org/showthread.php?t=187413). Includes dependencies in all installations.

wget http://andrew.v5n.net/ubuntu/install_qemu.sh
chmod +x/install_qemu.sh
sudo/install_qemu.sh

Compiling from source

In the terminal, enter the following command to download, compile and install Qemu 0.7.2 (including "No Free" KQEMU accelerator module)

CD ~
wget http://fabrice.bellard.free.fr/qemu/qemu-0.7.2.tar.gz
Tar zxf qemu-0.7.2.tar.gz
CD qemu-0.7.2
wget http://fabrice.bellard.free.fr/qemu/kqemu-0.7.2.tar.gz
Tar zxf kqemu-0.7.2.tar.gz
sudo apt install linux-headers-' uname-r '
sudo apt install gcc-3.4
sudo apt install Libsdl1.2-dev
sudo apt install checkinstall
sudo apt build-dep qemu
./configure--disable-gcc-check
Sed-i "S/gcc/gcc-3.4/g" Config-host.mak
Make
sudo checkinstall-y

Note that Kqemu needs to be recompiled each time the kernel is upgraded.

This page is written thanks to McPhail (who wrote about how to compile Qemu) and Turtlegirlman (test) help.

QEMU using the Kqemu module

The Kqemu module must be loaded like this:

sudo modprobe kqemu major=0

("major=0" needs to be added when creating/dev/kqemu device files)


You need to check to make sure that the module is loaded correctly:

Dmesg

Network configuration for the virtual environment, reference howtodebian-administration.org (HTTP://WWW.DEBIAN-ADMINISTRATION.ORG/ARTICLES/40), set forwarding and in/dev/net/ Tun set permissions. Note that the pre-built Ubuntu package installs a useful script to start the network interface. To do this, open a text editor and paste the text:

#!/bin/sh
Sudo-p "Password for $:"/sbin/ifconfig $172.20.0.1

Save Qemu to the desktop and open a terminal:

sudo cp ~/desktop/qemu/etc/qemu-ifup

When Qemu is turned on, there are now KQEMU modules and network support. To speed up the program, QEMU must start with Superuser because the/DEV/KQEMU device is used.

To avoid this, you can run before starting QEMU (this must be done every time the machine restarts):

sudo chmod a+rw/dev/kqemu

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.