Install Xen4.3.0 from the source code of Fedora20

Source: Internet
Author: User
Tags cloudstack
1. Environment Introduction Linux: Fedora20X86_64Xen: Xen4.3.02. download the image from the Fedora official website, boot the USB flash drive, and complete the installation. For more information, see Fedora20 system installation and configuration. 3.1 update yum # yum 1. Environment Introduction

Linux: Fedora 20 X86_64
Xen: Xen 4.3.0

2. Install Fedora

Download the image from the official website, boot the USB flash drive, and complete the installation.
For more information, see Fedora 20 system installation and configuration http://www.linuxidc.com/Linux/2015-04/116552.htm.

3. Install the required Toolkit

All commands are executed under the root permission.

3.1 update yum
# yum update
3.2 Development Kit
# yum groupinstall "Development Tools"# yum install hmaccalc ncurses-devel zlib-devel openssl-devel python-devel# yum install bridge-utils  libtool-ltdl xorg-x11-drv-evdev xorg-x11-drv-fbdev# yum install xorg-x11-drv-i810-devel xorg-x11-drv-via-devel xorg-x11-proto-devel# yum install xorg-x11-server-sdk xorg-x11-xtrans-devel libuuid-devel# yum install readline-devel gcc gcc-gfortran gcc-c++ flex pcre-devel# yum install blas-devel lapack-devel curl-devel bison gperf gnuplot# yum install texinfo-tex tetex-dvips

