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] [PATCH]put xenstored tdb to tmpfs

To: xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] [PATCH]put xenstored tdb to tmpfs
From: Zhigang Wang <zhigang.x.wang@xxxxxxxxxx>
Date: Thu, 21 Jan 2010 11:19:14 +0800
Delivery-date: Wed, 20 Jan 2010 19:19:45 -0800
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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.23 (X11/20090812)
Hi,

This patch put the xenstored tdb into tmpfs. It will improve the performance
when there are intensive xenstore read/writes.

Signed-off-by: Zhigang Wang <zhigang.x.wang@xxxxxxxxxx>

thanks,

zhigang




--- xen-unstable/tools/hotplug/Linux/init.d/xend        2009-09-18 
00:04:17.000000000 +0800
+++ xen-unstable/tools/hotplug/Linux/init.d/xend.new    2010-01-21 
11:12:48.000000000 +0800
@@ -57,6 +57,13 @@
        test -z "$XENCONSOLED_TRACE" || export XENCONSOLED_TRACE
        [[ "$XENSTORED_TRACE" == @(yes|on|1) ]] && export XENSTORED_TRACE
        [[ "$XENBACKENDD_DEBUG" == @(yes|on|1) ]] && export XENBACKENDD_DEBUG
+       pid=`cat /var/run/xenstore.pid 2>/dev/null`
+       if [ -z "$pid" -o ! -d "/proc/$pid" ]; then
+               dir=${XENSTORED_ROOTDIR:-/var/lib/xenstored}
+               if ! grep -q "$dir" /proc/mounts 2>/dev/null; then
+                       mount -t tmpfs none "$dir"
+               fi
+       fi
        xend start
        await_daemons_up
        ;;
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH]put xenstored tdb to tmpfs, Zhigang Wang <=