From: Ian Jackson Subject: Re: [OSSTEST PATCH 5/6] ts-xen-build-prep: mkfs a new /home/osstest, don't resize2fs Date: Thu, 14 May 2015 18:48:03 +0100 Message-ID: <21844.57299.598941.161575@mariner.uk.xensource.com> References: <1431515722-5016-1-git-send-email-ian.jackson@eu.citrix.com> <1431515722-5016-6-git-send-email-ian.jackson@eu.citrix.com> <1431597912.13579.19.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1YsxEv-0007KX-GX for xen-devel@lists.xenproject.org; Thu, 14 May 2015 17:48:09 +0000 In-Reply-To: <1431597912.13579.19.camel@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Campbell Cc: xen-devel@lists.xenproject.org List-Id: xen-devel@lists.xenproject.org Ian Campbell writes ("Re: [OSSTEST PATCH 5/6] ts-xen-build-prep: mkfs a new /home/osstest, don't resize2fs"): > On Wed, 2015-05-13 at 12:15 +0100, Ian Jackson wrote: > > + echo '$mapper $dir $fstype defaults 0 0' >>/etc/fstab > > This doesn't update /etc/fstab so in standalone mode (when a host may > share build and test duties) the reboots will cause the > old /home/osstest to reappear and then I'm not sure if this all does > what we want or not with the existing lv. That line there is the update to /etc/fstab. The result is that if the host reboots the new fs should be mounted, and then when this runs again this > > + if mount | sed -e 's/^[^ ].* on //; s/ .*//' | grep -F '$dir'; then > > + exit 0 > > + fi is supposed to arrange that the whole thing is a no-op. Also note that the script makes the mount point with mode 2700 so that normal build scripts will crash if the fs is not mounted for some reason: > + mkdir -m 2700 $dir Ian.