[[PageOutline]]
{{{
#!html
Xen 4.0 Installation (Debian Lenny)
}}}
----
= 【安裝基本套件】 =
{{{
$ sudo aptitude install bcc bin86 gawk bridge-utils iproute libcurl3 \
libcurl4-openssl-dev bzip2 module-init-tools transfig tgif texinfo \
texlive-latex-base texlive-latex-recommended texlive-fonts-extra \
texlive-fonts-recommended pciutils-dev mercurial build-essential \
make gcc libc6-dev zlib1g-dev python python-dev python-twisted \
libncurses5-dev patch libvncserver-dev libsdl-dev libjpeg62-dev \
iasl libbz2-dev e2fslibs-dev git-core uuid-dev
\\若是 64bit 系統還需安裝
$ sudo aptitude install gcc-multilib
}}}
----
= 【安裝 Xen 4.0】 =
== [法一:從 Debian 的套件庫安裝 Xen] ==
因目前 Debian 官方維護的 Xen 套件版本較舊(Xen 3.2),Kernel 版本也較舊(2.6.26),若想使用最新版的 Xen 4.0 和較新的 Kernel 2.6.31 必須從 source 安裝
{{{
$ sudo aptitude install xen-linux-system-2.6.26-2-xen-amd64 xen-hypervisor-3.2-1-amd64 xen-tools
}}}
== [法二:從 Source 安裝 Xen] ==
{{{
$ cd /usr/src
$ sudo wget http://bits.xensource.com/oss-xen/release/4.0.0/xen-4.0.0.tar.gz
$ sudo tar zxvf xen-4.0.0.tar.gz
$ cd xen-4.0.0/
$ make -j 4 world
$ make insatll
$ sudo mkinitramfs -o /boot/initrd.img-2.6.31.13 2.6.31.13
$ sudo update-grub
}}}
----
= 【問題】 =
* ERROR Internal error: Could not obtain handle on privileged command interface
{{{
#!sh
ERROR Internal error: Could not obtain handle on privileged command interface (2 = No such file or directory)
Traceback (most recent call last):
File "/usr/sbin/xend", line 36, in
from xen.xend.server import SrvDaemon
File "usr/lib/python2.5/site-packages/xen/xend/server/SrvDaemon.py", line 26, in
File "usr/lib/python2.5/site-packages/xen/xend/server/relocate.py", line 28, in
File "usr/lib/python2.5/site-packages/xen/xend/XendDomain.py", line 36, in
File "usr/lib/python2.5/site-packages/xen/xend/XendCheckpoint.py", line 20, in
File "usr/lib/python2.5/site-packages/xen/xend/image.py", line 46, in
xen.lowlevel.xc.Error: (1, 'Internal error', 'Could not obtain handle on privileged command interface (2 = No such file or directory)')
}}}
* 檢查一下 Xen 預設的 Kernel 並無將全部的 Intel 1G 系列的全部網路 build-in 或編成模組,解法可能得自行編譯 Kernel
----
= 【Reference】 =
* [http://wiki.xensource.com/xenwiki/Xen4.0 Xen4.0]
* [http://www.vpsee.com/2010/04/install-xen-on-debian-from-source/ 在 Debian 上源码安装 Xen]
* [http://bderzhavets.wordpress.com/2010/04/24/set-up-ubuntu-10-04-server-pv-domu-at-xen-4-0-dom0-pvops-2-6-32-10-kernel-dom0-on-top-of-ubuntu-10-04-server/ Set up Ubuntu 10.04 Server PV DomU at Xen 4.0 Dom0 (pvops 2.6.32.12 kernel) Dom0 on top of Ubuntu 10.04 Server]
* [http://bderzhavets.wordpress.com/2010/05/18/set-up-libvirt-0-7-7xen-4-0-on-top-fedora-13-rc2/ Set up Libvirt 0.7.7&Xen 4.0 Dom0 (2.6.32.13 pvops) on top of Fedora 13 RC2]