public inbox for linux-ext4@vger.kernel.org
 help / color / mirror / Atom feed
From: bugzilla-daemon@kernel.org
To: linux-ext4@vger.kernel.org
Subject: [Bug 216714] Issue with file system image created with mke2fs parameter -E offset
Date: Mon, 28 Nov 2022 15:51:17 +0000	[thread overview]
Message-ID: <bug-216714-13602-UHEoF1jjyZ@https.bugzilla.kernel.org/> (raw)
In-Reply-To: <bug-216714-13602@https.bugzilla.kernel.org/>

https://bugzilla.kernel.org/show_bug.cgi?id=216714

Theodore Tso (tytso@mit.edu) changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |tytso@mit.edu

--- Comment #4 from Theodore Tso (tytso@mit.edu) ---
I'm curious --- *why* are you wanting to create file systems with an offset to
begin with?    The original reason why this feature was added was in a highly
specialized case where someone was creating a system image for some embedded
system or for a virtual machine.  In this use case, the image contained a
partition table, and the offset feature was used to create a filesystem at the
appropriate location as specified by the partition table.

A typical use case is as part of an automated build procedure where the system
image (say, for an Android mobile device, or some ARM development board, such
as a Beaglebone, Arduino, etc., or some Virtual machine), using the mke2fs -d
option to pre-populate the file system with the root file system, or some data
partition, etc.   Since Best Practices for such automated build systems involve
creating a reproducible build, there is nothing precious on the file system
that can't be replicated by re-running the the automated build.   So if the
offset is wrong (which is to say, inconsistent with the partition table which
was laid down using the same automated build system), the developer will just
curse to themselves, and can determine the offset by looking at the build image
creation script, and then adjust that offset to match with the offset that was
set in the partition table.

So I'm a bit perplexed about why you were using a random starting offset for
the file system, and why you can't seem to figure out the offset afterwards. 
The typical approach is to RTFS (Read The Fine Shellscript) to determine the
offset, and then to fix the perhaps not-so-fine shell script.  :-)

-- 
You may reply to this email to add a comment.

You are receiving this mail because:
You are watching the assignee of the bug.

      parent reply	other threads:[~2022-11-28 15:51 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-20 23:41 [Bug 216714] New: Issue with file system image created with mke2fs parameter -E offset bugzilla-daemon
2022-11-21  8:56 ` [Bug 216714] " bugzilla-daemon
2022-11-21 16:15 ` bugzilla-daemon
2022-11-28  1:00 ` bugzilla-daemon
2022-11-28  6:59 ` bugzilla-daemon
2022-11-28 15:51 ` bugzilla-daemon [this message]

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=bug-216714-13602-UHEoF1jjyZ@https.bugzilla.kernel.org/ \
    --to=bugzilla-daemon@kernel.org \
    --cc=linux-ext4@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