AF:
NF:0
PS:10
SRH:1
SFN:
DSR:
MID:<20080208191102.2df26437@ripper.onstor.net>
CFG:
PT:0
S:andy.sharp@onstor.com
RQ:
SSV:onstor-exch02.onstor.net
NSV:
SSH:
R:<john.keiffer@onstor.com>,<john.rogers@onstor.com>,<larry.scheer@onstor.com>,<dl-qa@onstor.com>,<henry.lau@onstor.com>,<dl-cougar>
MAID:1
X-Sylpheed-Privacy-System:
X-Sylpheed-Sign:0
SCF:#mh/Mailbox/sent
RMID:#imap/andys@onstor.net@onstor-exch02.onstor.net/INBOX	0	BB375AF679D4A34E9CA8DFA650E2B04E0835117A@onstor-exch02.onstor.net
X-Sylpheed-End-Special-Headers: 1
Date: Fri, 8 Feb 2008 19:12:26 -0800
From: Andrew Sharp <andy.sharp@onstor.com>
To: "John Keiffer" <john.keiffer@onstor.com>
Cc: "John Rogers" <john.rogers@onstor.com>, "Larry Scheer"
 <larry.scheer@onstor.com>, "dl-QA" <dl-qa@onstor.com>, "Henry Lau"
 <henry.lau@onstor.com>, dl-cougar
Subject: Re: umounting problems
Message-ID: <20080208191226.5d260a6e@ripper.onstor.net>
In-Reply-To: <BB375AF679D4A34E9CA8DFA650E2B04E0835117A@onstor-exch02.onstor.net>
References: <BB375AF679D4A34E9CA8DFA650E2B04E08351160@onstor-exch02.onstor.net>
	<BB375AF679D4A34E9CA8DFA650E2B04E0346AF6D@onstor-exch02.onstor.net>
	<BB375AF679D4A34E9CA8DFA650E2B04E0835116B@onstor-exch02.onstor.net>
	<BB375AF679D4A34E9CA8DFA650E2B04E0835117A@onstor-exch02.onstor.net>
Organization: Onstor
X-Mailer: Sylpheed-Claws 2.6.0 (GTK+ 2.8.20; x86_64-pc-linux-gnu)
Mime-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit

On Fri, 8 Feb 2008 14:17:57 -0800 "John Keiffer"
<john.keiffer@onstor.com> wrote:

> I also noticed that I had previously mounted my mgmt volume, and the
> doesn't show up in the mount output:
0.0.0-020608/nfx-tree/B
> uild/cg/dbg/Release on /mnt type nfs (rw,addr=10.0.0.236)

You guys are killing me!  ~:^)  Your root filesystem is mounted RO, so
mounts and umounts can't be properly recorded in /etc/mnttab.  That's
what's causing the problem.  You do remember that you must always
remount root RW before any mount or umount, jah?  Jah.  It's easy to
forget sometimes, see bottom paragraph.

To remount on linux, the command is:

# mount -o remount,rw /

or 'ro' to remount read-only, etc.

When your root is RO and you're not sure if your mnttab file is
correct, you can always do this:

# cat /proc/mounts

which will give you an accurate listing of mounts, give-or-take a mount
flag or two.  The mount command won't try to unmount a filesystem that
can't be found in mnttab, -f option or otherwise, although that might
not be true if you give the device name as the argument, I haven't
tried that lately.

When I was porting flash_install.sh, I had a bug where it wasn't
remounting root RW before mounting a couple of directories on the
secondary flash.  But just a couple.  So those weren't recorded in
mnttab, and so couldn't be unmounted.  Drove me crazy for at least 2
hours before I noticed that /proc/mounts had the correct data.

Cheers,

a

PS Neither /proc/mounts or mnttab is always accurate with respect to
the RW v. RO flag.  Go figure.  If 

# touch /foo

fails, you're mounted RO ~:^)
