X-Original-To: alpine-user@lists.alpinelinux.org Received: from mail-it1-f175.google.com (mail-it1-f175.google.com [209.85.166.175]) by lists.alpinelinux.org (Postfix) with ESMTP id 302CFF855BF for ; Fri, 7 Jun 2019 14:37:54 +0000 (UTC) Received: by mail-it1-f175.google.com with SMTP id i21so3031730ita.5 for ; Fri, 07 Jun 2019 07:37:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=NP3I/3tIQkww4mg+RERElrSOfVq39FptljiwfRhIWmU=; b=NvLwsx80Ae7Zm9MTIlsMVEEgNrokBayv6s5vjS82Q1g8vxamHprFc80hOEo9kITb68 NB+A0AptPPh7mE0KXkrSNB87flaqGy+7EiTtkBuSX+tmNdt1LtknxFN7kP9xfXWwJS0r XfolZSZjiwkpkIopcFbJ31zLeAB1plJxgfZwgF/sz8DNOBLtSFWxotkBqEmlsAkMhWmO 7z+/QY5FpGIFJA+GVwOZpCzF2GOQtq8i57KAHtCzWDKIXYESi77H049kYORM3Rlc6JAv a4ma30yf3OubGQNQTfkvmiQ30bd5jQbkeWNy23/hzFPh2dh17YZ/KYcH46sxJgRlRBBo iHMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=NP3I/3tIQkww4mg+RERElrSOfVq39FptljiwfRhIWmU=; b=mVJm1Et5doeIWsw6Ou5vPobMseqMSNtwCfuoHqTGzORlS9WvK9DR4FPnsWTPQrf+Dz 0p63JMxpI0GoI9GWZNPZwqY3dIFYAIbB+RtCOhvl6Hzbw7+s2zXz7293KUru4KyEBcsU Kuvznu0c/j2/ZHBmeDGfIFIct71WLwe6nvAtk4UPVchzGCT9d7YpGB2SbtK8EGCklLHc 6Ab3l2Y3ynWjaPjvrf/ZAwhOIS7MIfdp3OvvVDmV/xuZ4FYxrOkpYQufDzUDPwXF8j3H Nd3GYdW1kskKFy2etb/C5dwbL5m6r4NWWF+LqzglIXwHO34+8A0iwNPkvTPR/KdgGJxg F6dA== X-Gm-Message-State: APjAAAWbiYpiKTaFsyaCk3k9AAk9fyz7VspbleVIFRENwPVTr0u/6CMF PpT6d/tj/tlDrYhDUw5SfncD1h0EQmTiQcj36HOYuA== X-Google-Smtp-Source: APXvYqypsFqChgS8jI4XH6EKKpaHwS/qzGYvZ0gZjwzBqYU3vqze2y2xMMNunlWECUwoJgfJaQeUWwmPNZCzLJVdvqM= X-Received: by 2002:a02:1948:: with SMTP id b69mr13067074jab.55.1559918273629; Fri, 07 Jun 2019 07:37:53 -0700 (PDT) X-Mailinglist: alpine-user Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: MIME-Version: 1.0 References: In-Reply-To: From: PICCORO McKAY Lenz Date: Fri, 7 Jun 2019 10:37:41 -0400 Message-ID: Subject: Re: [alpine-user] Squashfs root filesystem To: Paul Zillmann Cc: alpine-user Content-Type: multipart/alternative; boundary="00000000000094184d058abcc6a6" --00000000000094184d058abcc6a6 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable gr4eat, thanks for the hints El vie., 7 de jun. de 2019 a la(s) 10:27, Paul Zillmann (p.zillmann@h6g.de) escribi=C3=B3: > Hello Lars-Erik, > > Am 07.06.19 um 12:40 schrieb Lars-Erik Helander: > > Is it possible to configure boot to run alpine using a read-only mounte= d > squashfs file? > > Yes it is, supposing the Kernel and initramfs are not part of the > squashfs file. > Take a look at [1] if the Kernel arguments work for you. > > Otherwise you can modify the init script here: > - mount the fs where the squashfs lies > - mount the squashfs > - mount a tmpfs > - mount an overlayfs as the new root, lower dir would be squashfs, > upper dir is the tmpfs > The scipt is located at /usr/share/mkinitfs/initramfs-init > Important parts at this section is "nlplug-findfs" and "exec > /bin/busybox switch_root" to exit the initramfs into the bootet system. > (You can replace the code in lines 479-490 as present in the linked > repository) > > Don't forget do add the squashfs and overlayfs Kernel modules into the > initramfs, then regenerate the initramfs. > > You should also take a look into the Alpine Netboot which uses modloop > instead of squashfs. > > 1: https://git.alpinelinux.org/mkinitfs/tree/initramfs-init.in#n455 > > - Paul > > > > > The mkinit code seems to include some squashfs support, but I can not > figure if that could be used for my purpose. > > > > /Lars > > > > Skickat fr=C3=A5n min iPhone > > > > > > --- > > Unsubscribe: alpine-user+unsubscribe@lists.alpinelinux.org > > Help: alpine-user+help@lists.alpinelinux.org > > --- > > > > > --- > Unsubscribe: alpine-user+unsubscribe@lists.alpinelinux.org > Help: alpine-user+help@lists.alpinelinux.org > --- > > --00000000000094184d058abcc6a6 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
gr4eat, thanks for the hints

El vie., 7 de jun. de 2019= a la(s) 10:27, Paul Zillmann (p.zillm= ann@h6g.de) escribi=C3=B3:
Hello Lars-Erik,

Am 07.06.19 um 12:40 schrieb Lars-Erik Helander:
> Is it possible to configure boot to run alpine using a read-only mount= ed squashfs file?

Yes it is, supposing the Kernel and initramfs are not part of the
squashfs file.
Take a look at [1] if the Kernel arguments work for you.

Otherwise you can modify the init script here:
=C2=A0=C2=A0=C2=A0=C2=A0 - mount the fs where the squashfs lies
=C2=A0=C2=A0=C2=A0=C2=A0 - mount the squashfs
=C2=A0=C2=A0=C2=A0=C2=A0 - mount a tmpfs
=C2=A0=C2=A0=C2=A0=C2=A0 - mount an overlayfs as the new root, lower dir wo= uld be squashfs,
upper dir is the tmpfs
The scipt is located at /usr/share/mkinitfs/initramfs-init
Important parts at this section is "nlplug-findfs" and "exec=
/bin/busybox switch_root" to exit the initramfs into the bootet system= .
(You can replace the code in lines 479-490 as present in the linked
repository)

Don't forget do add the squashfs and overlayfs Kernel modules into the =
initramfs, then regenerate the initramfs.

You should also take a look into the Alpine Netboot which uses modloop
instead of squashfs.

1: https://git.alpinelinux.org/mkini= tfs/tree/initramfs-init.in#n455

- Paul

>
> The mkinit code seems to include some squashfs support, but I can not = figure if that could be used for my purpose.
>
> /Lars
>
> Skickat fr=C3=A5n min iPhone
>
>
> ---
> Unsubscribe:=C2=A0 alpine-user+unsubscribe@lists.alpinelinux= .org
> Help:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0alpine-user+help@lists.alpin= elinux.org
> ---
>


---
Unsubscribe:=C2=A0 alpine-user+unsubscribe@lists.alpinelinux.org<= /a>
Help:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0
alpine-user+help@lists.alpinelinu= x.org
---

--00000000000094184d058abcc6a6-- --- Unsubscribe: alpine-user+unsubscribe@lists.alpinelinux.org Help: alpine-user+help@lists.alpinelinux.org ---