Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

mount --bind

18 views
Skip to first unread message

Why Tea

unread,
Mar 17, 2011, 8:37:47 AM3/17/11
to
If I have done the following:

# mount --bind /a/b /y/z

how do I find out if /y/z has been mounted to /a/b
in a bash script?

Samel

unread,
Mar 17, 2011, 9:20:54 AM3/17/11
to

Check $? for any command result

--- news://freenews.netfront.net/ - complaints: ne...@netfront.net ---

goarilla

unread,
Mar 17, 2011, 12:14:04 PM3/17/11
to

i think it's the reverse
/a/b is now accessible as /y/z *AND* /a/b

or I'm just misreading

James Waldby

unread,
Mar 17, 2011, 12:49:50 PM3/17/11
to
On Thu, 17 Mar 2011 05:37:47 -0700, Why Tea wrote:

Maybe you could test mount | grep /y/z ?

Eg,
sudo mount --bind 123 mnt
mount | grep 123
shows
/home/jw/tmp/123 on /home/jw/tmp/mnt type none (rw,bind)

--
jiw

0 new messages