>From cloud-init perspective, we have seen this too in our CI/CD
integration runs on both GCP and Azure lunar daily images which allows
cloud-init to resize2fs /dev/root on first boot, but also re-invokes
resize2fs a second time to assert cloud-init can be re-run all boot
stages without having to reboot[1] This 2nd run of cloud-init invokes
resize2fs /dev/root a second time.

This failure is resize2fs a second time due to checksums is seen only on
Azure lunar daily images containing linux-azure=5.19.0.1010.9 and
e2fsprogs=1.47.0. e2fsprogs=1.47.0 was introduced in Azure daily lunar
images on image version 23.04.202303170  (image version 23.04.202303170
allows multiple calls to resize2fs /dev/root without checksum errors)


GCP: CI/CD runners in cloud-init also started failing jobs on Mar 17th as well, 
presumably across the same image build update and introduction of 
esfsprogs=1.47.0 in lunar.


Our internal daily test runners track this failure signal well from daily image 
builds for Azure[2] and GCP lunar[3] giving us a good signal the the failure 
symptom below. We can ensure 

 'cloudinit.subp.ProcessExecutionError: Unexpected error while running '
 'command.\n'
 "Command: ('resize2fs', '/dev/root')\n"
 'Exit code: 1\n'
 'Reason: -\n'
 "Stdout: Couldn't find valid filesystem superblock.\n"
 'Stderr: resize2fs 1.47.0 (5-Feb-2023)\n'
 '        resize2fs: Superblock checksum does not match superblock while '
 'trying to open /dev/root\n'


references:
[1] cloud-init integration test which triggers multiple resize2fs /dev/root 
calls 
https://github.com/canonical/cloud-init/blob/main/tests/integration_tests/test_upgrade.py#L91-L105
[2] 
https://jenkins.canonical.com/server-team/view/cloud-init/job/cloud-init-integration-lunar-azure/
[3] 
https://jenkins.canonical.com/server-team/view/cloud-init/job/cloud-init-integration-lunar-gce/

** Also affects: cloud-init (Ubuntu)
   Importance: Undecided
       Status: New

** Also affects: linux-azure (Ubuntu)
   Importance: Undecided
       Status: New

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux-gcp in Ubuntu.
https://bugs.launchpad.net/bugs/2003816

Title:
  Regression in ext4 during online resize

Status in cloud-init package in Ubuntu:
  New
Status in linux package in Ubuntu:
  Invalid
Status in linux-azure package in Ubuntu:
  New
Status in linux-gcp package in Ubuntu:
  Invalid
Status in cloud-init source package in Jammy:
  New
Status in linux source package in Jammy:
  Fix Committed
Status in linux-azure source package in Jammy:
  New
Status in linux-gcp source package in Jammy:
  Fix Released

Bug description:
  Issue

  resize2fs utility is used to resize the filesystem and is idempotent
  in nature. But in the 5.15 kernel, successive execution of resize2fs
  is returning error.

  Reproduction step (on AWS):

      Create an AWS instance with AMI ami-056a67ea1b8ffa0fc (Linux 
5.15.0-1022-aws) in us-west-2 region and attach an EBS volume.
      Format and mount the disk - sudo mkfs.ext4 /dev/xvdb, sudo mkdir -p 
/mnt/ssd0, sudo mount /dev/xvdb /mnt/ssd0
      Increase the size of EBS volume.
      Run sudo resize2fs /dev/xvdb multiple times.

  The first execution returns -

  $ sudo resize2fs /dev/xvdb
  resize2fs 1.45.5 (07-Jan-2020)
  Filesystem at /dev/xvdb is mounted on /mnt/ssd0; on-line resizing required
  old_desc_blocks = 2, new_desc_blocks = 3
  The filesystem on /dev/xvdb is now 5242880 (4k) blocks long.

  The following execution returns -

  $ sudo resize2fs /dev/xvdb
  resize2fs 1.45.5 (07-Jan-2020)
  The filesystem is already 5242880 (4k) blocks long.  Nothing to do!

  When you run the same step on the latest image ami-0a1d6d351894df6cc
  (Linux 5.15.0-1026-aws).

  The first execution returns -

  $ sudo resize2fs /dev/xvdb
  resize2fs 1.45.5 (07-Jan-2020)
  Filesystem at /dev/xvdb is mounted on /mnt/ssd0; on-line resizing required
  old_desc_blocks = 2, new_desc_blocks = 3
  The filesystem on /dev/xvdb is now 5242880 (4k) blocks long.

  The following execution returns

  $ sudo resize2fs /dev/xvdb
  resize2fs 1.45.5 (07-Jan-2020)
  resize2fs: Superblock checksum does not match superblock while trying to open 
/dev/xvdb
  Couldn't find valid filesystem superblock.


  FIX:

  
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=a408f33e895e455f16cf964cb5cd4979b658db7b

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/cloud-init/+bug/2003816/+subscriptions


-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to     : kernel-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to