Xen: Install xen in Ubuntu

Source: Internet
Author: User

-Install and configure xen in Ubuntu


Lab environment:

Operating System: Ubuntu 12.04.4 lts x86_64

Kernel version: 3.2.0-23-generic



Install bridge-utils:

apt-get  install bridge-utils

Configure the bridge network (use static IP address, where the real IP address is replaced by x. x ):

# The loopback network interfaceauto loiface lo inet loopback# The primary network interfaceauto eth0iface eth0 inet static        address X.X.X.X        netmask 255.255.255.128        gateway X.X.X.Xauto eth0:0iface eth0:0 inet static        address X.X.X.X        netmask 255.255.255.128auto eth1iface eth1 inet manualauto xenbr1iface xenbr1 inet static    address 10.20.20.20netmask 255.255.255.0bridge_ports eth1bridge_stp off



Use apt-get to download and install:

 apt-getinstall xen-hypervisor-4.1-amd64 xen-utils-4.1 xenwatch xen-toolsxen-utils-common xenstore-utils

Modify the startup Item after installation:

sed -i‘s/GRUB_DEFAULT=.*\+/GRUB_DEFAULT="Xen 4.1-amd64"/‘ /etc/default/grubupdate-grub2

Modify xend configuration (/etc/xen/xend-config.sxp)

Use the bridging method based on my network configuration. Modify the following:

(network-script ‘network-bridge netdev=eth1‘)

To ensure smooth network connection, you need to configure the following:

Add NAT:

/sbin/iptables-t nat -A POSTROUTINGi -s 10.0.0.0/8 -o eth0 -j MASQUERADE

Enable IP forwarding:

vim/etc/sysctl.confnet.ipv4.ip_forward= 1sysctl -p

Now, the basic configuration of xen is OK.

This article from the "keep walking" blog, please be sure to keep this source http://yao1990.blog.51cto.com/2913182/1559332

Xen: Install xen in Ubuntu

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.