bugutil-vserver - Bugs: bug #25547, mounting /sbin readonly remounts...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #25547: mounting /sbin readonly remounts whole partition readonly

Submitter:  Andreas <medic>
Submitted:  Tue 10 Feb 2009 02:23:41 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Ready For Test
Privacy:  Public Assigned to:  daniel_hozac
Open/Closed:  Open Component Version:  stable
Release:  0.30.216

Jump to the original submission

Fri 24 Apr 2009 08:32:55 AM UTC, comment #6: 

we ported Your patch down and applied it to the current debian version.

We weren't able to reproduce any of the problems we had lately.

We are rolling this patch out to production environment now.
Thank You alot

Andreas <medic>
Fri 03 Apr 2009 05:01:37 PM UTC, comment #5: 

i just had a look at your patch, and i spawned an idea.
We had lately big issues when restarting vserver often due to config changes, resulting in having secure mount taking all cpu power of all 16 cores ... not accepting a kill -9, nor were we able to force-remount via sysreq.

i got the impression, there could be a kind of deadlock between secure_mount, the kernel and pd_flush, which stated to wait for IO all the time.

my colleague stated, he would have noticed that at his servers too, when using vserver and mount --bind.

Could this be a side-effect of this mount-problem ?

Andreas <medic>
Fri 03 Apr 2009 04:42:01 PM UTC, comment #4: 

No, the problem is with the way bind mounts with different attributes from the original mount point are handled in recent kernels. This should be fixed by commit 2832.

Daniel Hokka Zakrisson <daniel_hozac>
Group Member
Fri 03 Apr 2009 03:56:34 PM UTC, comment #3: 

I found the bug - this costs someone a case of beer ;)

It's a parser bug regarding reading fstab-parsing.

1st) the last entry in fstab when doing read-only-bind(only?)-mounts has to be "rw", otherwise

laura:/srv/vserver# touch test
laura:/srv/vserver# vserver vs-p49couk start
secure-mount: open(<mtab>): Read-only file system
Failed to update mtab-file
secure-mount: open(<mtab>): Read-only file system
Failed to update mtab-file
secure-mount: open(<mtab>): Read-only file system
Failed to update mtab-file
secure-mount: open(<mtab>): Read-only file system
Failed to update mtab-file
secure-mount: open(<mtab>): Read-only file system
Failed to update mtab-file
secure-mount: write(): Invalid argument
Failed to update mtab-file
secure-mount: write(): Invalid argument
Failed to update mtab-file
chroot-sh: unlink("var/run/lighttpd.pid"): Read-only file system
chroot-sh: unlink("var/run/crond.reboot"): Read-only file system
chroot-sh: unlink("var/run/crond.pid"): Read-only file system
chroot-sh: unlink("var/run/utmp"): Read-only file system

Failed to start vserver 'vs-p49couk'
laura:/srv/vserver# touch test
touch: can't touch „test“: Filesystem is read-only


It is only reproducible, if NOT already a vserver is running.
If any vserver is already running, it will start as expected.
If not - one ends up with these errors.

Andreas <medic>
Fri 03 Apr 2009 02:06:05 PM UTC, comment #2: 

It's standard lenny kernel

Linux atlas 2.6.26-1-vserver-amd64 #1 SMP Fri Mar 13 20:19:13 UTC 2009 x86_64 GNU/Linux


Andreas <medic>
Thu 26 Mar 2009 06:02:35 PM UTC, comment #1: 

What kernel is that on?

Daniel Hokka Zakrisson <daniel_hozac>
Group Member
Tue 10 Feb 2009 02:23:41 PM UTC, original submission:  

Our setup is:
- LVM partition which holds the vserver-data
- a stripped vserver, which mount-binds everything needed to start readonly
- a complete vserver serving as reference.


when /sbin in /etc/vserver/<vserver>/fstab is "bind,ro" the startup fails.

additionally the partition holding all vservers is remounted readonly.

This does not happen, if already a vserver is running ...

Andreas <medic>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by daniel_hozac (Posted a comment)
  • -email is unavailable- added by medic (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2009-04-03 daniel_hozac StatusNeed Info Ready For Test
        Assigned toNone daniel_hozac
    2009-03-26 daniel_hozac StatusNone Need Info

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code