* Can't remount loopback ext4 without /etc/mtab
@ 2011-07-24 18:09 Daniel Drake
2011-07-24 19:57 ` Ted Ts'o
0 siblings, 1 reply; 7+ messages in thread
From: Daniel Drake @ 2011-07-24 18:09 UTC (permalink / raw)
To: util-linux
Hi,
In Fedora 14, the test case below worked fine. In Fedora 15, it fails.
I think this is due to the change to have /etc/mtab as a symlink to
/proc/mounts.
# dd if=/dev/zero of=fs.img bs=1M count=20
# mkfs.ext4 fs.img
# mkdir mountpt
# mount -o loop fs.img mountpt
Now try to remount it read-only:
# mount -o remount,ro mountpt
mount: /home/dsd/tmpdisk/mountpt not mounted already, or bad option
(On Fedora 14 no error was returned and the mount became read-only)
When the error occurs, dmesg says:
[ 5495.860391] EXT4-fs (loop0): Unrecognized mount option "seclabel"
or missing value
Here is the corresponding entry from /proc/mounts:
/dev/loop0 /home/dsd/tmpdisk/mountpt ext4
rw,seclabel,relatime,barrier=1,data=ordered 0 0
Is this a util-linux bug? Or an ext4 issue?
Thanks,
Daniel
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Can't remount loopback ext4 without /etc/mtab
2011-07-24 18:09 Can't remount loopback ext4 without /etc/mtab Daniel Drake
@ 2011-07-24 19:57 ` Ted Ts'o
2011-07-24 22:46 ` Davidlohr Bueso
2011-07-25 9:06 ` Karel Zak
0 siblings, 2 replies; 7+ messages in thread
From: Ted Ts'o @ 2011-07-24 19:57 UTC (permalink / raw)
To: Daniel Drake; +Cc: util-linux
On Sun, Jul 24, 2011 at 07:09:47PM +0100, Daniel Drake wrote:
>
> When the error occurs, dmesg says:
> [ 5495.860391] EXT4-fs (loop0): Unrecognized mount option "seclabel"
> or missing value
>
> Here is the corresponding entry from /proc/mounts:
> /dev/loop0 /home/dsd/tmpdisk/mountpt ext4
> rw,seclabel,relatime,barrier=1,data=ordered 0 0
>
> Is this a util-linux bug? Or an ext4 issue?
Or a selinux thing; "seclabel" seems to be SELinux's fault:
% git grep LABELSUPP_STR
security/selinux/hooks.c: {Opt_labelsupport, LABELSUPP_STR},
security/selinux/hooks.c: seq_puts(m, LABELSUPP_STR);
security/selinux/hooks.c: match_prefix(LABELSUPP_STR, sizeof(LABEL
security/selinux/include/security.h:#define LABELSUPP_STR "seclabel"
Personally, I find my life has been much happier since I gave up on
SELinux as being too complicated to be secure.
- Ted
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Can't remount loopback ext4 without /etc/mtab
2011-07-24 19:57 ` Ted Ts'o
@ 2011-07-24 22:46 ` Davidlohr Bueso
2011-07-25 9:06 ` Karel Zak
1 sibling, 0 replies; 7+ messages in thread
From: Davidlohr Bueso @ 2011-07-24 22:46 UTC (permalink / raw)
To: Ted Ts'o; +Cc: Daniel Drake, util-linux
On Sun, 2011-07-24 at 15:57 -0400, Ted Ts'o wrote:
> On Sun, Jul 24, 2011 at 07:09:47PM +0100, Daniel Drake wrote:
> >
> > When the error occurs, dmesg says:
> > [ 5495.860391] EXT4-fs (loop0): Unrecognized mount option "seclabel"
> > or missing value
> >
> > Here is the corresponding entry from /proc/mounts:
> > /dev/loop0 /home/dsd/tmpdisk/mountpt ext4
> > rw,seclabel,relatime,barrier=1,data=ordered 0 0
> >
> > Is this a util-linux bug? Or an ext4 issue?
>
> Or a selinux thing; "seclabel" seems to be SELinux's fault:
>
It would seem so, I can't reproduce this issue on a "normal", non
SELinux box.
> % git grep LABELSUPP_STR
> security/selinux/hooks.c: {Opt_labelsupport, LABELSUPP_STR},
> security/selinux/hooks.c: seq_puts(m, LABELSUPP_STR);
> security/selinux/hooks.c: match_prefix(LABELSUPP_STR, sizeof(LABEL
> security/selinux/include/security.h:#define LABELSUPP_STR "seclabel"
>
> Personally, I find my life has been much happier since I gave up on
> SELinux as being too complicated to be secure.
+1!!
- Davidlohr
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: Can't remount loopback ext4 without /etc/mtab
2011-07-24 19:57 ` Ted Ts'o
2011-07-24 22:46 ` Davidlohr Bueso
@ 2011-07-25 9:06 ` Karel Zak
2011-07-25 9:20 ` Daniel Drake
1 sibling, 1 reply; 7+ messages in thread
From: Karel Zak @ 2011-07-25 9:06 UTC (permalink / raw)
To: Ted Ts'o; +Cc: Daniel Drake, util-linux
On Sun, Jul 24, 2011 at 03:57:13PM -0400, Ted Ts'o wrote:
> On Sun, Jul 24, 2011 at 07:09:47PM +0100, Daniel Drake wrote:
> >
> > When the error occurs, dmesg says:
> > [ 5495.860391] EXT4-fs (loop0): Unrecognized mount option "seclabel"
> > or missing value
> >
> > Here is the corresponding entry from /proc/mounts:
> > /dev/loop0 /home/dsd/tmpdisk/mountpt ext4
> > rw,seclabel,relatime,barrier=1,data=ordered 0 0
> >
> > Is this a util-linux bug? Or an ext4 issue?
mount(8) "bug"
The kernel does not accept any SELinux specific mount options for
MS_REMOUNT. We already have exception for this in mount(8) ... and I
hate it, but our SELunux kernel guys are happy with this strange
behavior:
https://bugzilla.redhat.com/show_bug.cgi?id=563267#c9
> Personally, I find my life has been much happier since I gave up on
> SELinux as being too complicated to be secure.
+1
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2011-07-26 19:29 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-07-24 18:09 Can't remount loopback ext4 without /etc/mtab Daniel Drake
2011-07-24 19:57 ` Ted Ts'o
2011-07-24 22:46 ` Davidlohr Bueso
2011-07-25 9:06 ` Karel Zak
2011-07-25 9:20 ` Daniel Drake
2011-07-25 9:46 ` Karel Zak
2011-07-26 19:29 ` Daniel Drake
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.