From: Carl Karsten <carl@nextdayvideo.com>
To: linux-unionfs@vger.kernel.org
Subject: Re: sd .img partition loop support
Date: Mon, 18 Oct 2021 13:45:46 -0500 [thread overview]
Message-ID: <CADmzSSgZqrBCavL=NmO1_YPCHP7DfG9hLnN4gNBXZXyJTo8XiQ@mail.gmail.com> (raw)
In-Reply-To: <CADmzSSgquwg49GfMNSxi6KRcvq2nxPhwtiH311D+Ux_VTuE+fA@mail.gmail.com>
I'm trying to overlay an empty upper dir onto a fat/loop/img fs and getting:
juser@negk:~/boot$ sudo mount -o ro /dev/mapper/loop0p1 img
juser@negk:~/boot$ sudo mount -t overlay overlay
-olowerdir=img,upperdir=upper,workdir=work merged
mount: /home/juser/boot/merged: wrong fs type, bad option, bad superblock
on overlay, missing codepage or helper program, or other error.
[ 2449.670177] overlayfs: filesystem on 'lower' not supported
code to replicate:
mkdir boot
cd boot
mkdir img lower upper work merged
wget http://downloads.raspberrypi.org/raspios_lite_armhf/images/raspios_lite_armhf-2020-05-28/2020-05-27-raspios-buster-lite-armhf.zip
unzip 2020-05-27-raspios-buster-lite-armhf.zip
sudo kpartx -av 2020-05-27-raspios-buster-lite-armhf.img
sudo mount /dev/mapper/loop0p1 img
# this errors:
sudo mount -t overlay overlay -olowerdir=img,upperdir=upper,workdir=work
merged
# this does not
cp img/* lower/
sudo mount -t overlay overlay -olowerdir=lower,upperdir=upper,workdir=work
merged
https://github.com/CarlFK/pici/blob/main/test1.sh
The goal is to netboot a pi using the files from the .img with a few
changes, the root kernel parameter needs to be changed from local storage
to nfs:
# tftp/cmdline.txt
root=/dev/nfs nfsroot=10.21.0.1:/srv/nfs/rpi/root,vers=4.1,proto=tcp rw
ip=dhcp rootwait elevator=deadline consoleblank=0
I can copy all the files from the .img into a dir, but I am thinking I
should be able to overlay a dir on top to manage the changes.
If you want to see my netboot pi server setup
https://github.com/CarlFK/pici/blob/main/setup.md
--
Carl K
next parent reply other threads:[~2021-10-18 18:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CADmzSSgquwg49GfMNSxi6KRcvq2nxPhwtiH311D+Ux_VTuE+fA@mail.gmail.com>
2021-10-18 18:45 ` Carl Karsten [this message]
2021-10-19 6:53 ` sd .img partition loop support Amir Goldstein
2021-10-19 15:29 ` Carl Karsten
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CADmzSSgZqrBCavL=NmO1_YPCHP7DfG9hLnN4gNBXZXyJTo8XiQ@mail.gmail.com' \
--to=carl@nextdayvideo.com \
--cc=linux-unionfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).