Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #56171 > unrolled thread

Bug#848181: initramfs-tools-core: support mounting of more complex setups

Started byTobias Schlemmer <keinstein@users.sf.net>
First post2016-12-14 23:10 +0100
Last post2016-12-15 00:00 +0100
Articles 7 — 4 participants

Back to article view | Back to linux.debian.kernel


Contents

  Bug#848181: initramfs-tools-core: support mounting of more complex setups Tobias Schlemmer <keinstein@users.sf.net> - 2016-12-14 23:10 +0100
    Bug#848181: initramfs-tools-core: support mounting of more complex setups Ben Hutchings <ben@decadent.org.uk> - 2016-12-15 00:00 +0100
      Bug#848181: initramfs-tools-core: support mounting of more complex setups Tobias Schlemmer <keinstein_junior@gmx.net> - 2016-12-15 20:30 +0100
        Bug#848181: initramfs-tools-core: support mounting of more complex setups Ben Hutchings <ben@decadent.org.uk> - 2016-12-15 21:10 +0100
          Bug#848181: initramfs-tools-core: support mounting of more complex setups Tobias Schlemmer <keinstein_junior@gmx.net> - 2016-12-17 02:10 +0100
            Bug#848181: initramfs-tools-core: support mounting of more complex setups Ben Hutchings <ben@decadent.org.uk> - 2016-12-17 03:40 +0100
    Processed: Re: Bug#848181: initramfs-tools-core: support mounting  of more complex setups owner@bugs.debian.org (Debian Bug Tracking System) - 2016-12-15 00:00 +0100

#56171 — Bug#848181: initramfs-tools-core: support mounting of more complex setups

FromTobias Schlemmer <keinstein@users.sf.net>
Date2016-12-14 23:10 +0100
SubjectBug#848181: initramfs-tools-core: support mounting of more complex setups
Message-ID<sOpUm-5Dh-29@gated-at.bofh.it>

[Multipart message — attachments visible in raw view] — view raw

Package: initramfs-tools-core
Version: 0.125
Severity: wishlist
Tags: patch

Hi,

I have the following antries in /etc/fstab:
/dev/mapper/tobias4-home /home           ext3    defaults        0       2
/home/usr /usr none bind 0 0

Currently /usr is not mounted automatically. However, with the attached patches
the mountfs function is able mount everything read-only. Tested manually with
the “kernel parameter” break=bottom.

Currently this script mounts only /usr, but not /usr/lib (if necessary) but
this can be easily added.




-- System Information:
Debian Release: stretch/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386, mingw64-amd64, mingw64-i386

Kernel: Linux 4.8.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=de_DE.utf8, LC_CTYPE=de_DE.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages initramfs-tools-core depends on:
ii  cpio         2.11+dfsg-6
ii  klibc-utils  2.0.4-9
ii  kmod         23-1
ii  udev         232-7

Versions of packages initramfs-tools-core recommends:
ii  busybox  1:1.22.0-19

Versions of packages initramfs-tools-core suggests:
ii  bash-completion  1:2.1-4.3

-- Configuration Files:
/etc/initramfs-tools/initramfs.conf changed:
MODULES=most
BUSYBOX=y
KEYMAP=n
COMPRESS=gzip
DEVICE=
NFSROOT=auto


-- no debconf information

[toc] | [next] | [standalone]


#56173

FromBen Hutchings <ben@decadent.org.uk>
Date2016-12-15 00:00 +0100
Message-ID<sOqGK-6gP-3@gated-at.bofh.it>
In reply to#56171

[Multipart message — attachments visible in raw view] — view raw

Control: tag -1 wontfix

This code is broken in several ways, and I don't want to add this sort
of complexity anyway.  Sorry.

Ben.

-- 
Ben Hutchings
The two most common things in the universe are hydrogen and stupidity.

[toc] | [prev] | [next] | [standalone]


#56222

FromTobias Schlemmer <keinstein_junior@gmx.net>
Date2016-12-15 20:30 +0100
Message-ID<sOJT4-1jR-13@gated-at.bofh.it>
In reply to#56173

[Multipart message — attachments visible in raw view] — view raw

Hi Ben,

Am 14.12.2016 um 23:51 schrieb Ben Hutchings:
> Control: tag -1 wontfix
> 
> This code is broken in several ways,

For me it would be interesting to know about them. So I could improve my
skills.

> and I don't want to add this sort
> of complexity anyway.  Sorry.

