Re: mounted multiple times
- From: "Trevor \"TeC\" Christian" <trevor@xxxxxxxxxxxxxxxxx>
- Date: Sat, 03 Dec 2005 00:23:15 -0400
Jack Tanner wrote:
David G. Miller (aka DaveAtFraud <dave <at> davenjudy.org> writes:
Question, does umount still unmount "one instance" of the mount? This is the behavior under Red Hat Enterprise 3 (2.4 kernel) which also doesn't complain. The application I QA hasn't managed to get confused enough under RHEL4 (we start supporting RHEL4 under our next release) to mount one of our mount points multiple times so I don't have a data point for RHEL4 (2.6 kernel).
Under FC4 (kernel 2.6.14-1.1644), umount removes no mounts at all if there are multiple mounts of the same mount point.
Under RHEL3, I just keep issuing umounts for the mount point until I get rid of all of them. Would this work for your situation? Any idea when this "feature" got added to mount/umount?
The only thing that worked for removing one of the duplicate mount points was umount -f (as root).
I wrapped a code snippet posted earlier in this thread into a function that I then placed in my .bashrc.
mount_if_not_mounted() {
MOUNT='/bin/mount'
MOUNTPOINT='/mount/point'
if [ "`$MOUNT | grep "$MOUNTPOINT"`" = "" ] ; then
$MOUNT $1
fi
}
What is the expected value of $1?
Minor modification
mount_if_not_mounted() {
MOUNT='/bin/mount'
MOUNTPOINT=$1
if [ "`$MOUNT | grep "$MOUNTPOINT"`" = "" ] ; then
$MOUNT $MOUNTPOINT
fi
}mount_if_not_mounted "/mnt/samba/share";
In this case there's a parameter being supplied to the funtion which is used to define the mount point...
That works wonderfully when invoked from .bash_profile as
mount_if_not_mounted /mount/point
-- *Trevor "TeC" Christian* /TeC Productions Studios/ Cell #: (767) 225 4472 IM MSN: trevorc98@xxxxxxxxxxx / trevor@xxxxxxxxxxxxxxxxx YM : trevorc01@xxxxxxxxx AIM: DoubleOTeC GoogleTalk: doubleOTeC@xxxxxxxxx ------------------------------------------------------------------------ Home Page <http://trevor.bouyon.dalive.com/> Curriculum Vitae <http://bouyon.dalive.com/cv/> Dalive Market <http://www.dalivemarket.com/>
-- fedora-list mailing list fedora-list@xxxxxxxxxx To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
- References:
- Re: mounted multiple times
- From: David G. Miller (aka DaveAtFraud)
- Re: mounted multiple times
- From: Jack Tanner
- Re: mounted multiple times
- Prev by Date: Re: Help in setting up one http server for two different domains
- Next by Date: Re: PostgreSQL fails on boot, but works fine after logging in...?
- Previous by thread: Re: mounted multiple times
- Next by thread: Re: Updated Kernel Compilation Tutorial
- Index(es):
Relevant Pages
|
|