[Bug 2129196] Re: mysql-server fails to install when an ext4 fs is mounted to /var/lib/mysql

Timo Aaltonen 2129196 at bugs.launchpad.net
Fri Nov 21 16:15:42 UTC 2025


Hello Zachary, or anyone else affected,

Accepted mysql-8.4 into plucky-proposed. The package will build now and
be available at
https://launchpad.net/ubuntu/+source/mysql-8.4/8.4.7-0ubuntu0.25.04.2 in
a few hours, and then in the -proposed repository.

Please help us by testing this new package.  See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed.  Your feedback will aid us getting this
update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested, what testing has been
performed on the package and change the tag from verification-needed-
plucky to verification-done-plucky. If it does not fix the bug for you,
please add a comment stating that, and change the tag to verification-
failed-plucky. In either case, without details of your testing we will
not be able to proceed.

Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification .  Thank you in
advance for helping!

N.B. The updated package will be released to -updates after the bug(s)
fixed by this package have been verified and the package has been in
-proposed for a minimum of 7 days.

** Changed in: mysql-8.4 (Ubuntu Plucky)
       Status: New => Fix Committed

** Tags added: verification-needed-plucky

** Changed in: mysql-8.0 (Ubuntu Noble)
       Status: New => Fix Committed

** Tags added: verification-needed-noble

-- 
You received this bug notification because you are a member of Ubuntu
Sponsors, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/2129196

Title:
  mysql-server fails to install when an ext4 fs is mounted to
  /var/lib/mysql

Status in mysql-8.0 package in Ubuntu:
  New
Status in mysql-8.4 package in Ubuntu:
  Fix Released
Status in mysql-8.0 source package in Jammy:
  Fix Committed
Status in mysql-8.0 source package in Noble:
  Fix Committed
Status in mysql-8.4 source package in Plucky:
  Fix Committed
Status in mysql-8.4 source package in Questing:
  Fix Committed
Status in mysql-8.4 source package in Resolute:
  Fix Released

Bug description:
  [ Impact ]

   * The postinst script for mysql-server checks whether the
  `/var/lib/mysql` directory is empty before setting up the database
  state. When `/var/lib/mysql` is an ext4 filesystem, the `lost+found`
  directory causes this check to fail and the database is not properly
  set up.

   * Mounting a separate volume to hold the mysql state is a common
  pattern, and ext4 is extremely prevalent so this is likely to be a
  common pain point. Although workarounds are straightforward, it makes
  for bad UX.

   * This can be remedied by ignoring the lost+found directory in the
  check.

  [ Test Plan ]

   To ensure bug is fixed:
   * Create an empty ext4 volume and mount it to /var/lib/mysql
   * Install mysql-server
   * Check whether the installation succeeds

   To check that data is preserved:
   * Uninstall and reinstall mysql-server
   * Ensure that the data in /var/lib/mysql is not overwritten

  [ Where problems could occur ]

   * In this case, the only change is to the postinst script, so problems should be related to install.
   * If the check being done were incorrect it could lead to loss of user data.
     - We keep the change to script to a minimum to reduce the risk of this
     - Test plan includes confirming that user data is not overwritten

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-8.0/+bug/2129196/+subscriptions





More information about the Ubuntu-sponsors mailing list