Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Oct 2009 14:58:56 +0300
From:      Andriy Gapon <avg@icyb.net.ua>
To:        Alexander Best <alexbestms@math.uni-muenster.de>
Cc:        freebsd-current@FreeBSD.org
Subject:   Re: panic when mounting device >= 2 times
Message-ID:  <4AD5BD00.4050700@icyb.net.ua>
In-Reply-To: <permail-2009101411215080e26a0b00001bea-a_best01@message-id.uni-muenster.de>
References:  <permail-2009101411215080e26a0b00001bea-a_best01@message-id.uni-muenster.de>

next in thread | previous in thread | raw e-mail | index | archive | help
on 14/10/2009 14:21 Alexander Best said the following:
> could somebody have a look at this PR please:
> http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/108968
> 
> this still exists in -CURRENT.

This is because of serious and long-standing brokenness (probably from time of
introduction of GEOM) in g_vfs_open/g_vfs_close.
The essence:
1. we allow multiple concurrent read-only mounts of a device
2. but even a read-only mount mangles bufobj of device vnode
3. Bug!
Trivial fix with POLA violation - prohibit concurrent RO mounts.
Non-trivial fix - _somehow_ avoid changing or depending on device vnode bufobj.

See this for even more evil example of this problem:
http://lists.freebsd.org/pipermail/freebsd-fs/2009-February/005676.html

-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4AD5BD00.4050700>