PyGrub

from:https://wiki.debian.org/PyGrub

Using pyGRUB on Wheezy to boot a domU kernel

Using pyGRUB from xen-utils-4.0, each domU can boot with its own kernel instead of using the dom0 kernel, which makes life easier for updates and multi distribution Xeninstalls. You need to have first a working domU. The domU FileSystem needs to be ext[234].

On the dom0

  • You need to have the system partition as the first partition listed in your domU.cfg disklist.

Config snippet:

root        = ‘/dev/xvda2 ro‘
disk        = [
                  ‘phy:/dev/vg05/test2.openforce.com-disk,xvda2,w‘,
                  ‘phy:/dev/vg05/test2.openforce.com-swap,xvda1,w‘,
              ]

On the domU

  • Make sure /etc/fstab refers to the mount points /dev/xvda{1,2}
  • Install a standard linux-image-amd64 kernel (since Xen support is in mainline Linux since Linux 2.6.37)
mkdir /boot/grub
apt-get install linux-image-amd64

You don‘t need to install grub, you just need to create a simple grub config file which will be read by pygrub on the Dom0.

  • Create first /boot/grub/menu.lst based on the content of /boot/.
cat > /boot/grub/menu.lst << EOF

default         0
timeout         2

title           Debian GNU/Linux
root            (hd0,0)
kernel          /vmlinuz root=/dev/xvda2 ro
initrd          /initrd.img

title           Debian GNU/Linux (recovery mode)
root            (hd0,0)
kernel          /vmlinuz root=/dev/xvda2 ro single
initrd          /initrd.img

EOF

On the dom0

  • Check that grub was properly installed on the domU with
/usr/lib/xen-default/bin/pygrub /dev/vg02/my_domU-disk

which should great with the familiar grub menu, and then abort

  • Replace the kernel and ramdisk parameters in the domU config file with the following line.
bootloader      = ‘/usr/lib/xen-default/bin/pygrub‘

PyGrub

时间: 2024-07-29 19:12:54

PyGrub的相关文章

Xen虚拟化基础篇

一.xen的简介 Xen是一个开放源代码虚拟机监视器,由剑桥大学开发.它打算在单个计算机上运行多达128个有完全功能的操作系统. 在旧(无虚拟硬件)的处理器上执行Xen,操作系统必须进行显式地修改("移植")以在Xen上运行(但是提供对用户应用的兼容性).这使得Xen无需特殊硬件支持,就能达到高性能的虚拟化. Xen的架构如图: Xen虚拟机的组成: Xen Hypervisor: 虚拟化技术通过在现有平台(机器)上添加一层薄的虚拟机监控程序(Virtual Machine Monit

xen 4.3.0 创建Guest OS遇到的一些问题

1.physical machine: Centos 6.5 Xen Version: xen 4.3.0 Guest OS Version: Centos 6.5 2. After finishing the configuration file for Guest OS, we should use xl command to create a virtual machine as following: xl create xxx.cfg    xxx.cfg represents cond

libvirt笔记(未完待续)

参考源地址:http://libvirt.org/formatdomain.html http://blog.csdn.net/qq250941970/article/details/6022094 libvirt是管理KVM的工具,通过libvirt可以管理配置虚拟机.而虚拟机的配置主要都是通过libvirt的xml文件来实现的,因此xml是十分重要的. Domain XML format 从官网文档中,我们可以发现xml文件具有一定的格式. 1.Element and attribute o

aaaaaaaaaaaaaaaaaaaaaaa

下载制作完成的虚拟机镜像 wget http://192.168.1.1/vps.img -P /etc/xen/  建立配置文件: # vim  /etc/xen/vps name = "vps" uuid = "38c36e77-fdea-6839-ed9e-6eae22f52cd4" maxmem = 3584 memory = 3584 vcpus = 4 bootloader = "/usr/bin/pygrub" on_powerof

在xen上创建虚拟机并安装操作系统

1,安装第三方xen yum源 # yum install  http://au1.mirror.crc.id.au/repo/kernel-xen-release-6-5.noarch.rpm 2,安装桥工具 # yum -y install bridge-utils 3,安装xen # yum install xen44 4,验证是否安装成功 # ls -l /boot/xen.gz 5,安装xen内核 # yum install kernel-xen 6,关闭对xen有影响的服务 # se

xen kvm

1,查看是否支持硬件虚拟化egrep --color=auto '(vmx|xvm)' /proc/cpuinfo 2,安装xen yum -y install xen kernel-xen 3,title CentOS (3.7.4-1.el6xen.x86_64)        root (hd0,0)        kernel /xen.gz dom0_mem=512M cpufreq=xen dom0_max_vcpus=1 dom0_vcpus_pin        module /

xen实现虚拟化(二)

本文将介绍virt-manager.virt-install等工具在xen的半虚拟化平台上安装虚拟机,及xen的一些高级应用 一.virt-manager安装Guest虚拟机 # yum  -y install virt-manager libvirt virt-viewer    注意:我使用的为centos官方提供的libvirt,版本为:0.10.2.8 # service xend  start # service libvirtd start # virt-manager &    打

运维命令

==================================1 文件管理2 软件管理3 系统管理4 服务管理5 网络管理6 磁盘管理7 用户管理8 脚本相关9 服务配置==================================----------------------------------1 文件管理----------------------------------创建空白文件touch不提示删除非空目录rm -rf 目录名(-r:递归删除-f 强制)##########

虚拟化技术之虚拟化技术介绍及Xen的应用实现

虚拟化技术是什么: 在计算机中,虚拟化(英语:Virtualization)是一种资源管理技术,是将计算机的各种实体资源,如服务器.网络.内存及存储等,予以抽象.转换后呈现出来,打破实体结构间的不可切割的障碍,使用户可以比原本的组态更好的方式来应用这些资源.这些资源的新虚拟部份是不受现有资源的架设方式,地域或物理组态所限制.一般所指的虚拟化资源包括计算能力和资料存储.--转自百度百科 为什么需要虚拟化:  虚拟化技术在近几年来非常的火热, 实际上在上个世纪60年代, 就已经有了虚拟化的实现.由于