[Bug 2129196] Re: mysql-server fails to install when an ext4 fs is mounted to /var/lib/mysql
Lena Voytek
2129196 at bugs.launchpad.net
Mon Nov 24 21:00:58 UTC 2025
Thanks for testing! I retried the jammy build and it should be ready to
test too now
--
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