Compare commits

...
Sign in to create a new pull request.

15 commits

Author SHA1 Message Date
b44ba4ca9d Bump release for tmpfiles.d fixup 2026-01-10 23:25:34 +01:00
361286ca01 [tmpfiles.d] Fixup of the tmpfile.d rules
Each line must begin with a valid prefix (type)
  https://www.man7.org/linux/man-pages/man5/tmpfiles.d.5.html
2026-01-10 23:25:26 +01:00
cd65e91adc Bump release for tmpfiles.d fixup 2026-01-10 23:25:19 +01:00
1c5fa82301 [tmpfiles.d] Fixup of the tmpfile.d rules
A comment is misisng a comment line prefix
2026-01-10 23:25:14 +01:00
Nikola Davidova
8faf748ba4 Bump release for tmpfiles.d change 2026-01-10 23:25:08 +01:00
Nikola Davidova
2ce028a64a Extend tmpfiles.d rules for ImageMode
After switching to a container image with bootc switch, systemd failed to start
mysqld because required runtime directories were missing or had wrong permissions.

Adding tmpfiles entries with correct ownership ensures systemd creates the
necessary directories at boot and gives them correct permissions, allowing the
mysql daemon to start.

"In a container build, you can write to '/var'. However, this will have a semantic
similar to a Dockerfile VOLUME instruction; the content from the container image
is only copied at initial install time. Any subsequent system updates will not
by default see new changes.

It's recommended instead to use e.g. systemd tmpfiles.d as a way to ensure that
newly added state "reconciles" across upgrades as desired."

https://docs.fedoraproject.org/en-US/bootc/filesystem/#_filesystem_bind_mount_var

This covers all the files in /var sicne we only ship these as can be seen here:
find | grep /var/
./mysql8.0-server-8.4.5-1.fc43.x86_64.rpm/var/lib
./mysql8.0-server-8.4.5-1.fc43.x86_64.rpm/var/lib/mysql
./mysql8.0-server-8.4.5-1.fc43.x86_64.rpm/var/lib/mysql-files
./mysql8.0-server-8.4.5-1.fc43.x86_64.rpm/var/lib/mysql-keyring
./mysql8.0-server-8.4.5-1.fc43.x86_64.rpm/var/log
./mysql8.0-server-8.4.5-1.fc43.x86_64.rpm/var/log/mysql

The '/usr' directory is not persistent therefore this change does not affect it
and the '/etc' directory is merged in a different way and also not under the
'mysql:mysql' user
2026-01-10 23:25:03 +01:00
ffdad46fbb Testsuite verification for 8.0.44 release
The testsuite is currently disabled because of very long build times on the s390x Fedora builders.

The x86_64 build without tetsuite takes ~15 minutes.
The x86_64, i686, ppc64le, aarch64 builds with the main suite all takes between 50 and 60 minutes, while the s390x takes nearly 7 hours.
Builds with the full testsuite takes approximatelly double the time of the builds with just the main suite.

--

There were some failing tests:
 |  auth_sec.admin_channel_tls
 |  auth_sec.admin_channel_tls_startup
 |  auth_sec.cert_verify
 |  auth_sec.cert_verify_openssl
 |  x.mysqlxtest_mode_ssl
 |  x.mysqlxtest_mode_ssl_unixsocket
and all of them fail because the test certificates in the 'std_data' testsuite directory have expired.

Some of those tests fail gracefuly, some not. But all of them produce variant of this error message:
 "Server SSL certificate doesn't verify: certificate has expired"

--

I believe this is a recuring timebomb bug in MySQL.
I found this upstream commit dealing with the issue few years ago:
  8c22b5f6df
but this time different certificates needs refreshing, e.g.:
 | std_data/server-cert-verify-fail.pem
 | std_data/server-cert-verify-pass.pem