This complexity comes from the fact that initramfs ignores the mount
order in /etc/fstab and that it does not support the bind option of
mount (wich is supported by busybox, btw.).

Following this concept, you can only have either a good usability as
unix systems used to have for decades until the recent changes in
initramfs, or you can have a complicated system.

I see the following alternatives:
a) Check at configure time which filesystems are needed for mounting
/usr. This can lead into problems when administrators have to move the
contents of one directory to another partition (as it was in my case).

b) Provide an easily to modify configuration variable that can be used
to specify the filesystems that must be early mounted and their mount order.

Otherwise I expect that there will be many more bug reports and
complaints about initramfs in particular, Debian at medium level and the
unpredictability of Linux configuration in the future.

I think the 2nd approach will be the easiest to implement: replace
“mountfs /usr“ by “for fs in $EARLYMOUNTFS ; do mountfs "$fs"; done“ but
it may still lead to confusion while upgrading Debian. I'm using Debian
for more than 15 years, now, and, until recently, I had never a major
Debian release that rendered my system unbootable. People don't expect that.

Regards,

Tobias

[toc] | [prev] | [next] | [standalone]


#56224

FromBen Hutchings <ben@decadent.org.uk>
Date2016-12-15 21:10 +0100
Message-ID<sOKvL-1MW-1@gated-at.bofh.it>
In reply to#56222

[Multipart message — attachments visible in raw view] — view raw

On Thu, 2016-12-15 at 20:15 +0100, Tobias Schlemmer wrote:
> Hi Ben,
> 
> Am 14.12.2016 um 23:51 schrieb Ben Hutchings:
> > Control: tag -1 wontfix
> > 
> > This code is broken in several ways,
> 
> For me it would be interesting to know about them. So I could improve my
> skills.

For one, it has dependencies on scripts in /root on the root
filesystem.

[...]
> Otherwise I expect that there will be many more bug reports and
> complaints about initramfs in particular, Debian at medium level and the
> unpredictability of Linux configuration in the future.

