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的更多相关文章

  1. 在 CentOS 上安装和配置 OpenNebula

    转自:http://www.aikaiyuan.com/4889.html 我们提到的云计算一般有三种类型:软件即服务(Software as a Service, SaaS),平台即服务(Platf ...

  2. libvirtsAPI

    mongodb远程服务器连接 mongo -uroot -p321 master.puppet.org:27017/admin

  3. xen之基本搭建

    1. 前言 所需包: kernel-xen xen xen-libs (xen依赖包) xen_runtime (xen依赖包) 以上xen包需要版本号一致,例如4.1.3版本,这里使用xm接口管理工 ...

  4. virsh VMI deploy data serial xml

    <domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>        <name> ...

  5. xen虚拟机操作整理

    1,登陆物理机器 2,查看物理机建立虚拟机的列表 root:~ # xm li Name ID Mem VCPUs State Time(s) Domain-0 0 49450 8 r----- 52 ...

  6. xen虚拟机(Centos6.6)的创建和扩容

    好久没来更博了,从这篇开始,我准备好好梳理一下Hadoop的那些"事".本人技术渣一枚,只是本着知识共享的原则,希望将我所掌握的知识分享出来.若文中有错误的地方,欢迎大家告知我,我 ...

  7. 实验六:通过grub程序引导本地磁盘内核启动系统(busybox)

    实验名称: 通过grub程序引导本地磁盘内核启动系统(busybox) 实验环境: 理论上,该实验只需要配置好xen环境即可,但是,我们的xen环境安装在centOS7上,但是我们又是使用的kerne ...

  8. 实验七:Xen环境下cirrOS的安装配置

    实验名称: Xen环境下cirrOS的安装配置 实验环境: 这里的cirrOS和实验六中的busybox的启动方式相同,唯一的区别就是我们使用的cirrOS镜像中,已经包含了根文件系统.内核文件以及r ...

  9. centos6.7环境半虚拟化软件xen及xm配置工具使用详解

    1.xen软件的安装及配置 环境准备: ①操作系统:centos6.7(注意最好使用centos6.7,centos6.5无法使用xen的图形化界面创建操作系统) ②调整虚拟机配置,内存4G(推荐2G ...

随机推荐

  1. HihoCoder 1121 二分图一•二分图判定

    二分图一•二分图判定 时间限制:10000ms 单点时限:1000ms 内存限制:256MB 描述 大家好,我是小Hi和小Ho的小伙伴Nettle,从这个星期开始由我来完成我们的Weekly. 新年回 ...

  2. matlab数据流仿真和时间流仿真

    simulink 使用的动态系统仿真,仿真需要求状态方程和输出方程,关键是求状态方程,而状态方程的求解有多种算法,可变步长和定步长,所以仿真时对求解器的选择和步长的设置就比较重要. 所谓基於数据流的仿 ...

  3. C#网络编程(接收文件) - Part.5

    这篇文章将完成 Part.4 中剩余的部分,它们本来是一篇完整的文章,但是因为上一篇比较长,合并起来页数太多,浏览起来可能会比较不方便,我就将它拆为两篇了,本文便是它的后半部分.我们继续进行上一篇没有 ...

  4. Android中内容观察者的使用---- ContentObserver类详解 (转)

    前言: 工作中,需要开启一个线程大量的查询某个数据库值发送了变化,导致的开销很大,后来在老大的指点下,利用了 ContentObserver完美的解决了该问题,感到很兴奋,做完之后自己也对Conten ...

  5. RelativeLayout里的gravity不能居中的解决方法

    最近在遇到RelativeLayout里的gravity属性给它复制center_horizontal或者center都不能居中它的子组件,后来找到了替代方法,只要在它的每个子组件里加上android ...

  6. Oracle配置文件tnsnames.ora新增链接后连接报错:ORA-12154: TNS:无法解析指定的标识符

    一个空格引发的血案:在tnsnames. ora文件中新加了一个配置,该配置估计当时是拷的别人的直接粘贴上去的,然后发现用pl/sql连接就一直报错了,后面排除了用户名和密码问题和后,仔细看了该文件才 ...

  7. 第16篇 Shell脚本基础(一)

    1.什么是shell?shell是一个命令解释器. 是介于操作系统内核与用户之间的一个绝缘层.对于一个linux系统使用人员来说,shell是你驾驭类linux系统最基本的工具.所有的系统命令和工具再 ...

  8. VC++中如何让RadioButton分组,并且互斥

    首先让两个RadioButton的Group属性为False. 将两个RadioButton放入一个GroupBox里面,即可如果分成多个组,则将多组Radio分别用GroupBox框起来,并将每组的 ...

  9. php小白和菜鸟 上班路上可以看的修行博客

    上班地铁 公交上我们不要去追剧 不要去打游戏 不要看看有效性的海量新闻, 我们需要去技术博客里遨游, 下面就推荐点与php有关的可以学习的技术博客; 大部分程序员在自学的道路上不知道走了多少坑,这个视 ...

  10. Ubuntu 下使用 mutt 和 msmtp 发送 Gmail 邮件

    参考:        http://www.cnblogs.com/refrag/archive/2012/11/28/2793533.html         http://www.habadog. ...