and maybe some more.
2026-01-10 23:24:57 +01:00
Pavol Sloboda
993d914638 Updated the skipped test list with the newest finding s in the main test
suite. The tests are still disabled because the infrastructure issues
with s390x and ppc64le are still present
2026-01-10 23:24:51 +01:00
Pavol Sloboda
3b4a18961a Rebase to 8.0.44
Upstream release notes:
https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-44.html

Resolves: RHBZ#2407154
2026-01-10 23:24:43 +01:00
Lukas Javorsky
aea0759ce7 Revert to soft static allocation of MariaDB and MySQL sysusers.d files
Resolves: RHEL-119789

Related PR for `setup` RPM: https://src.fedoraproject.org/rpms/setup/pull-request/30

Partially reverts commit: 3556d5e

The MariaDB and MySQL sysusers.d files has to use soft static allocation in order to correctly handle the MariaDB PAM v2 plugin which utilizes setuid-to-root binary "/usr/lib64/mariadb/plugin/auth_pam_tool_dir/auth_pam_tool".
2026-01-10 23:24:35 +01:00
Pavol Sloboda
0358d7d293 [bugfix] Fix packaging of the default MySQL server log
We've received a bug report, that the 'rpm -qc' incorrectly returns the MySQL
server default log file '/var/log/mysql/mysqld.log' as a configuration file.
  https://issues.redhat.com/browse/RHEL-57601

This was caused by us packing it in the SPECfile '%files' section with the
'%config %ghost' directives. The reason was historical. We tried to mark
the file as owned by the package, but at the same time to not pack it,
and also prevent its deleteion on package removal.

The correct way is to not list the file at all.
The parent directory is properly packed and owned instead (already), so it should be
clear that the files inside are associated with that package. This is how we already
do it with the DB datadir '/var/lib/mysql'.

Resolves: RHEL-57601

While investigating this issue, we also reviewed the log file creation.
The log file is created automatically by the MySQL server when needed.
This can even happen in the middle of the server runtime, when the file
is (re)moved, and the DB server is tasked to flush the logs.

I checked the MySQL server documentation, and tested it, and I found, that the logfile
is indeed created by the server. The only possible reason why the file might be needed
to be created beforehand, is when the file lies on a location to which the MySQL server
won't have permissions to write to.

This is likely the case of MySQL upstream RPMs, which place it by default to the '/var/log':
  96d58aa2b9/packaging/rpm-fedora/mysql.spec.in (L703)

However Fedora and RHEL uses a designated directory '/var/log/mysql', which is owened by 'mysql:mysql',
so the issue does not exists here.
2026-01-10 23:24:28 +01:00
6288efd5f8 [bugfix] Fixup of the versioned package layout control code 2026-01-10 23:24:22 +01:00
Pavol Sloboda
00a4b0bede Rebase to 8.0.43
Upstream release notes:
https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-43.html

Resolves: RHBZ#2383954

Resolves: RHBZ#2381703
2026-01-10 23:24:11 +01:00
1ad8e8a7c3 [bugfix] Fix the 'Conflicts:' with MariaDB packages
The package conflicts between MariaDB and MySQL packages are only set against the un-versioned names.
(the un-versioned names are only provided by the distribution default version)

The conflicts has to be extended to cover the '-any' virtually provided names,
which are provided by all versions of the versioned packages.
2026-01-10 23:23:22 +01:00
Pavol Sloboda
a94b935b5e [logrotate] Enhance the logrotate configuration to use systemctl kill
`systemctl kill` leverages systemd's knowledge of the daemon's main PID,
eliminating the need to rely on PID files or external tools like
`killall` or `pkill`.
This ensures precise signal sending to the intended process, reducing
the risk of errors in process identification. Additionally, using
`systemctl kill` logs the signal sending in the service's journal,
providing a record of actions taken.
Requires selinux-policy-41.43 or higher, which is currently available as
an update for F41, F42, and Rawhide.

Resolves: RHBZ#2372778

Also updated the comment for 'Requires: systemd' to list all of the parts
that 'systemd' is required for. This is useful for packaging for systems
without systemd, such as containers.
2026-01-10 23:22:58 +01:00
7 changed files with 77 additions and 44 deletions