There has been one other bug report so far (#781656).  The lack of
support for bind-mounting /usr (which I hadn't previously considered)
was then documented in initramfs-tools NEWS and the release notes for
jessie.

> I think the 2nd approach will be the easiest to implement: replace
> “mountfs /usr“ by “for fs in $EARLYMOUNTFS ; do mountfs "$fs"; done“ but
> it may still lead to confusion while upgrading Debian. I'm using Debian
> for more than 15 years, now, and, until recently, I had never a major
> Debian release that rendered my system unbootable. People don't expect that.

I'm sorry, but you can't claim you weren't warned about this.

The answer is still no.

Ben.

-- 
Ben Hutchings
It is easier to change the specification to fit the program than vice
versa.

[toc] | [prev] | [next] | [standalone]


#56251

FromTobias Schlemmer <keinstein_junior@gmx.net>
Date2016-12-17 02:10 +0100
Message-ID<sPbFD-2GI-27@gated-at.bofh.it>
In reply to#56224

[Multipart message — attachments visible in raw view] — view raw

Am 15.12.2016 um 21:03 schrieb Ben Hutchings:
> On Thu, 2016-12-15 at 20:15 +0100, Tobias Schlemmer wrote:
>> Hi Ben,
>>
>> Am 14.12.2016 um 23:51 schrieb Ben Hutchings:
>>> Control: tag -1 wontfix
>>>
>>> This code is broken in several ways,
>>
>> For me it would be interesting to know about them. So I could improve my
>> skills.
> 
> For one, it has dependencies on scripts in /root on the root
> filesystem.

Actually, it does not. functions.ts and local.ts are patched copies
/scripts/functions and /scripts/local, which I keep in /root for
development purposes, only. Both patches have been provided.

> [...]
>> Otherwise I expect that there will be many more bug reports and
>> complaints about initramfs in particular, Debian at medium level and the
>> unpredictability of Linux configuration in the future.
> 
> There has been one other bug report so far (#781656).

You probably have not noticed #847119. It is not obvious, that the
problem is caused by initramfs ignoring the mount order of fstab. So you
are probably not informed about all bug reports regarding this problem.

>  The lack of
> support for bind-mounting /usr (which I hadn't previously considered)
> was then documented in initramfs-tools NEWS and the release notes for
> jessie.

Sorry that does not help when I have to decide whether to install an
package or not, especially when there are more than 1000 packages to
upgrade. This information is available only after installing the
upgrade. This means, when the system is already unbootable.

>> I think the 2nd approach will be the easiest to implement: replace
>> “mountfs /usr“ by “for fs in $EARLYMOUNTFS ; do mountfs "$fs"; done“ but
>> it may still lead to confusion while upgrading Debian. I'm using Debian
>> for more than 15 years, now, and, until recently, I had never a major
>> Debian release that rendered my system unbootable. People don't expect that.
> 
> I'm sorry, but you can't claim you weren't warned about this.

I can't remember of beeing warned when I installed the upgrade. In fact
I was surprised that the init systems depend on having /usr being
available before mounting the file systems.

Regards,

Tobias

[toc] | [prev] | [next] | [standalone]


#56254

FromBen Hutchings <ben@decadent.org.uk>
Date2016-12-17 03:40 +0100
Message-ID<sPd4J-3qs-7@gated-at.bofh.it>
In reply to#56251

[Multipart message — attachments visible in raw view] — view raw

On Sat, 2016-12-17 at 02:06 +0100, Tobias Schlemmer wrote:
> Am 15.12.2016 um 21:03 schrieb Ben Hutchings:
> > On Thu, 2016-12-15 at 20:15 +0100, Tobias Schlemmer wrote:
> > > Hi Ben,
> > > 
> > > Am 14.12.2016 um 23:51 schrieb Ben Hutchings:
> > > > Control: tag -1 wontfix
> > > > 
> > > > This code is broken in several ways,
> > > 
> > > For me it would be interesting to know about them. So I could improve my
> > > skills.
> > 
> > For one, it has dependencies on scripts in /root on the root
> > filesystem.
> 
> Actually, it does not. functions.ts and local.ts are patched copies
> /scripts/functions and /scripts/local, which I keep in /root for
> development purposes, only.

That's what I thought.

> Both patches have been provided.

But not in a state which would ever be suitable for applying to a
package.

> > [...]
> > > Otherwise I expect that there will be many more bug reports and
> > > complaints about initramfs in particular, Debian at medium level and the
> > > unpredictability of Linux configuration in the future.
> > 
> > There has been one other bug report so far (#781656).
> 
> You probably have not noticed #847119. It is not obvious, that the
> problem is caused by initramfs ignoring the mount order of fstab. So you
> are probably not informed about all bug reports regarding this problem.

I think I can rely on the systemd maintainers to reassign such bugs.

> >  The lack of
> > support for bind-mounting /usr (which I hadn't previously considered)
> > was then documented in initramfs-tools NEWS and the release notes for
> > jessie.
> 
> Sorry that does not help when I have to decide whether to install an
> package or not, especially when there are more than 1000 packages to
> upgrade. This information is available only after installing the
> upgrade. This means, when the system is already unbootable.

The release notes are available before a system upgrade.  If you have
apt-listchanges installed (it's installed by default) then NEWS will
be presented at a point when you can still abort the upgrade.

> >> I think the 2nd approach will be the easiest to implement: replace
> >> “mountfs /usr“ by “for fs in $EARLYMOUNTFS ; do mountfs "$fs"; done“ but
> >> it may still lead to confusion while upgrading Debian. I'm using Debian
> >> for more than 15 years, now, and, until recently, I had never a major
> >> Debian release that rendered my system unbootable. People don't expect that.
> > 
> > I'm sorry, but you can't claim you weren't warned about this.
>
> I can't remember of beeing warned when I installed the upgrade. In fact
> I was surprised that the init systems depend on having /usr being
> available before mounting the file systems.

I suspect that you missed this during the upgrade to jessie, but things
just happened to work (with systemd mounting /usr later) until now.

Ben.

-- 
Ben Hutchings
Quantity is no substitute for quality, but it's the only one we've got.

[toc] | [prev] | [next] | [standalone]


#56175 — Processed: Re: Bug#848181: initramfs-tools-core: support mounting of more complex setups

Fromowner@bugs.debian.org (Debian Bug Tracking System)
Date2016-12-15 00:00 +0100
SubjectProcessed: Re: Bug#848181: initramfs-tools-core: support mounting of more complex setups
Message-ID<sOqGK-6gP-21@gated-at.bofh.it>
In reply to#56171
Processing control commands:

> tag -1 wontfix
Bug #848181 [initramfs-tools-core] initramfs-tools-core: support mounting of more complex setups
Added tag(s) wontfix.

-- 
848181: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=848181
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems

[toc] | [prev] | [standalone]


Back to top | Article view | linux.debian.kernel


csiph-web