public inbox for development@lists.ipfire.org
 help / color / mirror / Atom feed
From: Adolf Belka <adolf.belka@ipfire.org>
To: development@lists.ipfire.org
Subject: Re: [PATCH 2/2] flash-image: Create a journal when the filesystem is being created
Date: Sat, 14 Dec 2024 13:58:16 +0100	[thread overview]
Message-ID: <b8c5e116-4ed1-4722-a7dc-6dc596326aa5@ipfire.org> (raw)
In-Reply-To: <20241214120547.863221-2-michael.tremer@ipfire.org>

[-- Attachment #1: Type: text/plain, Size: 2161 bytes --]

Reviewed-by: Adolf Belka <adolf.belka(a)ipfire.org>

On 14/12/2024 13:05, Michael Tremer wrote:
> We recently started to have problems when a new installation was
> launched from the flash image that creating the journal corrupted the
> filesystem on the next mount operation.
>
> Since we would like all IPFire installations to have a journal, we
> create this now when we create the image and won't try to add it later.
>
> Signed-off-by: Michael Tremer <michael.tremer(a)ipfire.org>
> ---
>   lfs/flash-images                  |  2 +-
>   src/initscripts/system/partresize | 13 -------------
>   2 files changed, 1 insertion(+), 14 deletions(-)
>
> diff --git a/lfs/flash-images b/lfs/flash-images
> index 30513f0bc..27d3a89d7 100644
> --- a/lfs/flash-images
> +++ b/lfs/flash-images
> @@ -126,7 +126,7 @@ endif
>   ifeq "$(EFI)" "1"
>   	mkfs.vfat $(PART_EFI)
>   endif
> -	mkfs.ext4 -O ^has_journal,extent -F $(PART_ROOT)
> +	mkfs.ext4 -F $(PART_ROOT)
>   
>   	# Most systems that use Flashimages has no RTC at boot
>   	# so the interval check should disables
> diff --git a/src/initscripts/system/partresize b/src/initscripts/system/partresize
> index df9c43991..832bc7237 100644
> --- a/src/initscripts/system/partresize
> +++ b/src/initscripts/system/partresize
> @@ -48,7 +48,6 @@ case "${1}" in
>   			# Azure and Google Compute Platform
>   			if running_on_ec2 || running_on_oci || running_on_azure || running_on_gcp; then
>   				scon="on"
> -				journal="on"
>   			fi
>   
>   			mount /boot > /dev/null
> @@ -110,18 +109,6 @@ case "${1}" in
>   						root_dev="${dev::-2}"
>   					fi
>   
> -					# Check if the device support smart
> -					smartctl --smart=on "${root_dev}" > /dev/null
> -					if [ ${?} = 0 ]; then
> -						journal="on"
> -					fi
> -
> -					# Enable journal
> -					if [ "${journal}" = "on" ]; then
> -						boot_mesg "Create journal on "${dev}" ..."
> -						tune2fs -O has_journal "${dev}"
> -					fi
> -
>   					boot_mesg "Growing root partition to maximum size..."
>   					echo -e ',+' | sfdisk --no-reread -f -N${part_num} "${root_dev}" 2>/dev/null
>   

  reply	other threads:[~2024-12-14 12:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-14 12:05 [PATCH 1/2] installer: Remove the option to install without journal Michael Tremer
2024-12-14 12:05 ` [PATCH 2/2] flash-image: Create a journal when the filesystem is being created Michael Tremer
2024-12-14 12:58   ` Adolf Belka [this message]
2024-12-14 12:57 ` [PATCH 1/2] installer: Remove the option to install without journal Adolf Belka

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=b8c5e116-4ed1-4722-a7dc-6dc596326aa5@ipfire.org \
    --to=adolf.belka@ipfire.org \
    --cc=development@lists.ipfire.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