View file

@ -1,5 +1,6 @@
--- mysql-8.0.40/packaging/rpm-common/mysql.logrotate.in 2024-09-18 12:08:24.000000000 +0200
+++ mysql-8.0.40/packaging/rpm-common/mysql.logrotate.in_patched 2025-02-13 16:00:32.325677977 +0100
diff -Naur mysql-8.0.42/packaging/rpm-common/mysql.logrotate.in mysql-8.0.42_patched/packaging/rpm-common/mysql.logrotate.in
--- mysql-8.0.42/packaging/rpm-common/mysql.logrotate.in 2025-07-10 16:20:26.000000000 +0200
+++ mysql-8.0.42_patched/packaging/rpm-common/mysql.logrotate.in 2025-07-29 10:16:39.509884723 +0200
@@ -5,18 +5,6 @@
# [mysqld]
# log-error=@LOGFILE_RPM@
@ -30,6 +31,6 @@
-# @bindir@/mysqladmin flush-logs
-# fi
+# # SIGUSR1 makes the daemon to flush the logs, no need to connect through mysqladmin
+# @bindir@/kill -USR1 $(systemctl show --property MainPID --value mysqld)
+# @bindir@/systemctl kill --signal=USR1 --kill-whom=main mysqld.service 2>/dev/null || true
# endscript
#}

View file

