Accepting request 721764 from home:kstreitova:branches:server:database

- remove sql_mode from my.ini/my.cnf as NO_ENGINE_SUBSTITUTION and
  STRICT_TRANS_TABLES are already set by default from version
  10.2.4 [bsc#1144314]

- add mariadb-10.3.17-fix_ppc_build.patch to fix a compilation
  failure for ppc if ${CRC32_LIBRARY} target has no COMPILE_FLAGS
  yet. Then GET_TARGET_PROPERTY returns COMPILE_FLAGS-NOTFOUND,
  which doesn't work very well when it's later fed back into
  COMPILE_FLAGS.
- _constraints: increase the memory because of the ppc build
- adjust mysql-systemd-helper ("shutdown protected MySQL" section)
  so it checks both ping response and the pid in a process list
  as it can take some time till the process is terminated.
  Otherwise it can lead to "found left-over process" situation
  when regular mariadb is started [bsc#1143215]

OBS-URL: https://build.opensuse.org/request/show/721764
OBS-URL: https://build.opensuse.org/package/show/server:database/mariadb?expand=0&rev=236
This commit is contained in:
Martin Pluskal 2019-08-08 14:14:01 +00:00 committed by Git OBS Bridge
parent bc9a74f66d
commit 66949ef81c
6 changed files with 63 additions and 7 deletions

View File

@ -7,7 +7,7 @@
</conditions> </conditions>
<hardware> <hardware>
<physicalmemory> <physicalmemory>
<size unit="M">7000</size> <size unit="G">10</size>
</physicalmemory> </physicalmemory>
</hardware> </hardware>
</overwrite> </overwrite>

View File

@ -0,0 +1,27 @@
From 13e8f728ec83133b990ed21404cbac1d8a0bc74c Mon Sep 17 00:00:00 2001
From: Sergei Golubchik <serg@mariadb.org>
Date: Sun, 16 Jun 2019 01:25:03 +0200
Subject: [PATCH] compilation failure on ppc with -DCMAKE_BUILD_TYPE=Debug
if ${CRC32_LIBRARY} target has no COMPILE_FLAGS yet,
GET_TARGET_PROPERTY returns COMPILE_FLAGS-NOTFOUND, which
doesn't work very well when it's later fed back into COMPILE_FLAGS.
GET_PROPERTY() returns an empty string in this case.
---
extra/crc32-vpmsum/CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/extra/crc32-vpmsum/CMakeLists.txt b/extra/crc32-vpmsum/CMakeLists.txt
index 31c09a97d6af..b4adebdadf5a 100644
--- a/extra/crc32-vpmsum/CMakeLists.txt
+++ b/extra/crc32-vpmsum/CMakeLists.txt
@@ -2,7 +2,7 @@ ADD_CONVENIENCE_LIBRARY(${CRC32_LIBRARY} $<TARGET_OBJECTS:crc32c> $<TARGET_OBJEC
ADD_LIBRARY(crc32c OBJECT vec_crc32.c)
ADD_LIBRARY(crc32ieee OBJECT vec_crc32.c)
-GET_TARGET_PROPERTY(CFLAGS_CRC32_VPMSUM ${CRC32_LIBRARY} COMPILE_FLAGS)
+GET_PROPERTY(CFLAGS_CRC32_VPMSUM TARGET ${CRC32_LIBRARY} PROPERTY COMPILE_FLAGS)
SET_TARGET_PROPERTIES(crc32c crc32ieee PROPERTIES COMPILE_FLAGS "${CFLAGS_CRC32_VPMSUM} -maltivec -mvsx -mpower8-vector -mcrypto -mpower8-vector")
SET_TARGET_PROPERTIES(crc32ieee PROPERTIES COMPILE_DEFINITIONS "CRC32_FUNCTION=crc32ieee_vpmsum;CRC32_CONSTANTS_HEADER=\"crc32ieee_constants.h\"")
SET_TARGET_PROPERTIES(crc32c PROPERTIES COMPILE_DEFINITIONS "CRC32_FUNCTION=crc32c_vpmsum;CRC32_CONSTANTS_HEADER=\"crc32c_constants.h\"")

View File

@ -1,3 +1,25 @@
-------------------------------------------------------------------
Thu Aug 8 10:06:04 UTC 2019 - Kristyna Streitova <kstreitova@suse.com>
- remove sql_mode from my.ini/my.cnf as NO_ENGINE_SUBSTITUTION and
STRICT_TRANS_TABLES are already set by default from version
10.2.4 [bsc#1144314]
-------------------------------------------------------------------
Wed Aug 7 11:22:39 UTC 2019 - Kristyna Streitova <kstreitova@suse.com>
- add mariadb-10.3.17-fix_ppc_build.patch to fix a compilation
failure for ppc if ${CRC32_LIBRARY} target has no COMPILE_FLAGS
yet. Then GET_TARGET_PROPERTY returns COMPILE_FLAGS-NOTFOUND,
which doesn't work very well when it's later fed back into
COMPILE_FLAGS.
- _constraints: increase the memory because of the ppc build
- adjust mysql-systemd-helper ("shutdown protected MySQL" section)
so it checks both ping response and the pid in a process list
as it can take some time till the process is terminated.
Otherwise it can lead to "found left-over process" situation
when regular mariadb is started [bsc#1143215]
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Aug 2 10:32:48 UTC 2019 - Kristyna Streitova <kstreitova@suse.com> Fri Aug 2 10:32:48 UTC 2019 - Kristyna Streitova <kstreitova@suse.com>

View File

@ -77,6 +77,7 @@ Patch3: mariadb-10.1.1-mysqld_multi-features.patch
Patch7: mariadb-10.0.15-logrotate-su.patch Patch7: mariadb-10.0.15-logrotate-su.patch
Patch8: mariadb-10.2.4-fortify-and-O.patch Patch8: mariadb-10.2.4-fortify-and-O.patch
Patch9: mariadb-10.2.19-link-and-enable-c++11-atomics.patch Patch9: mariadb-10.2.19-link-and-enable-c++11-atomics.patch
Patch10: mariadb-10.3.17-fix_ppc_build.patch
# needed for bison SQL parser and wsrep API # needed for bison SQL parser and wsrep API
BuildRequires: bison BuildRequires: bison
BuildRequires: cmake BuildRequires: cmake
@ -333,6 +334,7 @@ find . -name "*.jar" -type f -exec rm --verbose -f {} \;
%patch7 %patch7
%patch8 %patch8
%patch9 -p1 %patch9 -p1
%patch10 -p1
cp %{_sourcedir}/suse-test-run . cp %{_sourcedir}/suse-test-run .

2
my.ini
View File

@ -59,8 +59,6 @@ server-id = 1
# ssl-cert=/etc/mysql/ssl/server-cert.pem # ssl-cert=/etc/mysql/ssl/server-cert.pem
# ssl-key=/etc/mysql/ssl/server-key.pem # ssl-key=/etc/mysql/ssl/server-key.pem
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
[mysqld_multi] [mysqld_multi]
mysqld = /usr/bin/mysqld_safe mysqld = /usr/bin/mysqld_safe
mysqladmin = /usr/bin/mysqladmin mysqladmin = /usr/bin/mysqladmin

View File

@ -126,12 +126,19 @@ mysql_upgrade() {
fi fi
# Shut down MySQL # Shut down MySQL
echo "Shuting down protected MySQL" echo "Shutting down protected MySQL"
kill "$(cat "$protected/mysqld.pid")" protected_pid=$(cat "$protected/mysqld.pid")
kill $protected_pid
for i in {1..30}; do for i in {1..30}; do
/usr/bin/mysqladmin --socket="$protected/mysql.sock" ping > /dev/null 2>&1 || break /usr/bin/mysqladmin --socket="$protected/mysql.sock" ping > /dev/null 2>&1
# Check both ping response and the pid in a process list as it can take some time till the process is terminated.
# Otherwise it can lead to "found left-over process" situation when regular mariadb is started.
if [[ $? -eq 1 ]] && ! ps -p $protected_pid > /dev/null 2>&1; then
break
fi
sleep 1
done done
/usr/bin/mysqladmin --socket="$protected/mysql.sock" ping > /dev/null 2>&1 && kill -9 "$(cat "$protected/mysqld.pid")" /usr/bin/mysqladmin --socket="$protected/mysql.sock" ping > /dev/null 2>&1 && kill -9 $protected_pid
# Cleanup # Cleanup
echo "Final cleanup" echo "Final cleanup"