Hi all, I''m a newbie on this list. I''m using xen 3.0.3 on CentOS50. I installed a new flavor of kernel in a domU via a standard RPM, which modified my grub.conf by adding a new entry to boot on the new kernel. When rebooting the domU by pygrub, I didn''t see the new grub entry. I tried to restart xend, with no effect. By googling a little, I understood that kernel files used by a domU must be present on the dom0, and it was considered as a bug. So I copied those files from the domU to the dom0... with no more effect. By rebooting the dom0, the new entry appeared and I be able to start my domU with its new kernel. I tried to remove the domU kernel files I copied before on the dom0, and the domU continues to boot normally. So I misunderstood what google said me before. I suppose that xen caches domU''s grub.conf somewhere on the dom0. My question is: where ? Thank you for answers. Alain. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi all, I''m a newbie on this list. I''m using xen 3.0.3 on CentOS50. I installed a new flavor of kernel in a domU via a standard RPM, which modified my grub.conf by adding a new entry to boot on the new kernel. When rebooting the domU by pygrub, I didn''t see the new grub entry. I tried to restart xend, with no effect. By googling a little, I understood that kernel files used by a domU must be present on the dom0, and it was considered as a bug. So I copied those files from the domU to the dom0... with no more effect. By rebooting the dom0, the new entry appeared and I be able to start my domU with its new kernel. I tried to remove the domU kernel files I copied before on the dom0, and the domU continues to boot normally. So I misunderstood what google said me before. I suppose that xen caches domU''s grub.conf somewhere on the dom0. My question is: where ? Thank you for answers. Alain. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Tue, 2007-12-11 at 11:08 +0100, Alain BARTHE wrote:> > By rebooting the dom0, the new entry appeared and I be able to start > my domU with its new kernel. I tried to remove the domU kernel files I > copied before on the dom0, and the domU continues to boot normally. So > I misunderstood what google said me before.My experience has been that an update to the grub config of a domU requires a shutdown/restart (rather than just a reboot) to take effect. John -- John Madden Sr. UNIX Systems Engineer Ivy Tech Community College of Indiana jmadden@ivytech.edu _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Alain BARTHE
2007-Dec-11 15:28 UTC
Re: [Xen-users] Where does xen chache domUs grub.conf ?
> My experience has been that an update to the grub config of a domU > requires a shutdown/restart (rather than just a reboot) to take effect.By "reboot", I meant "shutdown/restart". Among others things, I tried to run pygrub on the dom0 on the LV that support the domU''s virtual disk, while the domU is off. Without seeing any change. I also verified the grub.conf to be effectively updated by mounting the domU boot partition on the dom0, while the domU is off. The grub.conf was actually changed. That''s why I suppose something to be cached somewhere on the dom0. Did I miss something ? _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
> By "reboot", I meant "shutdown/restart". Among others things, I tried > to run pygrub on the dom0 on the LV that support the domU''s virtual > disk, while the domU is off. Without seeing any change. > I also verified the grub.conf to be effectively updated by mounting > the domU boot partition on the dom0, while the domU is off. The > grub.conf was actually changed. That''s why I suppose something to be > cached somewhere on the dom0.dom0 can/will certainly cache the contents of the disk you''re sharing to the domU: I had another case where "grub wasn''t getting installed inside domU" when it certainly was; less -f /dev/disk from dom0 didn''t show the grub sectors on the disk when they were definitely there, a domU shutdown "cleared the cache." So again, my experience has been that shutting it down completely fixed the problem, but perhaps it doesn''t for you. John -- John Madden Sr. UNIX Systems Engineer Ivy Tech Community College of Indiana jmadden@ivytech.edu _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Dec 11, 2007 8:08 AM, John Madden <jmadden@ivytech.edu> wrote:> > By "reboot", I meant "shutdown/restart". Among others things, I tried > > to run pygrub on the dom0 on the LV that support the domU''s virtual > > disk, while the domU is off. Without seeing any change. > > I also verified the grub.conf to be effectively updated by mounting > > the domU boot partition on the dom0, while the domU is off. The > > grub.conf was actually changed. That''s why I suppose something to be > > cached somewhere on the dom0. > > dom0 can/will certainly cache the contents of the disk you''re sharing to > the domU: I had another case where "grub wasn''t getting installed inside > domU" when it certainly was; less -f /dev/disk from dom0 didn''t show the > grub sectors on the disk when they were definitely there, a domU > shutdown "cleared the cache." So again, my experience has been that > shutting it down completely fixed the problem, but perhaps it doesn''t > for you.A domU shutdown will not necessarily clear the cache that is causing the pygrub problem. In fact, the problem has nothing to do with Xen or pygrub at all. It''s the linux kernel that''s caching the blocks in RAM and not noticing that they''ve changed on the disk. I ran into this when editing the grub configuration by mounting a kpartx device then trying to boot the VM off the normal LVM device. The kernel had no way of knowing that the pages containing grub.conf were dirty, so it just returned what it had cached in RAM. I''ll let a kernel hacker can explain this more thoroughly. Either of the following commands should clear the cache and let pygrub get the right information: echo 1 > /proc/sys/vm/drop_caches blockdev --flushbufs <device> See also: http://linux-mm.org/Drop_Caches blockdev(8) linux-2.6.xx/Documentation/filesystems/proc.txt (from the linux kernel source) -Al Tobey _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Alain BARTHE
2008-Jan-30 08:50 UTC
Re: [Xen-users] Where does xen chache domUs grub.conf ?
Thanks Al, that''s exactly the explanation I waited for. Alain. xen-users-bounces@lists.xensource.com a écrit sur 29/01/2008 03:29:10 :> On Dec 11, 2007 8:08 AM, John Madden <jmadden@ivytech.edu> wrote: > > > By "reboot", I meant "shutdown/restart". Among others things, Itried> > > to run pygrub on the dom0 on the LV that support the domU''s virtual > > > disk, while the domU is off. Without seeing any change. > > > I also verified the grub.conf to be effectively updated by mounting > > > the domU boot partition on the dom0, while the domU is off. The > > > grub.conf was actually changed. That''s why I suppose something to be > > > cached somewhere on the dom0. > > > > dom0 can/will certainly cache the contents of the disk you''re sharingto> > the domU: I had another case where "grub wasn''t getting installedinside> > domU" when it certainly was; less -f /dev/disk from dom0 didn''t showthe> > grub sectors on the disk when they were definitely there, a domU > > shutdown "cleared the cache." So again, my experience has been that > > shutting it down completely fixed the problem, but perhaps it doesn''t > > for you. > > A domU shutdown will not necessarily clear the cache that is causing > the pygrub problem. In fact, the problem has nothing to do with Xen > or pygrub at all. It''s the linux kernel that''s caching the blocks in > RAM and not noticing that they''ve changed on the disk. I ran into > this when editing the grub configuration by mounting a kpartx device > then trying to boot the VM off the normal LVM device. The kernel > had no way of knowing that the pages containing grub.conf were dirty, > so it just returned what it had cached in RAM. I''ll let a kernel > hacker can explain this more thoroughly. > > Either of the following commands should clear the cache and let pygrub > get the right information: > > echo 1 > /proc/sys/vm/drop_caches > blockdev --flushbufs <device> > > See also: > http://linux-mm.org/Drop_Caches > blockdev(8) > linux-2.6.xx/Documentation/filesystems/proc.txt (from the linux kernelsource)> > -Al Tobey > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users