Difference between revisions of "XenServer/Install/XcpXapiOnPrecise"
m (Text replace - "__NOTOC__" to "") |
|||
(6 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
− | + | ||
<!-- ## page was renamed from [[XenServer]]/Install/XenXcpXapiOnPrecise --> | <!-- ## page was renamed from [[XenServer]]/Install/XenXcpXapiOnPrecise --> | ||
− | + | __TOC__ | |
= Xen (XCP-XAPI) on Precise (Ubuntu 12.04) = | = Xen (XCP-XAPI) on Precise (Ubuntu 12.04) = | ||
This page should contain a sequence of operations to install an XCP-XAPI hypervisor on top of Precise, to get started with [[OpenStack]]. | This page should contain a sequence of operations to install an XCP-XAPI hypervisor on top of Precise, to get started with [[OpenStack]]. | ||
Line 14: | Line 14: | ||
== XCP-XAPI with bridge networking == | == XCP-XAPI with bridge networking == | ||
− | All the following commands must be executed as '''root''' | + | All the following commands must be executed as '''root'''. At the moment you need to perform some post install fixes in case of bridge networking. |
+ | === Instal Packages === | ||
Update your system | Update your system | ||
Line 23: | Line 24: | ||
</nowiki></pre> | </nowiki></pre> | ||
− | Select your desired network configuration, so that it won't | + | Select your desired network configuration, so that it won't be asked. At the moment the installer seems to ignore this bit, but it is useful to avoid popping up the dialog. |
<pre><nowiki> | <pre><nowiki> | ||
Line 29: | Line 30: | ||
</nowiki></pre> | </nowiki></pre> | ||
− | + | Setup a redirection, to make sure, xen will be booted first. | |
<pre><nowiki> | <pre><nowiki> | ||
− | + | dpkg-divert --add --rename --divert /etc/grub.d/09_linux_xen /etc/grub.d/20_linux_xen | |
</nowiki></pre> | </nowiki></pre> | ||
+ | Install XCP-XAPI | ||
+ | |||
+ | <pre><nowiki> | ||
+ | apt-get install -y xcp-xapi | ||
+ | </nowiki></pre> | ||
+ | |||
+ | === Post Install Fixes === | ||
Select xapi as your default toolstack | Select xapi as your default toolstack | ||
Line 47: | Line 55: | ||
</nowiki></pre> | </nowiki></pre> | ||
− | + | Install `qemu-common`, so that the keymap files will be installed to the correct location. | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
<pre><nowiki> | <pre><nowiki> | ||
− | + | apt-get install -y qemu-common | |
</nowiki></pre> | </nowiki></pre> | ||
− | Configure your network | + | Configure your network temporarily, so that you still have access to the server after reboot. After reboot, we'll remove this configuration, and use xcp-xapi to manage the network. |
<pre><nowiki> | <pre><nowiki> | ||
Line 86: | Line 87: | ||
<pre><nowiki> | <pre><nowiki> | ||
update-rc.d openvswitch-switch disable | update-rc.d openvswitch-switch disable | ||
+ | </nowiki></pre> | ||
+ | |||
+ | |||
+ | <pre><nowiki>#!wiki caution | ||
+ | There is a known incompatibility between linux-image-3.2.0-36-generic and xen-hypervisor-4.1-amd64 which resulted in bug https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1111470 - If you are using this kernel package, upgrade to the Quantal kernel - e.g. http://packages.qa.ubuntu.com/qatracker/milestones/223/builds/25321/downloads | ||
</nowiki></pre> | </nowiki></pre> | ||
Line 92: | Line 98: | ||
<pre><nowiki> | <pre><nowiki> | ||
reboot | reboot | ||
+ | </nowiki></pre> | ||
+ | |||
+ | Re-configure your network interface (eth0, dhcp) | ||
+ | |||
+ | <pre><nowiki> | ||
+ | xe pif-reconfigure-ip uuid=$(xe pif-list device=eth0 --minimal) mode=dhcp | ||
+ | echo 'auto lo' > /etc/network/interfaces | ||
+ | echo 'iface lo inet loopback' >> /etc/network/interfaces | ||
</nowiki></pre> | </nowiki></pre> | ||
Line 117: | Line 131: | ||
<pre><nowiki> | <pre><nowiki> | ||
POOL=$(xe pool-list --minimal) | POOL=$(xe pool-list --minimal) | ||
− | + | xe pool-param-set uuid=$POOL default-SR=$SR | |
</nowiki></pre> | </nowiki></pre> |
Latest revision as of 23:30, 17 February 2013
Contents
Xen (XCP-XAPI) on Precise (Ubuntu 12.04)
This page should contain a sequence of operations to install an XCP-XAPI hypervisor on top of Precise, to get started with OpenStack.
Setup base system
Install a minimal system (Press F4 during the CD install)
Select only an OpenSSH Server when asked
Other requirements:
- An empty partition - in my case `/dev/sda7` (should not contain LVM pv s)
- `eth0` connected to a network with a DHCP server
XCP-XAPI with bridge networking
All the following commands must be executed as root. At the moment you need to perform some post install fixes in case of bridge networking.
Instal Packages
Update your system
apt-get update apt-get -y dist-upgrade
Select your desired network configuration, so that it won't be asked. At the moment the installer seems to ignore this bit, but it is useful to avoid popping up the dialog.
echo "xcp-networkd xcp-xapi/networking_type select bridge" | debconf-set-selections
Setup a redirection, to make sure, xen will be booted first.
dpkg-divert --add --rename --divert /etc/grub.d/09_linux_xen /etc/grub.d/20_linux_xen
Install XCP-XAPI
apt-get install -y xcp-xapi
Post Install Fixes
Select xapi as your default toolstack
echo 'TOOLSTACK=xapi' > /etc/default/xen
Change your network configuration to bridge
echo 'bridge' > /etc/xcp/network.conf
Install `qemu-common`, so that the keymap files will be installed to the correct location.
apt-get install -y qemu-common
Configure your network temporarily, so that you still have access to the server after reboot. After reboot, we'll remove this configuration, and use xcp-xapi to manage the network.
echo 'auto lo' > /etc/network/interfaces echo 'iface lo inet loopback' >> /etc/network/interfaces echo 'auto xenbr0' >> /etc/network/interfaces echo 'iface xenbr0 inet dhcp' >> /etc/network/interfaces echo ' bridge_ports eth0' >> /etc/network/interfaces
Hack xend init script
sed -i "s/\\\$XEND status && return 1/return 0/" /etc/init.d/xend
Disable services
update-rc.d xendomains disable
Disable openvswitch
update-rc.d openvswitch-switch disable
#!wiki caution There is a known incompatibility between linux-image-3.2.0-36-generic and xen-hypervisor-4.1-amd64 which resulted in bug https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1111470 - If you are using this kernel package, upgrade to the Quantal kernel - e.g. http://packages.qa.ubuntu.com/qatracker/milestones/223/builds/25321/downloads
Reboot your server
reboot
Re-configure your network interface (eth0, dhcp)
xe pif-reconfigure-ip uuid=$(xe pif-list device=eth0 --minimal) mode=dhcp echo 'auto lo' > /etc/network/interfaces echo 'iface lo inet loopback' >> /etc/network/interfaces
SR Configuration
Save your desired SR device to a shell variable
SRDEVICE=/dev/sda7
Create an SR from your SRDEVICE
. /etc/xcp/inventory SR=$(xe sr-create \ host-uuid=$INSTALLATION_UUID \ type=ext \ name-label='Local storage' \ device-config:device=$SRDEVICE)
Set the newly created SR to be the pool default
POOL=$(xe pool-list --minimal) xe pool-param-set uuid=$POOL default-SR=$SR