@ -3,11 +3,10 @@ Software Collections. Removing these hard-coded paths should fix it.
Upstream report: https://mariadb.atlassian.net/browse/MDEV-6485
diff --git a/cmake/install_layout.cmake b/cmake/install_layout.cmake
index 9f7945d8..6734cdfd 100644
--- a/cmake/install_layout.cmake
+++ b/cmake/install_layout.cmake
@@ -105,7 +105,7 @@ IF(UNIX)
diff -Naur mysql-8.0.43/cmake/install_layout.cmake mysql-8.0.43_patched/cmake/install_layout.cmake
--- mysql-8.0.43/cmake/install_layout.cmake 2025-07-09 10:45:01.000000000 +0200
+++ mysql-8.0.43_patched/cmake/install_layout.cmake 2025-08-05 09:22:54.506782584 +0200
@@ -106,7 +106,7 @@
" Choose between ${VALID_INSTALL_LAYOUTS}" )
ENDIF()
@ -16,19 +15,18 @@ index 9f7945d8..6734cdfd 100644
CACHE PATH "config directory (for my.cnf)")
MARK_AS_ADVANCED(SYSCONFDIR)
ENDIF()
@@ -189,6 +189,7 @@ SET(INSTALL_SECURE_FILE_PRIVDIR_TARGZ ${secure_file_priv_path})
#
SET(INSTALL_BINDIR_RPM "bin")
SET(INSTALL_SBINDIR_RPM "sbin")
@@ -202,6 +202,7 @@
ELSE()
SET(INSTALL_SBINDIR_RPM "sbin")
ENDIF()
+SET(INSTALL_SYSCONFDIR_RPM "/etc")
#
IF(CMAKE_SYSTEM_PROCESSOR IN_LIST KNOWN_64BIT_ARCHITECTURES)
SET(INSTALL_LIBDIR_RPM "lib64/mysql")
diff --git a/mysys/my_default.cc b/mysys/my_default.cc
index 290f1666..8403425f 100644
--- a/mysys/my_default.cc
+++ b/mysys/my_default.cc
@@ -1570,12 +1570,12 @@ static const char **init_default_directories(MEM_ROOT *alloc) {
diff -Naur mysql-8.0.43/mysys/my_default.cc mysql-8.0.43_patched/mysys/my_default.cc
--- mysql-8.0.43/mysys/my_default.cc 2025-07-09 10:45:01.000000000 +0200
+++ mysql-8.0.43_patched/mysys/my_default.cc 2025-08-05 09:24:59.510804797 +0200
@@ -1652,12 +1652,12 @@
#else
@ -44,11 +42,10 @@ index 290f1666..8403425f 100644
#endif /* DEFAULT_SYSCONFDIR */
#endif
diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt
index 4149a764..b091d5e2 100644
--- a/scripts/CMakeLists.txt
+++ b/scripts/CMakeLists.txt
@@ -288,9 +288,9 @@ IF(UNIX)
diff -Naur mysql-8.0.43/scripts/CMakeLists.txt mysql-8.0.43_patched/scripts/CMakeLists.txt
--- mysql-8.0.43/scripts/CMakeLists.txt 2025-07-09 10:45:01.000000000 +0200
+++ mysql-8.0.43_patched/scripts/CMakeLists.txt 2025-08-05 09:25:55.019369630 +0200
@@ -271,9 +271,9 @@
ENDIF(UNIX)
SET(prefix "${CMAKE_INSTALL_PREFIX}")
@ -60,11 +57,10 @@ index 4149a764..b091d5e2 100644
SET(datadir ${prefix}/${INSTALL_MYSQLSHAREDIR})
SET(libsubdir ${INSTALL_LIBDIR})
SET(pkgincludedir ${prefix}/${INSTALL_INCLUDEDIR})
diff --git a/scripts/mysqld_multi.pl.in b/scripts/mysqld_multi.pl.in
index 84dd4d7c..50397ddd 100644
--- a/scripts/mysqld_multi.pl.in
+++ b/scripts/mysqld_multi.pl.in
@@ -586,9 +586,7 @@ sub list_defaults_files
diff -Naur mysql-8.0.43/scripts/mysqld_multi.pl.in mysql-8.0.43_patched/scripts/mysqld_multi.pl.in
--- mysql-8.0.43/scripts/mysqld_multi.pl.in 2025-07-09 10:45:01.000000000 +0200
+++ mysql-8.0.43_patched/scripts/mysqld_multi.pl.in 2025-08-05 09:26:57.252077640 +0200
@@ -587,9 +587,7 @@
my %seen; # Don't list the same file more than once
return grep { defined $_ and not $seen{$_}++ and -f $_ and -r $_ }

View file

@ -1 +1,8 @@
d @PID_FILE_DIR@ 0755 mysql mysql -
# Rules for ephemeral file systems (ImageMode)
d /var/lib/mysql 0755 mysql mysql -
d /var/log/mysql 0750 mysql mysql -
f /var/log/mysql/mysql.log 0640 mysql mysql -
d /var/lib/mysql-files 0750 mysql mysql -
d /var/lib/mysql-keyring 0700 mysql mysql -

View file

@ -1,6 +1,6 @@
# Name of the package without any prefixes
%global majorname mysql
%global package_version 8.0.42
%global package_version 8.0.44
%define majorversion %(echo %{package_version} | cut -d'.' -f1-2 )
%global pkgnamepatch mysql
@ -19,7 +19,7 @@
# The last version on which the full testsuite has been run
# In case of further rebuilds of that version, don't require full testsuite to be run
# run only "main" suite
%global last_tested_version 8.0.42
%global last_tested_version 8.0.44
# Set to 1 to force run the testsuite even if it was already tested in current version
%global force_run_testsuite 0
@ -102,7 +102,7 @@
Name: %{majorname}%{majorversion}
Version: %{package_version}
Release: 2%{?with_debug:.debug}%{?dist}
Release: 4%{?with_debug:.debug}%{?dist}
Summary: MySQL client programs and shared libraries
URL: http://www.mysql.com
@ -259,9 +259,9 @@ Provides: bundled(rapidjson)
# https://github.com/martinus/unordered_dense
Provides: bundled(unordered_dense)
%{?with_conflicts_mariadb:Conflicts: mariadb}
%{?with_conflicts_mariadb:Conflicts: mariadb-any}
# Explicitly disallow installation of mysql + mariadb-server
%{?with_conflicts_mariadb:Conflicts: mariadb-server}
%{?with_conflicts_mariadb:Conflicts: mariadb-server-any}
%{?with_provides_community_mysql:Provides: community-mysql = %community_mysql_version}
%{?with_provides_community_mysql:Provides: community-mysql%{?_isa} = %community_mysql_version}
%{?with_obsoletes_community_mysql:Obsoletes: community-mysql <= %obsolete_community_mysql_version}
@ -306,11 +306,13 @@ client/server implementation consisting of a server daemon (mysqld)
and many different client programs and libraries. The base package
contains the standard MySQL client programs and generic MySQL files.
%if %?mysql_default
%description -n %{pkgname}
MySQL is a multi-user, multi-threaded SQL database server. MySQL is a
client/server implementation consisting of a server daemon (mysqld)
and many different client programs and libraries. The base package
contains the standard MySQL client programs and generic MySQL files.
%endif
%if %{with clibrary}
%package -n %{pkgname}-libs
@ -401,6 +403,7 @@ Requires: %{pkgname}-errmsg = %{sameevr}
%{?mecab:Requires: mecab-ipadic}
Requires: coreutils
# We require this to be present for %%{_tmpfilesdir}
# `systemd` is also required for logrotate, as it uses `systemctl kill`
Requires: systemd
# Make sure it's there when scriptlets run, too
%{?systemd_requires: %systemd_requires}
@ -415,11 +418,11 @@ Requires(post): policycoreutils-python-utils
Requires: (mysql-selinux if selinux-policy-targeted)
%endif
%{?with_conflicts_mariadb:Conflicts: mariadb-server}
%{?with_conflicts_mariadb:Conflicts: mariadb-server-utils}
%{?with_conflicts_mariadb:Conflicts: mariadb-server-galera}
%{?with_conflicts_mariadb:Conflicts: mariadb-server-any}
%{?with_conflicts_mariadb:Conflicts: mariadb-server-utils-any}
%{?with_conflicts_mariadb:Conflicts: mariadb-server-galera-any}
# Explicitly disallow installation of mysql + mariadb-server
%{?with_conflicts_mariadb:Conflicts: mariadb}
%{?with_conflicts_mariadb:Conflicts: mariadb-any}
%{?with_provides_community_mysql:Provides: community-mysql-server = %community_mysql_version}
%{?with_provides_community_mysql:Provides: community-mysql-server%{?_isa} = %community_mysql_version}
%{?with_obsoletes_community_mysql:Obsoletes: community-mysql-server <= %obsolete_community_mysql_version}
@ -440,7 +443,7 @@ Summary: Files for development of MySQL applications
Requires: openssl-devel
Requires: zlib-devel
Requires: libzstd-devel
%{?with_conflicts_mariadb:Conflicts: mariadb-devel}
%{?with_conflicts_mariadb:Conflicts: mariadb-devel-any}
%{?with_conflicts_mariadb:Conflicts: mariadb-connector-c-devel}
%{?with_provides_community_mysql:Provides: community-mysql-devel = %community_mysql_version}
%{?with_provides_community_mysql:Provides: community-mysql-devel%{?_isa} = %community_mysql_version}
@ -481,7 +484,7 @@ Requires: perl(Sys::Hostname)
Requires: perl(Test::More)
Requires: perl(Time::HiRes)
%{?with_conflicts_mariadb:Conflicts: mariadb-test}
%{?with_conflicts_mariadb:Conflicts: mariadb-test-any}
%{?with_provides_community_mysql:Provides: community-mysql-test = %community_mysql_version}
%{?with_provides_community_mysql:Provides: community-mysql-test%{?_isa} = %community_mysql_version}
%{?with_obsoletes_community_mysql:Obsoletes: community-mysql-test <= %obsolete_community_mysql_version}
@ -661,7 +664,7 @@ rm -r %{buildroot}%{_tmpfilesdir}/mysql.conf
# We no longer enforce the hardcoded UID/GID 27
mkdir -p %{buildroot}%{_sysusersdir}
cat > %{buildroot}%{_sysusersdir}/%{name}.conf << EOF
u mysql - 'MariaDB and MySQL Server' %{dbdatadir} -
u mysql 27 'MariaDB and MySQL Server' %{dbdatadir} -
EOF
# helper scripts for service starting
@ -803,9 +806,6 @@ popd
%post -n %{pkgname}-server
%systemd_post %{daemon_name}.service
if [ ! -e "%{logfile}" -a ! -h "%{logfile}" ] ; then
install /dev/null -m0640 -omysql -gmysql "%{logfile}"
fi
%preun -n %{pkgname}-server
%systemd_preun %{daemon_name}.service
@ -993,12 +993,14 @@ fi
%{_tmpfilesdir}/%{daemon_name}.conf
%{_sysusersdir}/%{name}.conf
# Remember to also update the mysql.tmpfiles.d.in file when updating these permissions
%attr(0755,mysql,mysql) %dir %{dbdatadir}
%attr(0750,mysql,mysql) %dir %{_localstatedir}/lib/mysql-files
%attr(0700,mysql,mysql) %dir %{_localstatedir}/lib/mysql-keyring
%attr(0755,mysql,mysql) %dir %{pidfiledir}
%attr(0750,mysql,mysql) %dir %{logfiledir}
%attr(0640,mysql,mysql) %config %ghost %verify(not md5 size mtime) %{logfile}
%config(noreplace) %{logrotateddir}/%{daemon_name}
%if %{with devel}
@ -1118,6 +1120,24 @@ fi
%endif
%changelog
* Tue Nov 25 2025 Michal Schorm <mschorm@redhat.com> - 8.0.44-4
- Bump release for tmpfiles.d fixup
* Thu Nov 20 2025 Michal Schorm <mschorm@redhat.com> - 8.0.44-3
- Bump release for tmpfiles.d fixup
* Mon Nov 3 2025 Nikola Davidova <ndavidov@redhat.com> - 8.0.44-2
- Bump release for tmpfiles.d change
* Thu Oct 30 2025 Pavol Sloboda <psloboda@redhat.com> - 8.0.44-1
- Rebase to MySQL 8.0.44
* Mon Oct 27 2025 Lukas Javorsky <ljavorsk@redhat.com> - 8.0.43-2
- Revert to soft static allocation of MariaDB and MySQL sysusers.d files
* Wed Aug 06 2025 Pavol Sloboda <psloboda@redhat.com> - 8.0.43-1
- Rebase to MySQL 8.0.43
* Thu Apr 24 2025 Pavol Sloboda <psloboda@redhat.com> - 8.0.42-1
- Rebase to MySQL 8.0.42

View file

@ -44,3 +44,7 @@ main.subquery_sj_all_bka_nobnl : BUG#0 https://bugzilla.redhat.com/s
# Failing since 2025
main.time_zone : BUG#0
main.basedir : BUG#0
# Failing since 8.0.44
main.lock_backup : BUG#0
main.sdi_tablespace : BUG#0

View file

@ -50,3 +50,8 @@ main.multi_update : BUG#0
# Fails since 8.0.42
innodb_fts.optimize_big : BUG#0
# Fails since 8.0.44
main.join_cache_bnl : BUG#0
main.mysql : BUG#0
main.join_cache_nojb : BUG#0

View file

@ -1 +1 @@
SHA512 (mysql-boost-8.0.42.tar.gz) = 66776b5a1be603f215d4b227d395e72476bde76fdc0ba5ffdcfcb851a8261f1428c23c8abf1edca616765ee8254354e9092eaadde5ed43e7e2daa2ac265a0b23
SHA512 (mysql-boost-8.0.44.tar.gz) = f6881d6f88a4060796e1eac47c1ffe3ea005c27f1b0509fd97774ba5b1e7bf86d0f8c4e13126750f0cc3dd86af92c26459ae8fecf9e8f0f058dab43e93bb3b42