• Bug#1066646: live-boot: fails to mount persistence *files* from beside

    From Elena Grandi@21:1/5 to All on Wed Mar 13 14:30:02 2024
    Package: live-boot
    Version: 1:20230131
    Severity: normal

    Dear Maintainer,

    since the fix_ for #934701_, live boot is no longer considering the
    partition mounted e.g. on /run/live/medium even when looking for
    persistence partition image files (as opposed to persistence on regular partitions).

    It is my understanding that those would not fall under the case of

    The devices that are hosting the actual live rootfs should not be
    used for persistence storage since otherwise you might mount a parent
    directory on top of a sub-directory of the same filesystem in one
    union together.

    as described in the comment_ in the code that is doing the check, and
    thus they could be safely considered. Is it correct, or am I missing
    something?

    .. _fix: https://salsa.debian.org/live-team/live-boot/-/commit/ce7770b39f38d08bef557b67496c167499c0e3f4
    .. _#934701: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=934701
    .. _comment: https://salsa.debian.org/live-team/live-boot/-/blob/ce7770b39f38d08bef557b67496c167499c0e3f4/components/9990-misc-helpers.sh#L1076

    My usecase is that I'm running a system with multiple versions of a live system, each one of which has its own versioned /live directory with
    kernel etc. files, filesystem.squashfs *and* a persistence image file.
    This used to work up to bullseye, but has stopped working under
    bookworm, with the fixed version of live-boot.

    Would this be considered a valid usecase?

    In case it can be useful, what I'm doing is available online at https://github.com/Truelite/modian , where the -full-examples reproduce
    the issue.

    Thanks in advance

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Elena ``of Valhalla''@21:1/5 to All on Fri Mar 29 11:00:02 2024
    --KZjwZ+n1aDCCFlZO
    Content-Type: text/plain; charset=us-ascii
    Content-Disposition: inline
    Content-Transfer-Encoding: quoted-printable

    The attached patch should re-enable looking just for image files on all partitions; it does work on our usecase (but I don't know live-boot well
    enough to test for every other one).

    Thanks in advance,
    --
    Elena ``of Valhalla''

    --KZjwZ+n1aDCCFlZO
    Content-Type: text/x-diff; charset=us-ascii
    Content-Disposition: attachment;
    filename="0001-Look-for-persistence-files-also-on-blacklisted-devic.patch"
    Content-Transfer-Encoding: quoted-printable

    From 4873cd2e22a2107836d442ed9d98edb5a5325182 Mon Sep 17 00:00:00 2001
    From: Elena Grandi <elena@truelite.it>
    Date: Thu, 28 Mar 2024 10:35:07 +0100
    Subject: [PATCH] Look for persistence files also on blacklisted devices

    ---
    components/9990-misc-helpers.sh | 42 ++++++++++++++++++++-------------
    1 file changed, 25 insertions(+), 17 deletions(-)

    diff --git a/components/9990-misc-helpers.sh b/components/9990-misc-helpers.sh index 122014f..cac5e96 100755
    --- a/components/9990-misc-helpers.sh
    +++ b/components/9990-misc-helpers.sh
    @@ -1104,6 +1104,31 @@ find_persistence_media ()
    fi
    fi

    + # Probe for directory with matching name on mounted partition
    + if is_in_comma_sep_list directory ${PERSISTENCE_STORAGE}
    + then
    + result=$(probe_