XEN on OpenSolaris (1) - 安装并配置Solaris Dom0

本文提供详细的Solaris Dom0安装步骤,包括Solaris Express的安装、必需软件包的添加、BFU归档文件的部署、Xen兼容性的配置调整及Xen服务验证等内容。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Installation instructions for Solaris Dom0:

NOTE: These instructions are for setting up Solaris on Xen from a fresh Solaris Install. Upgrading from a previous work-in-progress snapshot is not generally supported. However, we do have some notes for those who will try anyway ;-).

  1. Install Solaris Express build 44.
  2. Uncompress and add the packages
# cd /path/to/downloads/
   
# bunzip2 -d SUNWPython64.pkg.bz2
   
# pkgadd -d SUNWPython64.pkg
   
# bunzip2 -d SUNWPython64-devel.pkg.bz2
   
# pkgadd -d SUNWPython64-devel.pkg
   
# bunzip2 -d SUNWxenh.pkg.bz2
   
# pkgadd -d SUNWxenh.pkg
   
# bunzip2 -d SUNWxenr.pkg.bz2
   
# pkgadd -d SUNWxenr.pkg
   
# bunzip2 -d SUNWxenu.pkg.bz2
   
# pkgadd -d SUNWxenu.pkg
   
# bunzip2 -d SUNWonbld.pkg.bz2
   
# pkgadd -d SUNWonbld.pkg
  

Remember, these packages must be the version we provide, not the generic OpenSolaris packages, as we have made modifications for Xen support.

3. Install the BFU archives of Solaris modified for Xen

If you built Solaris modified for Xen from source, your BFU archives can be found in the archives/i386/nightly directory of your OpenSolaris source tree.

If you did not build your own archives, you downloaded them from the download page for this community.

When deploying on a fresh Solaris install using downloaded archives, it will probably look something like:

# mkdir /archives
   
# cd /archives
   
# bunzip2 -d -c /path/to/downloads/osox-bfu-2006-08-16.tar.bz2 | tar xf -
   
# FASTFS=/opt/onbld/bin/`uname -p`/fastfs ; export FASTFS
   
# BFULD=/opt/onbld/bin/`uname -p`/bfuld ; export BFULD
   
# ACR=/opt/onbld/bin/acr ; export ACR
   
# GZIPBIN=/usr/bin/gzip ; export GZIPBIN
   
# DIRECTBOOT_BIN_DIR=/archives/osox-bfu-2006-08-16 ; export DIRECTBOOT_BIN_DIR
   
# /opt/onbld/bin/bfu /archives/osox-bfu-2006-08-16
   
# /tmp/bfubin/acr
  

Be aware that the full pathname "/archives" is required for the correct functioning of BFU.

If you're using Live Upgrade, you may need to modify /boot/grub/menu.lst by hand. Make sure you've verified the changes are correct. The new entries to boot the non-Xen kernels should look something like this:

title Solaris 
   
    
     Nevada
    
    snv_44 X86 64-bit
   
kernel /platform/i86pc/kernel/amd64/unix
   
module /platform/i86pc/boot_archive
  

or for 32-bit boot:

title Solaris Nevada snv_44 X86 32-bit
   
kernel /platform/i86pc/kernel/unix
   
module /platform/i86pc/boot_archive
  

For more detailed instructions on installing from a BFU archive, see the Developers' Reference.

4. Disable all IP checksum offload, as it doesn't interact well with the ethernet bridge and Xen.

# echo "set ip:dohwcksum = 0" >>/etc/system
   
# bootadm update-archive
  

5. Prepare for reboot into either 32 or 64 bit Xen

BFU will update the default entries in /boot/grub/menu.lst to boot Solaris on metal, but as you want to boot Xen, you'll need to add two more entries as follows:

title Solaris on Xen 64-bit
   
kernel /boot/amd64/xen.gz dom0_mem=524288 console=com1 com1=9600,8n1 
   
module /platform/i86xen/kernel/amd64/unix /platform/i86xen/kernel/amd64/unix -k
   
module /platform/i86pc/boot_archive
  

and

title Solaris on Xen 32-bit
   
kernel /boot/xen.gz dom0_mem=524288 console=com1 com1=9600,8n1
   
module /platform/i86xen/kernel/unix /platform/i86xen/kernel/unix -k
   
module /platform/i86pc/boot_archive
  

If you want, also change the "default" line to point to these. When you reboot, select a Xen entry from the grub menu. Note that the above examples assume you are using a serial port for the system console.

Link to more information on menu.lst changes

At this point the system is ready for rebooting into Xen with a Solaris dom0.

6. Set up /etc/xen/xend-config.sxp

If you have more than one physical NIC configured, you may need to configure the network-bridge property in this file; see the example given in the file. The NIC must support the latest version of GLD. These include bge, e1000g, xge, nge, and rge.

If you want to allow migration to this machine from another dom0, you must change the xend-relocation-hosts-allow parameter in this file to allow that host.

7. Verify Xen devices are present

In some cases, the xen devices may not be present. For example, if you booted a i86pc kernel after BFU'ing the i86xen kernel, the reconfigure boot following the BFU would not create the xen devices (since the drivers do not exist in i86pc). Check that the following device links are present.

# ls -l /dev/xen
   
total 6
   
lrwxrwxrwx   1 root     root          36 Jun 28 16:05 evtchn -> ../../devices/xendev/evtchn@0:evtchn
   
lrwxrwxrwx   1 root     root          38 Jun 28 16:05 privcmd -> ../../devices/xendev/privcmd@0:privcmd
   
lrwxrwxrwx   1 root     root          36 Jun 28 16:05 xenbus -> ../../devices/xendev/xenbus@0:xenbus
  

If they are not, you can fix this by doing the following (make sure you boot a i86xen kernel immediately after the reboot):

# touch /reconfigure
   
# reboot
  

8. Verify the Xen Services are started

# svcs -a | grep xen
   
online         10:03:06 svc:/system/xen/store:default
   
online         10:03:16 svc:/system/xen/xend:default
   
online         10:03:16 svc:/system/xen/console:default
  

If they are not, first verify you booted a i86xen kernel (uname -i), and if you did, enable them by doing the following:

# svcadm enable xen/store
   
# svcadm enable xen/xend
   
# svcadm enable xen/console
  
 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值