Commit graph

1133 commits

Author SHA1 Message Date
Marko Mäkelä
eb6b521f1b Merge 10.6 into 10.9 2023-06-27 13:48:46 +03:00
Tuukka Pasanen
8171f9da87 MDEV-31423: Make sure that datadir is available with SySV-init script
Commit fixes Debian SySV-init script fail:
  /etc/init.d/mariadb: line 90: [: : integer expression expected
which happens if datadir is not changed in configuration which
makes it invisible when printing MariaDB config defaults.

Commit makes sure that there is some value if nothing else if in hand
use default /usr/lib/mysql or fail with correct error message if
directory is not present
2023-06-09 10:22:34 +10:00
Marko Mäkelä
223c2c5b9d Merge 10.6 into 10.9 2023-06-08 10:46:19 +03:00
Marko Mäkelä
6882eeabb0 MDEV-30483 fixup: Declare the test plugin for Debian 2023-06-08 09:23:01 +03:00
Marko Mäkelä
878a86f276 Merge 10.6 into 10.9 2023-06-07 14:32:46 +03:00
Tuukka Pasanen
30fb72ca6e MDEV-31331: Fix cut'n'paste variable name in Debian pre-inst script
There is unwanted cut'n'paste variable name in Debian pre-inst
script which causes:

df: '': No such file or directory
/var/lib/dpkg/tmp.ci/preinst: line 215: [: : integer expression expected

Rename variable to correct one and make check that that directory
or symlink really exists. If it does not then fail with error
and message.
2023-05-31 10:26:19 +10:00
Otto Kekalainen
ea66df2f45 Deb: Fix blocksize check to use $mysql_datadir/$datadir correctly
In commit f99a8918 this line was changed to not use awk, and new version
copied both to init file and preinst file but overlooking that they use
different variable names.

Also fix minor syntax issues to make Shellcheck happy.

All new code of the whole pull request, including one or several files
that are either new files or modified ones, are contributed under the
BSD-new license. I am contributing on behalf of my employer
Amazon Web Services, Inc.
2023-05-30 18:55:13 +10:00
Marko Mäkelä
2ec42f793d Merge 10.6 into 10.9 2023-05-19 15:11:06 +03:00
Tuukka Pasanen
f522b0f230 MDEV-30951: Fix small perlcritic and enable modern Perl
Add Modern Perl headers. Perl 5.16 is still fairly
old from 2012.

Enable UTF-8, warnings and make script 'strict'

Small fixes for perlcritic reported problems and some crashes

I/O layer ":utf8" used at line 268, column 16.  Use ":encoding(UTF-8)" to get strict validation.  (Severity: 5)
"return" statement with explicit "undef" at line 806, column 4.  See page 199 of PBP.  (Severity: 5)
"return" statement with explicit "undef" at line 6844, column 4.  See page 199 of PBP.  (Severity: 5)
"return" statement with explicit "undef" at line 7524, column 4.  See page 199 of PBP.  (Severity: 5)
"return" statement with explicit "undef" at line 7527, column 4.  See page 199 of PBP.  (Severity: 5)
"return" statement with explicit "undef" at line 7599, column 4.  See page 199 of PBP.  (Severity: 5)
"return" statement with explicit "undef" at line 7602, column 4.  See page 199 of PBP.  (Severity: 5)
Expression form of "eval" at line 7784, column 4.  See page 161 of PBP.  (Severity: 5)
Expression form of "eval" at line 7806, column 4.  See page 161 of PBP.  (Severity: 5)
Glob written as <...> at line 8016, column 25.  See page 167 of PBP.  (Severity: 5)
"return" statement followed by "sort" at line 9195, column 60.  Behavior is undefined if called in scalar context.  (Severity: 5)
Expression form of "eval" at line 9846, column 10.  See page 161 of PBP.  (Severity: 5)
2023-05-12 15:17:40 +01:00
Marko Mäkelä
2763f733ee Merge 10.8 into 10.9 2023-05-11 09:24:59 +03:00
Marko Mäkelä
1f1eaef0af Merge 10.6 into 10.8 2023-05-11 09:00:27 +03:00
Tuukka Pasanen
2740b657ce MDEV-31216: Make sure that lsof does not fail on install
Command lsof can fail on Debian install.
Revert logic more like old one to make sure that there is no failing
and still does don't boundce on shellcheck.
2023-05-09 08:55:05 +10:00
Tuukka Pasanen
50cdf0b5ea MDEV-30952: Reformat Debian pre- and postscripts if-clauses
Debian install scripts if-clauses are not formatted
as they should be. This commit formats Debian
Pre and Post script if-clauses.
2023-05-08 16:52:27 +10:00
Tuukka Pasanen
8febdfa342 MDEV-30952: Fix shellcheck problems on Debian scripts
Commit fixes several ShellCheck found problems in Debian
Pre- and Postscripts.

Debian script mariadb-server-10.6.postrm contains shellcheck
Fixed problems are:
  https://www.shellcheck.net/wiki/SC2166 -- Prefer [ p ] && [ q ] as [ p -a q...
  https://www.shellcheck.net/wiki/SC2006 -- Use $(...) notation instead of le...
  https://www.shellcheck.net/wiki/SC1091 -- Not following: /usr/share/debconf...

Debian script mariadb-server-10.6.postinst contains shellcheck
Fixed problems are:
  https://www.shellcheck.net/wiki/SC2129 -- Consider using { cmd1; cmd2; } >>...
  https://www.shellcheck.net/wiki/SC1091 -- Not following: /usr/share/debconf...
  https://www.shellcheck.net/wiki/SC1072 -- Expected test to end here (don't ...
  https://www.shellcheck.net/wiki/SC1073 -- Couldn't parse this test expressi...
  https://www.shellcheck.net/wiki/SC1009 -- The mentioned syntax error was in...

Debian script mariadb-server-10.6.preinst contains shellcheck
Fixed problems are:
  https://www.shellcheck.net/wiki/SC2231 -- Quote expansions in this for loop...
  https://www.shellcheck.net/wiki/SC2166 -- Prefer [ p ] && [ q ] as [ p -a q...
  https://www.shellcheck.net/wiki/SC2001 -- See if you can use ${variable//se...
  https://www.shellcheck.net/wiki/SC1091 -- Not following: /usr/share/debconf...
  https://www.shellcheck.net/wiki/SC1007 -- Remove space after = if trying to...
2023-05-08 16:52:27 +10:00
Tuukka Pasanen
7cbb45d1d4 MDEV-30952: Reformat Debian post and pre scripts
There is several misindentation inside Debian post and pre
installation scripts. False indentation with space
as indent space should be 2 and indentation with tabs.
2023-05-08 16:52:27 +10:00
Oleksandr Byelkin
cf56f2d7e8 Merge branch '10.8' into 10.9 2023-05-03 13:27:59 +02:00
Oleksandr Byelkin
f0f1f2de0e Merge branch '10.6' into 10.8 2023-05-03 11:33:57 +02:00
Tuukka Pasanen
5f3a4beb9d MDEV-31045: Update debian/rules to be in sync to MariaDB LTS 10.6
To make sure that PMEM problem does not happen again sync
10.9 and up debian/rules to make sure that they are not making
anymore problems with autobake-debs.sh
2023-05-02 16:37:01 +10:00
Daniel Black
d0a71e90b8 deb: sid - debian autobake
Deb-autobakes where failing with:

dh_missing: warning: usr/share/mysql/mysql-test/mysql-test-run exists in debian/tmp but is not installed to anywhere
dh_missing: warning: usr/share/mysql/mysql-test/mtr exists in debian/tmp but is not installed to anywhere
dh_missing: warning: usr/share/mysql/mysql-test/mariadb-test-run exists in debian/tmp but is not installed to anywhere
dh_missing: warning: usr/share/mysql/mysql-test/mysql-test-run.pl exists in debian/tmp but is not installed to anywhere

Add all to mariadb-test.install and remove mariadb-test.links
2023-04-27 17:12:22 +10:00
Marko Mäkelä
436d8ef6b5 Merge 10.8 into 10.9 2023-04-27 10:03:26 +03:00
Marko Mäkelä
bbd261bb2e Merge 10.6 into 10.8 2023-04-27 09:53:56 +03:00
Tuukka Pasanen
c5e50c48bb MDEV-30837: Remove usage of AWK in autobake-debs.sh
AWK is used in autobake-debs.sh for printing information
about created DEB packages.

This can be rewrite with bash inner commands read and echo.
2023-04-27 15:09:01 +10:00
Tuukka Pasanen
f99a891858 MDEV-30837: Remove usage of AWK from Debian init and postinst scripts
AWK in used in Debian SysV-init and postinst scripts to determine
is there enough space starting MariaDB database or create new
database to target destination.

These AWK scripts can be rewrited to use pure SH or help
using Coreutils which is mandatory for usage of MariaDB currently.

Reasoning behind this is to get rid of one very less used dependency
2023-04-27 15:09:01 +10:00
Marko Mäkelä
e3f6e1c92e Merge 10.8 into 10.9 2023-04-26 17:48:13 +03:00
Marko Mäkelä
c15c8ef3e3 Merge 10.6 into 10.8 2023-04-26 13:58:40 +03:00
Marko Mäkelä
818d5e4814 Merge 10.5 into 10.6 2023-04-25 13:10:33 +03:00
Marko Mäkelä
3c25077899 Merge 10.6 into 10.8 2023-04-24 15:59:23 +03:00
Oleksandr Byelkin
1d74927c58 Merge branch '10.4' into 10.5 2023-04-24 12:43:47 +02:00
Oleksandr Byelkin
3d27f6d7f4 Merge branch '10.3' into 10.4 2023-04-21 09:10:58 +02:00
Daniel Black
3b85e3dcc1 MDEV-30687: Make small facelifting to autobake-debs.sh (fix)
Appending to 'eatmydata' will obviously cause an executable that
doesn't exist. Use an array to create the entire executable.

Also while we are at it, check the fakeroot actually works before
using it.
2023-04-17 19:17:58 +10:00
Marko Mäkelä
44281b88f3 Merge 10.8 into 10.9 2023-04-14 11:32:36 +03:00
Marko Mäkelä
10147af9e5 Merge 10.6 into 10.8 2023-04-14 09:48:22 +03:00
Tuukka Pasanen
f2fde3f667 MDEV-30687: Make small facelifting to autobake-debs.sh
Currently autobake-debs.sh does not pass shellcheck
it fails making errors:

 * SC1091 when using shellcheck -x it needs to know where to
   find ./VERSION. As this is not needed we just specify it
   as /dev/null as mentioned in shellcheck documentation:
   https://www.shellcheck.net/wiki/SC1091

 * SC2086 make sure that there is no globbing or word splitting
   in dpkg-buidpackage string. This not big problem or about to happen
   but now extra parameter parsing is more Bash compliant with
   using array.
   Change BUILDPACKAGE_PREPEND to BUILDPACKAGE_DPKGCMD which holds
   'eatmydata' if it's available and needed 'dpkg-buildpackage'
   https://www.shellcheck.net/wiki/SC2086

Fix small script indentation problem.
2023-04-14 07:51:51 +08:00
Tuukka Pasanen
1e4eef5c17 MDEV-31045: Fix regression building on Ubuntu 18.04
Github PR #2424 regressed Ubuntu 18.04 building
other than x86_64 machines. Architecture that are
impacted are PPC64 and ARM64.
This was because of changes in debian/rules file
which caused removing dependency to package 'libpmem-dev'
and CMake which '-DWITH_PMEM' removing not working
correctly. Package libpmem-dev was removed but
it still required to have PMEM with CMake which.
Commit make change that -DWITH_PMEM is correctly removed
if it's not wanted.
2023-04-13 21:49:02 +08:00
Marko Mäkelä
1d1e0ab2cc Merge 10.6 into 10.8 2023-04-12 15:50:08 +03:00
Otto Kekäläinen
18342cd5e1 Deb: Add missing installation step to Salsa-CI job for 10.5 upgrades
Add vital missing step to MariaDB 10.5 upgrade job to actually install
the new binary being built. Without this the test was happily passing all
the time but actually not testing the upgrade.

Also stop using oneliner syntax for the install step to make the debugging
of failing installs/upgrades from build logs easier.

NOTE TO MERGERS: This commit is made on 10.6 branch and can be merged to
all later branches (10.7, 10.8, ..., 11.0). If/when some jobs break, they
will be fixed per branch on follow-up commits.
2023-04-01 23:18:51 -07:00
Otto Kekäläinen
ee68fe3272 Deb: Update Salsa-CI to use Bullseye instead of Sid
Tests that try to upgrade MariaDB 10.6 in Debian Sid can no longer work
properly on versions < 10.11 as MariaDB 10.11 in now Debian Sid.

Change RELEASE to use Bullseye and refactor builds and upgrade tests to
use primarily Bullseye, as it has MariaDB 10.5 and thus testing upgrades
to MariaDB 10.6 and higher can work. Add on new 'build sid' job to continue
at least on build on Sid as well, even though it is not tested in other
jobs.

Due to this many Sid specific workarounds are can also be dropped, and
since Bullseye is now used for everything, the old bullseye-backports jobs
are obsolete and removed.

Tests that upgrade MySQL in Sid to MariaDB are also removed, as no test
in Debian Sid with MariaDB < 10.11 can reliably work anymore.

Also disable reprotest as unnecessary on old branches, refactor the naming
of autobake-deb.sh and native Debian build jobs to be more clear.

NOTE TO MERGERS: This commit is made on 10.6 branch and can be merged to
all later branches (10.7, 10.8, ..., 11.0). If/when some jobs break, they
will be fixed per branch on follow-up commits.
2023-04-01 23:18:51 -07:00
Otto Kekäläinen
2a5763224e Deb: Sync Salsa-CI from Debian MariaDB 10.6
Compare to Debian packaging of MariaDB 1:10.6.11-2 release at commit
2934e8a795
and sync upstream everything that is relevant for upstream and safe
to import on a stable 10.6 release.

* Use OpenSSL 1.1 from Debian Snapshots
  0040c272bf
  Related: https://jira.mariadb.org/browse/MDEV-30322

* Prefer using bullseye-backports in mosts tests over buster-bpo
  daa827ecde

* Add new upgrade test for MySQL Community Cluster 8.0
  3c71bec9b7

* Enable automatic datadir move also on upgrades from MySQL.com packages
  4cbbcb7e56

* Update Breaks/Replaces
  2cab13d059

* Normalize apt-get and curl commands
  8754ea2578

* Standardize on using capitalized 'ON' in CMake build options
  938757a85a

* Apply wrap-and-sort -av and other minor tweaks and inline documentation

NOTE TO MERGERS: This commit is made on 10.6 branch and can be merged to
all later branches (10.7, 10.8, ..., 11.0).
2023-04-01 23:18:51 -07:00
Marko Mäkelä
fffa4b28a1 Merge 10.8 into 10.9 2023-03-17 06:58:33 +02:00
Marko Mäkelä
acf46b7b36 Merge 10.6 into 10.8 2023-03-16 18:11:37 +02:00
Marko Mäkelä
f169dfb41a Merge 10.5 into 10.6 2023-03-10 09:35:50 +02:00
Julius Goryavsky
1e58b8afc0 move alloca() definition from all *.h files to one new header file 2023-03-07 11:13:20 +01:00
Marko Mäkelä
0d55914d96 Merge 10.8 into 10.9 2023-02-16 10:25:34 +02:00
Marko Mäkelä
dbab3e8d90 Merge 10.6 into 10.8 2023-02-10 13:43:53 +02:00
Marko Mäkelä
6aec87544c Merge 10.5 into 10.6 2023-02-10 13:03:01 +02:00
Tuukka Pasanen
a9eb272f91 MDEV-30534: Remove EOL Debian version 9 (stretch) from autobake-deb.sh
Debian 9 has EOL July 6th, 2020. This commit cleans it up
from debian/autobake-deb.sh which is used to build official
versions of MariaDB
2023-02-08 15:31:59 +11:00
Salman Mohammadi
2a78c3ef6f MDEV-30509: mariadb-plugin-connect: introduce curl as recommends
in order to be able to retrieve files using REST queries. Otherwise,
`ERROR 1105 (HY000): Curl not installed.` will be thrown.
2023-01-31 16:20:55 +11:00
Marko Mäkelä
820ebcec86 Merge 10.8 into 10.9 2023-01-10 14:50:58 +02:00
Marko Mäkelä
92c8d6f168 Merge 10.7 into 10.8
The MDEV-25004 test innodb_fts.versioning is omitted because ever since
commit 685d958e38 InnoDB would not allow
writes to a database where the redo log file ib_logfile0 is missing.
2023-01-10 14:42:50 +02:00
Marko Mäkelä
8356fb68c3 Merge 10.6 into 10.7 2023-01-04 14:52:25 +02:00