Note:
1. When executing the above command, the xorg-x11-drv-i810-devel and the xorg-x11-server-sdk did not, I did not go down alone, and found that the subsequent does not affect. These two packages will be required for later Compilation: (I installed them directly according to the tutorial. I don't know if it will affect the installation)
2. When Xen configuration is installed later, the system prompts: No as86. This is because gcc-c ++ is not installed at this step.

3.3 dev86

URL: http://rpmfind.net/linux/rpm2html/search.php? Query = dev86
Download: dev86-0.16.19-3.fc19.x86_64.rpm
Installation:

# rpm -ivh dev86-0.16.19-3.fc19.x86_64.rpm
3.4 Intel ACPI CA

Download to home: http://acpica.org/downloads
Download the source code, decompress it, and install:

# tar zxvf acpica-unix-20150204.tar.gz# cd acpica-unix-20150204# make# make install
4. Install Xen 4.3.0

Official Website: http://www.xenproject.org/downloads/xen-archives/supported-xen-43-series/xen-430.html

4.1 compile and install
# tar zxvf xen-4.3.0.tar.gz# cd xen-4.3.0# make clean# ./configure# make xen tools stubdom# make install-xen install-tools install-stubdom

Note:
My Xen is directly downloaded and installed on the official website. There is almost no problem when running these commands. Some people copied other people's ready-made Xen source code, and then encountered some problems during the installation process. Below I will post the problems that may occur:

1. One problem that appears more often is that the permissions are not enough, because the xen-4.3.0 is copied over and some permissions have changed. For example:
Error: make [3]: execvp:/home/chenchao/xen-4.3.0/tools/include/.../../tools/cross-install: insufficient Permissions
Solution: Enter the corresponding directory and modify the permissions of the corresponding file.

2. Compilation parameters are not recognized
Error: cc: Error: unrecognized command line option '-combine'
Solution: remove the compile parameter-combine from/home/chenchao/xen-4.3.0/tools/firmware/seabios-dir-remote/Makefile

3. Compilation Error
Error: Traceback (most recent call last ):
File "./tools/layoutrom. py", line 630, in
Main ()
File "./tools/layoutrom. py", line 607, in main
Info16 = parseObjDump (infile16, '16 ')
File "./tools/layoutrom. py", line 538, in parseObjDump
Relocsection = sectionmap [sectionname]
KeyError: '. text. asm. out/../src/smp. c.77'
Solution: With LC_ALL = C make compilation, the reason is: the language is set to UTF-8.

4. the header file library is missing
Error:/usr/include/gnu/stubs. h: 7: 27: fatal error: gnu/stubs-32.h: No such file or directory
# Include <gnu/stubs-32.h>
Solution: 64-bit systems compile 32bit programs. If any problem occurs, run the program on the terminal.
Sudo yum install glibc-devel.i686
Sudo yum install libgcc. i686

5. Compile the command not find
Error:/bin/sh: line 1: patch: command not found
Solution: sudo yum install patch. x86_64

6. The lib library is missing.
Error: glib-2.12 required to compile QEMU
Solution: sudo yum install glib2-devel.x86_64

7. This file does not exist
Error:/tmp/qemu-conf-5475-3115-17647.c: 1: 17: fatal error: SDL. h: No such file or directory
# Include <SDL. h>
Solution: sudo yum install SDL-devel.x86_64

8. ERROR: pixman not present. Your options:
(1) Prefered: Install the pixman devel package (any recent
Distro shoshould have packages as Xorg needs pixman too ).
(2) Fetch the pixman submodule, using:
Git submodule update-init pixman
Libxl_json.h: 18: 27: fatal error: yajl/yajl_gen.h: No such file or directory
# Include <yajl/yajl_gen.h>
Solution: sudo yum install yajl-devel.x86_64

./Configure error:

No package 'glib-2.0 'found
Solution:
Sudo yum install libgnomeui-devel

4.2 Add a startup Item
# /sbin/chkconfig --add xend# /sbin/chkconfig --add xencommons# /sbin/chkconfig --add xendomains# /sbin/chkconfig xend on# /sbin/chkconfig xendomains on# /sbin/chkconfig xencommons on
5. Update Grub

Update Grub and use Xen for guidance. The terminal executes the following command:

# grub2-mkconfig -o /boot/grub2/grub.cfg

Restart, use Xen to boot to Fedora, enter the root permission, and verify Xen:

# xm list

A bunch of errors:

Error:
Traceback (most recent call last ):
File "/usr/local/sbin/xm", line 5, in from xen. xm import main
ImportError: No module named xen. xm

Solution:
# The above error is still reported by sudo yum install xen-devel.x86_64
# The above error is still reported by sudo yum install xen-devel.i686
# Sudo yum install xen. x86_64

Here, an error is reported:
Error: Unable to connect to xend: No such file or directory. Is xend running?

Run:
# Xend start

Error:
Xc: error: cocould not obtain handle on privileged command interface (2 = No such file or directory): Internal error xend/image. py: Error connecting to hypervisor

Go to the xen root directory and execute:
# Make clean

Error:
Fatal build error: Xen requires at least gcc-4.1

Gcc installation: gcc is missing
# Yum install gcc

Execute again:
# Make clean
#./Configure
# Make xen tools stubdom

Error:
/Usr/include/gnu/stubs. h: 7: 27: fatal error: gnu/stubs-32.h: No such file or directory
# Include <gnu/stubs-32.h>

Solution: 64-bit systems compile 32bit programs. If any problem occurs, run the program on the terminal.
# Sudo yum install glibc-devel.i686
# Sudo yum install libgcc. i686

Execute again:

# make xen tools stubdom# make install-xen install-tools install-stubdom

Then, add the startup Item again. The xen and xendomains prompts you to enable the corresponding service and follow the prompts to enable it.
Update grub
Restart, use Xen to boot to Fedora, enter the root permission, and verify Xen:

# xm list

Succeeded:

Name                                        ID   Mem VCPUs      State   Time(s)Domain-0                                     0  3788     4     r-----    64.9

XenServer VM physical CPU usage policy http://www.linuxidc.com/Linux/2013-08/88698.htm

CloudStack compilation environment XenServer startup system virtual machine failed http://www.linuxidc.com/Linux/2013-08/88694.htm

Disable CloudStack from deleting XenServer original Virtual Machine http://www.linuxidc.com/Linux/2013-08/88693.htm

Linux VM boot http://www.linuxidc.com/Linux/2013-07/87699.htm from the drive in XenServer

Enable and configure the SNMP service http://www.linuxidc.com/Linux/2013-01/78487.htm for Citrix XenServer

Reset XenServer local disk LVM to EXT3 format http://www.linuxidc.com/Linux/2013-11/92282.htm

Install and configure Xen http://www.linuxidc.com/Linux/2010-04/25351.htm On Debian

For more information about Fedora, see Fedora topics page http://www.linuxidc.com/topicnews.aspx? Tid = 5

This article permanently updates the link address: Http://www.linuxidc.com/Linux/2015-04/116551.htm

Related Article

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.