There is no need for MariaDB Backup to be versioned. Other packages are
very unlikely to need to depend on a certain generation of this package.
Also for MariaDB Backup to run, it does not need the server, but client,
and from client only core parts.
It will only build if there is network access, which is a strict no-go
for Linux distributions. Thus the AWS plugin needs to be a custom built
only special plugin that is not built as part of the normal sources.
This fixes the build error in e.g. Launchpad:
Performing download step (git clone) for 'aws_sdk_cpp'
cd "/<<PKGBUILDDIR>>/builddir/plugin/aws_key_management" && /usr/bin/cmake ..
Cloning into 'aws-sdk-cpp'...
fatal: unable to access 'https://github.com/awslabs/aws-sdk-cpp.git/':
Could not resolve host: github.com
RocksDB configure step checks that platform is 64-bit and little endian,
so limit the .deb packages to be built only on those platforms.
List of official Debian platforms at
https://www.debian.org/ports/index.en.html
A non-MariaDB.org contributor introduced the epoch 1: in Debian.
There is no way to revert it, so we just need to adapt to it to
ensure no 10.3 installation would downgrade to that version in
Debian/Ubuntu, as 1: is considered higher than any version before.
There was a lot of files generated by the sources that were not installed
in any package. This fixes most of those issues, but not all. Files still
outside any package are in the not-installed, which is used by dh_install.
Also make sure all configuration files are installed to the correct
location that matches layout used by Debian official packages.
Matching libmariadb-dev package contents in official Debian repositories,
the MariaDB Connector/C files should go into a folder using the 'mariadb'
name. For compatibility with sources that expect to find 'mysql' stuff,
create a symlink from include/mysql to include/mariadb.
Using this package any source that expects MySQL Client libraries should
build without changes. Sources that expect MariaDB Connector C should
build using only libmariadb-dev.
Current MariaDB Connector/C does not build quite identically in
this source tree compared to how it build in Debian official.
The remaining differences are tracked in MDEV-14921.
We already ship libmysqlclient18 that replaces any existing package
with the same name and install symlinks that point to out libmariadb.so.
Instead of creating more packages, we add just one more that does the
same and provides both libmysqlclient19 and -20 replacements symlinks.
This is a clean solution, because systems that only use (and are built
against) libmariadb will not need them and if somebody has done a mistake
in the linker parameters, they will spot it and can easily update the
filename to libmariadb.
- tokuft_logprint should be shipped in the TokuDB plugin
- mysql_install_db is needed for installing/upgrading the datadir
so it must be in the server core package so users can roll their
own upgrades
There is no point in having version suffixes in plugin packages. They
will via their control file anyway depend on the correct server or client
version. Having version suffices has no benefit and it just complicates
upgrades when a new major version name package needs to replace all
possible previous version.
This issue was overlooked when merging commit
844a575946 from 10.2 into 10.3, so it
needs to be manually fixed now.
The correct format for new Debian packages is to define install lists
as *.install files. This has already been fixed for 10.3, but it when
merging commit c5a525bda2 from 10.2, this
change was overlooked and a file of the old format slipped in.
The libmariadb-dev package must include this directory so that downstream
developers can intentionally include MariaDB libraries as they want.
This matches the contents of the official Debian libmariadb-dev package.
TokuDB and Mroonga are not built on Travis CI to save time. Previously
their packages were not created due to a hack in debian/rules, that got
removed in commit 9631d933fb. This change complements that commit.
Part of MDEV-13073 AliSQL Optimize performance of semisync
Did the following renames to match other similar variables
key_ss_mutex_LOCK_binlog_ > key_LOCK_bing
key_ss_cond_COND_binlog_send_ -> key_COND_binlog_send
COND_binlog_send_ -> COND_binlog_send
LOCK_binlog_ -> LOCK_binlog
debian/mariadb-server-10.2.install does not install semisync libs.
The Debian packaging build was failing on Travis-CI due to timeouts.
These changes make it faster by skipping less relevant parts of the build,
like the test suite, RocksDB, TokuDB and Mroonga.
Also fix the usage of the 'make -j' flag to not have any spaces as
recommended in an example in the Debian policy.
mariadb-client-core-10.2, mariadb-client-10.2, and
mariadb-server-core-10.2 should not depend on libmariadb3 - they
do not have any binaries dynamically linked with libmariadb3.so
The symlink
/usr/lib/libmysqlclient.so -> /usr/lib/libmysqlclient.so.18
was invalid, because the library was not in /usr/lib.
The correct symlink is
/usr/lib/x86_64-linux-gnu/libmysqlclient.so -> /usr/lib/x86_64-linux-gnu/libmysqlclient.so.18
put libmariadbclient18 symlinks into libmariadbclient18.deb package,
not into libmariadb3.deb, because installing/reinstalling
libmariadbclient18.deb must recreate these symlinks.
For running the Galera tests, the variable my_disable_leak_check
was set to true in order to avoid assertions due to memory leaks
at shutdown.
Some adjustments due to MDEV-13625 (merge InnoDB tests from MySQL 5.6)
were performed. The most notable behaviour changes from 10.0 and 10.1
are the following:
* innodb.innodb-table-online: adjustments for the DROP COLUMN
behaviour change (MDEV-11114, MDEV-13613)
* innodb.innodb-index-online-fk: the removal of a (1,NULL) record
from the result; originally removed in MySQL 5.7 in the
Oracle Bug #16244691 fix
377774689b
* innodb.create-index-debug: disabled due to MDEV-13680
(the MySQL Bug #77497 fix was not merged from 5.6 to 5.7.10)
* innodb.innodb-alter-autoinc: MariaDB 10.2 behaves like MySQL 5.6/5.7,
while MariaDB 10.0 and 10.1 assign different values when
auto_increment_increment or auto_increment_offset are used.
Also MySQL 5.6/5.7 exhibit different behaviour between
LGORITHM=INPLACE and ALGORITHM=COPY, so something needs to be tested
and fixed in both MariaDB 10.0 and 10.2.
* innodb.innodb-wl5980-alter: disabled because it would trigger an
InnoDB assertion failure (MDEV-13668 may need additional effort in 10.2)
- make re-bootstrap run with all extra options, not only InnoDB ones
- re-use previously created bootstrap.sql
- add --console
- fix debian patch to keep it applicable
The XtraDB storage engine was already replaced by InnoDB
and disabled in MariaDB Server 10.2. Let us remove it altogether
to avoid dragging dead code around.
Replace some references to XtraDB with references to InnoDB.
rpl_get_position_info(): Remove.
Remove the mysql-test-run --suite=percona, because it only contains
tests specific to XtraDB, many of which were disabled already in
earlier MariaDB versions.
This excludes MDEV-12472 (InnoDB should accept XtraDB parameters,
warning that they are ignored). In other words, MariaDB 10.3 will not
recognize any XtraDB-specific parameters.
* Update debian control file to include AWS key management plugin.
* Update dependencies in control file to include uuid.
* Include enable_encryption.preset with the aws-key-management plugin.
Also, include fixes by Vladislav Vaintroub to the
aws_key_management plugin. The AWS C++ SDK specifically depends on
OPENSSL_LIBRARIES, not generic SSL_LIBRARIES (such as YaSSL).
Aptitude provided the following error message without this fix:
mariadb-client-core-10.3 :
Conflicts: mysql-client-5.1 which is a virtual package, provided by:
- mariadb-client-10.3, but 10.3.0+maria~xenial is to be installed.
Conflicts: mysql-client-5.5 which is a virtual package, provided by:
- mariadb-client-10.3, but 10.3.0+maria~xenial is to be installed.
* Rename all files to use 10.3 in the filename
* Adjust rules to delete extra lines from control file
* Adjust control file to have correct Replaces/Breaks list for each
package
* Add libcurl3-dev as build dependency for mariadb server in debian
Compatibility links ended up looking like this:
libmysqlclient.so.18 -> /tmp/buildd/mariadb-10.2-10.2.0/debian/tmp/usr/lib/i386-linux-gnu/libmariadb.so.3
This change fixes ln syntax to create links with correct target paths.
To facilitate multiple build types in Travis, the environment variable
MYSQL_{BUILD_CC,BUILD_CXX} will be passed to cmake if used. This will
fallback to $CC/$CXX otherwise.
Added MYSQL_COMPILER_LAUNCHER (usually ccache) which isn't supported
until cmake-3.4, which isn't in travis (trusty), but hopefully a later
version can use it or in CI systems other than travis.
Signed-off-by: Daniel Black <daniel.black@au.ibm.com>
Rotating binary/relay logs can cause interuption to the processing
on the server. Binary and relay logs have their own mechanism already
for not getting out of control (expire_logs_days).
By no longer rotating binary and relay logs log rotation is limited to
the following logs:
* error log
* general log
* slow query log
Writing these to the binary log would cause any logrotation on the
slave to occur twice, once due to this and another due to the log-
rotate script on the slave. Now --local is passed to mysqladmin to
prevent this duplication.
In Debian, the default install is made more secure by omitting the anonymous
user and by making the root account authenticate by unix socket
authentication instead of the default password-less root. However, Debian
hard-codes this change in mysql_install_db, which breaks that program for
other users.
This commit instead implements new general options for mysql_install_db that
can be used by anyone to similarly perform a more secure install:
--skip-auth-anonymous-user: omits the anonymous user.
--auth-root-authentication-method=normal: Keeps the existing behaviour
with a password-less root account. Currently on by default.
--auth-root-socket-user=USER
--auth-root-authentication-method=socket: creates the MariaDB root user
with the name USER (defaults to 'root') and using unix socket
authentication. This way, only that user has MariaDB root access
after install.
The idea with --auth-root-authentication-method=normal is that
applications that need this behaviour can give that option explicitly.
Then eventually we could make --auth-root-authentication-method=socket
the default, giving a more secure default installation.
Note that it is perfectly possible to do a secure install with
--auth-root-authentication-method=normal. For example, installing a
private server just for local access by a single OS-level user, by
using --skip-networking and putting the connection socket in a
location without public access. So it is important to preserve this
API for backwards compatibility.
* Update mysqld_safe script to remove duplicated parameter --crash-script
* Make --core-file-size accept underscores as well as dashes correctly.
* Add mysqld_safe_helper to Debian and Ubuntu files.
* Update innodb minor version to 35
For backwards compatibility reasons.
E.g. innotop builds against libmysqlclient.so and expects to find
a libmysqlclient.so.18 library and does not use libmariadb.so.3 even
when built from our own sources.
This commit mimics to dcfe6cb834
This is required, as the innochecksum binary has moved package.
Without this change the following error would be emitted:
Unpacking mariadb-server-core-10.2 (10.2.3+maria~jessie) over (10.2.2+maria-1~jessie) ...
dpkg: error processing archive /var/cache/apt/archives/mariadb-server-core-10.2_10.2.3+maria~jessie_amd64.deb (--unpack):
trying to overwrite '/usr/bin/innochecksum', which is also in package mariadb-client-10.2 10.2.2+maria-1~jessie
Quite often in upgrades on systemd systems dpkg emitted an error like:
Failed to stop mysql.service: Unit mysql.service not loaded.
invoke-rc.d: initscript mysql, action "stop" failed.
invoke-rc.d returned 5
There is a MySQL server running, but we failed in our attempts to stop it.
Stop it yourself and try again!
dpkg: error processing archive /var/cache/apt/archives/mariadb-server-10.2
This is because the mariadb/mysql.service file is not loaded during
the upgrade/unpack stage of dpkg in certain situations. With this simple
check we can easily skip the shutdown step when it is really not needed,
which is for sure the case if no mysqld process at all is running on the
entire system.
In Debian many existing applications in Debian/Ubuntu have been built
while libmariadbclient-dev or libmariadbclient-dev-compat was installed.
To satisfy installation dependencies, the package name libmariadbclient18
must be provided, and at runtime a shared library must by the name
libmariadbclient.so.18.
Provide these to remain backwards compatible.
The new library name libmariadb3 matches the libmariadb.so.3 filename.
Packages that want to build against MariaDB Connector C have as
build-dependency libmariadb-dev and as run-time dependency libmariadb3.
Make the package provide libmariadbclient18 for backwards compatibility,
though compatibility is not always assured. There library did change
to a whole new generation after all, even though ABI compatibility has
been a design goal.
Also do the equivalent change for the -dev package. Packages that
explicitly want to use the MariaDB Connector C should mark it as
their build-depends.
Also provide an empty libmariadbclient18 metapackage to facilitate
upgrades from old MariaDB installs, just like there is an empty
libmysqlclient18 package. Create more of these in the future as needed.
Since Debian 9 (Stretch) and Ubuntu 16.10 (Yakkety) the following
packages have existed:
* virtual-mysql-client
* virtual-mysql-client-core
* virtual-mysql-server
* virtual-mysql-server-core
* virtual-libmysqlclient-dev
They are metapackages that in Debian depend on MariaDB and in
Ubuntu currently on MySQL. We need to provide them and point
them to MariaDB so that systems that have the mariadb.org
repositories enabled automatically get everything MariaDB
and not MySQL.
This change makes the packaging provide the four first ones,
and later commits will fix the client library issues.
libmariadbd19 was intended to be added as the package that
included the libmysqld shared library. This was missing
from the debian control file.
The libmariadbd-dev package requires libmariadbd19 to provide
the shared library.
The shared libraries for embedded mysql will go into the libmariadbd18
package rather than the libmariadbd-dev development package.
/usr/bin/mariadb_config is a executable that assists embedded developers
to use the correctly correct header and library files during their
development.
Signed-off-by: Daniel Black <daniel.black@au.ibm.com>
Previously private/*.h where included in the package. These represent internal
mysqld structures that aren't guarenteed to provide a stable ABI.
There aren't intended to be used by embedded mysqld applications so
they have been removed.
Signed-off-by: Daniel Black <daniel.black@au.ibm.com>
The control file contents must be correct from the start and cannot
be modified at build time by CMake. Also all static Debian package
analyzers will fail to see all manipulations by CMake later on.
It is best to do all manipulations like these in autobake-deb.sh.
The build must stay under the Travis-CI 50 minute limit. Currently
they often exceed, and the huge test suite is the single most long
step in moving/packaging files, so remove it on Travis-CI automatically.
Also sort control file slightly to be easier to compare to downstream
control file and include gdb for automatic backtraces if the test suite
fails.
Delete duplicate man page installation.
Make mariadb-test breaks/replaces mariadb-server-5.5
as /usr/lib/mysql/plugin/adt_null.so changed package.
For Debian the rules file is the main makefile and assuming that a upstream
makefile will mangle the Debian packaging files creates false alerts
from static analysis tools and other problems.
There is no need for a separate mariadb-test metapackage and a versioned
mariadb-test-* package. Simply make it versionless and make it depend on
the client and server packages that stem from same source version.
These changes update the contents and behaviour of current packages
to match the current packaging in Debian official repos.
Keep mtr test scope small.
Updating maintainer scripts also required regenerating the translations.
Rules based on modern dh_* buildtools.
Update control file with new Debian conventions:
- Provide virtual-mysql-* virtual packages
- Recommends perl modules instead of Depends
Now we check if a dependency is available and not just if older versions
are available. Also use correct name of libcrack2 to actually detect it.
Use sed to inject dependency at the end of the dependency list.
Otherwise keep the control line clean and parseable by Debian tools.
- All build-depends should be in one place.
- Library packages should depend on their main package using strict version.
- Most packages should depend on the misc variable, so that debhelper
can fill in it with various calculated dependencies automatically.
- All packages using dynamic libraries should depend on the shlibs variable
to include shared libraries as dependencies automatically.
- Essential tools like bsdutils, grep and tar shall not be defined in vain.
When acting as a Galera receiver node, server startup may take
more than 30 secs (the current default) as it has to wait for
SST/IST operation to complete besides spending some time doing
wsrep recovery.
Fixed by raising the default value of MYSQLD_STARTUP_TIMEOUT
to 60 secs. Also sourced /etc/default/mariadb into the init
script so that it can be used to set MYSQLD_STARTUP_TIMEOUT.
Logrotate script assumed an error if mysqladmin failed to connect to server
and there's mysqld process exists. However there can be non-system instance of
mysqld running (e.g. in docker) making this assumption wrong.
Check pid file existance instead.