WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] Invalidating buffer cache in dom0

To: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] Invalidating buffer cache in dom0
From: Jacob Gorm Hansen <jacobg@xxxxxxx>
Date: Thu, 26 May 2005 23:35:01 -0700
Delivery-date: Fri, 27 May 2005 06:35:29 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla Thunderbird 1.0 (X11/20050302)
hi,

I have a domU that dumps some data (a checkpoint) to a virtual device. Afterwards, I want to create a new domU based on that data, but because right now my domain bootstrapper does not have a disk driver, I first build a ramdisk which I give as an argument to my bootstrapper.

This all works fine, but I have the problem that I have to reboot dom0 between each run, because apparently dom0 Linux does not notice that the contents on disk have changed, and keep giving me stale data from its buffer cache when I create the ramdisk. I have tested that this is actually what happens by grepping for a string in the block device (/dev/hda5), and the value of the string changes between reboots.

Does anyone know of an ioctl or similar that I could use to make Linux forget about (not flush) buffer cache contents, or how to disable it?

I have tried reading from the block dev with O_DIRECT but that does not help.

Thanks,
Jacob

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>