Skip to content

Commit

Permalink
Merge 10.6 into 10.7
Browse files Browse the repository at this point in the history
  • Loading branch information
dr-m committed Jan 4, 2023
2 parents b5a54e8 + fe38d7c commit 8356fb6
Show file tree
Hide file tree
Showing 188 changed files with 3,169 additions and 2,297 deletions.
20 changes: 18 additions & 2 deletions .gitlab-ci.yml
Expand Up @@ -71,7 +71,7 @@ variables:
echo "$package"
rpm -qlpv "$package" | awk '{print $1 " " $3 "/" $4 " ." $9 " " $10 " " $11}' | sort -k 3
echo "------------------------------------------------"
done >> ../rpmlist-$CI_JOB_NAME-$CI_COMMIT_REF_SLUG.log
done >> "../rpmlist-$CI_JOB_NAME-$CI_COMMIT_REF_SLUG.log"
# CPackRPM lists contents in build log, so no need to show the output of this,
# just store it as a build artifact that can be downloaded and diffed against
# other builds to detect which files where added/removed/moved
Expand Down Expand Up @@ -182,7 +182,7 @@ fedora-sanitizer:
GIT_SUBMODULE_STRATEGY: normal
script:
- yum install -y yum-utils rpm-build openssl-devel clang
- yum install -y /usr/lib64/libasan.so.6.0.0 /usr/lib64/libtsan.so.0.0.0 /usr/lib64/libubsan.so.1.0.0
- yum install -y libasan libtsan libubsan
# This repository does not have any .spec files, so install dependencies based on Fedora spec file
- yum-builddep -y mariadb-server
- mkdir builddir; cd builddir
Expand Down Expand Up @@ -305,6 +305,8 @@ mysql-test-run:
stage: test
dependencies:
- fedora
needs:
- fedora
<<: *mysql-test-run-def
artifacts:
when: always # Also show results when tests fail
Expand All @@ -326,6 +328,8 @@ mysql-test-run-asan:
RESTART_POLICY: "--force-restart"
dependencies:
- "fedora-sanitizer: [-DWITH_ASAN=YES]"
needs:
- "fedora-sanitizer: [-DWITH_ASAN=YES]"
<<: *mysql-test-run-def
artifacts:
when: always # Also show results when tests fail
Expand All @@ -339,6 +343,8 @@ mysql-test-run-tsan:
RESTART_POLICY: "--force-restart"
dependencies:
- "fedora-sanitizer: [-DWITH_TSAN=YES]"
needs:
- "fedora-sanitizer: [-DWITH_TSAN=YES]"
<<: *mysql-test-run-def
allow_failure: true
artifacts:
Expand All @@ -353,6 +359,8 @@ mysql-test-run-ubsan:
RESTART_POLICY: "--force-restart"
dependencies:
- "fedora-sanitizer: [-DWITH_UBSAN=YES]"
needs:
- "fedora-sanitizer: [-DWITH_UBSAN=YES]"
<<: *mysql-test-run-def
allow_failure: true
artifacts:
Expand All @@ -367,6 +375,8 @@ mysql-test-run-msan:
RESTART_POLICY: "--force-restart"
dependencies:
- "fedora-sanitizer: [-DWITH_MSAN=YES]"
needs:
- "fedora-sanitizer: [-DWITH_MSAN=YES]"
<<: *mysql-test-run-def
allow_failure: true
artifacts:
Expand All @@ -379,6 +389,8 @@ rpmlint:
stage: test
dependencies:
- fedora
needs:
- fedora
script:
- yum install -y rpmlint
- rm -f rpm/*debuginfo* # Not relevant in this test
Expand All @@ -396,6 +408,8 @@ fedora install:
stage: test
dependencies:
- fedora
needs:
- fedora
script:
- rm -f rpm/*debuginfo* # Not relevant in this test
# Nothing provides galera-4 on Fedora, so this step fails if built with wsrep
Expand Down Expand Up @@ -429,6 +443,8 @@ fedora upgrade:
stage: test
dependencies:
- fedora
needs:
- fedora
script:
- dnf install -y mariadb-server
# Fedora does not support running services in Docker (like Debian packages do) so start it manually
Expand Down
6 changes: 6 additions & 0 deletions .gitmodules
@@ -1,19 +1,25 @@
[submodule "libmariadb"]
path = libmariadb
url = https://github.com/MariaDB/mariadb-connector-c.git
ignore = all
[submodule "storage/rocksdb/rocksdb"]
path = storage/rocksdb/rocksdb
url = https://github.com/facebook/rocksdb.git
ignore = all
[submodule "wsrep-lib"]
path = wsrep-lib
url = https://github.com/codership/wsrep-lib.git
branch = master
ignore = all
[submodule "extra/wolfssl/wolfssl"]
path = extra/wolfssl/wolfssl
url = https://github.com/wolfSSL/wolfssl.git
ignore = all
[submodule "storage/maria/libmarias3"]
path = storage/maria/libmarias3
url = https://github.com/mariadb-corporation/libmarias3.git
ignore = all
[submodule "storage/columnstore/columnstore"]
path = storage/columnstore/columnstore
url = https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
ignore = all
2 changes: 1 addition & 1 deletion CMakeLists.txt
Expand Up @@ -236,7 +236,7 @@ IF (WITH_MSAN)
MY_CHECK_AND_SET_COMPILER_FLAG("-fsanitize=memory -fsanitize-memory-track-origins -U_FORTIFY_SOURCE" DEBUG RELWITHDEBINFO)
ENDIF()

OPTION(WITH_GPROF "Enable profilingg with gprof" OFF)
OPTION(WITH_GPROF "Enable profiling with gprof" OFF)
IF (WITH_GPROF)
MY_CHECK_AND_SET_COMPILER_FLAG("-pg -g -no-pie -fPIC")
ENDIF()
Expand Down
2 changes: 1 addition & 1 deletion debian/additions/innotop/innotop
Expand Up @@ -4933,7 +4933,7 @@ sub noecho_password {
};

if ( $EVAL_ERROR ) {
die "Cannot read respose; is Term::ReadKey installed? $EVAL_ERROR";
die "Cannot read response; is Term::ReadKey installed? $EVAL_ERROR";
}
return $response;
}
Expand Down
4 changes: 2 additions & 2 deletions debian/additions/mariadb-report
Expand Up @@ -726,7 +726,7 @@ sub set_myisam_vals
{
print "set_myisam_vals\n" if $op{debug};

# should be moved elsewere
# should be moved elsewhere
$questions = $stats{'Questions'};

$key_read_ratio = sprintf "%.2f",
Expand Down Expand Up @@ -1376,7 +1376,7 @@ format QCACHE =
__ Query Cache _________________________________________________________
Memory usage @>>>>>> of @>>>>>> %Usage: @>>>>>
make_short($qc_mem_used, 1), make_short($vars{'query_cache_size'}, 1), perc($qc_mem_used, $vars{'query_cache_size'})
Block Fragmnt @>>>>>%
Block Fragment @>>>>>%
perc($stats{'Qcache_free_blocks'}, $stats{'Qcache_total_blocks'})
Hits @>>>>>> @>>>>>/s
make_short($stats{'Qcache_hits'}), t($stats{'Qcache_hits'})
Expand Down
8 changes: 7 additions & 1 deletion debian/mariadb-server-10.7.mariadb.init
Expand Up @@ -34,6 +34,12 @@ else
exit -1
fi

if [ ! -x /usr/bin/mariadbd-safe ]
then
log_failure_msg "/usr/bin/mariadbd-safe not found or executable! This SysV init script depends on it."
exit -1
fi

# priority can be overridden and "-s" adds output to stderr
ERR_LOGGER="logger -p daemon.err -t /etc/init.d/mariadb -i"

Expand Down Expand Up @@ -127,7 +133,7 @@ case "${1:-''}" in
test -e /run/mysqld || install -m 755 -o mysql -g root -d /run/mysqld

# Start MariaDB!
/usr/bin/mysqld_safe "${@:2}" 2>&1 >/dev/null | $ERR_LOGGER &
/usr/bin/mariadbd-safe "${@:2}" 2>&1 >/dev/null | $ERR_LOGGER &

for i in $(seq 1 "${MYSQLD_STARTUP_TIMEOUT:-30}"); do
sleep 1
Expand Down
2 changes: 1 addition & 1 deletion debian/mariadb-server-10.7.postinst
Expand Up @@ -155,7 +155,7 @@ EOF

# This is important to avoid dataloss when there is a removed
# mysql-server version from Woody lying around which used the same
# data directory and then somewhen gets purged by the admin.
# data directory and then somehow gets purged by the admin.
db_set mariadb-server/postrm_remove_database false || true

# Clean up old flags before setting new one
Expand Down
2 changes: 1 addition & 1 deletion debian/salsa-ci.yml
Expand Up @@ -402,7 +402,7 @@ build mariadbclient consumer Python-MySQLdb:
image: debian:${RELEASE}
script:
- *test-prepare-container
# Run each step separately to avoitda 800+ lines chunk that lacks the
# Run each step separately to avoid an 800+ line chunk that lacks the
# commands themselves printed and Gitlab-CI cutting off the output
- apt-get install -y pkg-config ./libmariadb-dev*.deb ./libmariadb3_*.deb ./mariadb-common*.deb
- pkg-config --cflags --libs mysqlclient # See what MySQLdb builds with
Expand Down
12 changes: 6 additions & 6 deletions debian/tests/smoke
Expand Up @@ -45,28 +45,28 @@ else
systemctl restart mariadb
fi

mysql <<EOT
mariadb <<EOT
CREATE DATABASE testdatabase;
CREATE USER 'testuser'@'localhost' identified by 'testpassword';
GRANT ALL ON testdatabase.* TO 'testuser'@'localhost';
EOT

mysql testdatabase <<EOT
mariadb testdatabase <<EOT
CREATE TABLE foo (bar INTEGER);
INSERT INTO foo (bar) VALUES (41);
EOT

result=$(echo 'SELECT bar+1 FROM foo;'|mysql --batch --skip-column-names --user=testuser --password=testpassword testdatabase)
result=$(echo 'SELECT bar+1 FROM foo;'|mariadb --batch --skip-column-names --user=testuser --password=testpassword testdatabase)
if [ "$result" != "42" ]; then
echo "Unexpected result" >&2
exit 1
fi

mysql --user=testuser --password=testpassword testdatabase <<EOT
mariadb --user=testuser --password=testpassword testdatabase <<EOT
DROP TABLE foo;
EOT

mysql <<EOT
mariadb <<EOT
DROP DATABASE testdatabase;
DROP USER 'testuser'@'localhost';
EOT
Expand Down Expand Up @@ -94,7 +94,7 @@ if [ "$(dpkg-architecture -qDEB_HOST_ARCH_BITS)" != 32 ] &&
LOG=/var/lib/mysql/#rocksdb/LOG
# XXX: The server may only be started during the install of
# mariadb-server-10.7, which happens before that of the plugin.
[ -e $LOG ] || mysql -e "INSTALL PLUGIN RocksDB SONAME 'ha_rocksdb';"
[ -e $LOG ] || mariadb -e "INSTALL PLUGIN RocksDB SONAME 'ha_rocksdb';"
# XXX: rocksdb_supported_compression_types variable does not report ZSTD.

# Print RocksDB supported items so test log is easier to debug
Expand Down
2 changes: 0 additions & 2 deletions extra/mariabackup/backup_copy.cc
Expand Up @@ -1483,8 +1483,6 @@ bool backup_start(CorruptedPages &corrupted_pages)
if (!write_galera_info(mysql_connection)) {
return(false);
}
// copied from xtrabackup. what is it needed for here?
write_current_binlog_file(mysql_connection);
}

if (opt_binlog_info == BINLOG_INFO_ON) {
Expand Down
8 changes: 6 additions & 2 deletions extra/mariabackup/backup_mysql.cc
Expand Up @@ -1444,14 +1444,18 @@ write_galera_info(MYSQL *connection)

if ((state_uuid == NULL && state_uuid55 == NULL)
|| (last_committed == NULL && last_committed55 == NULL)) {
msg("Failed to get master wsrep state from SHOW STATUS.");
result = false;
msg("Warning: failed to get master wsrep state from SHOW STATUS.");
result = true;
goto cleanup;
}

result = backup_file_printf(XTRABACKUP_GALERA_INFO,
"%s:%s\n", state_uuid ? state_uuid : state_uuid55,
last_committed ? last_committed : last_committed55);
if (result)
{
write_current_binlog_file(connection);
}

cleanup:
free_mysql_variables(status);
Expand Down

0 comments on commit 8356fb6

Please sign in to comment.