summaryrefslogtreecommitdiff
path: root/extra
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch '10.3' into 10.4bb-10.4-MDEV-23468Oleksandr Byelkin2020-12-251-0/+4
|\
| * Merge branch '10.2' into 10.3Oleksandr Byelkin2020-12-231-0/+4
| |\
| | * MDEV-22810 mariabackup does not honor open_files_limit from option during ↵Vlad Lesin2020-12-161-0/+4
| | | | | | | | | | | | | | | | | | | | | backup prepare open_files_limit option was processed only for --backup, but not for --prepare.
* | | Merge 10.3 into 10.4Marko Mäkelä2020-12-231-4/+1
|\ \ \ | |/ /
| * | Merge 10.2 into 10.3Marko Mäkelä2020-12-231-4/+1
| |\ \ | | |/
| | * MDEV-24340 Unique final message of InnoDB during shutdownbb-10.2-MDEV-24340Marko Mäkelä2020-12-041-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | innobase_space_shutdown(): Remove. We want this step to be executed before the message "InnoDB: Shutdown completed; log sequence number " is output by innodb_shutdown(). It used to be executed after that step. innodb_shutdown(): Duplicate the code that used to live in innobase_space_shutdown(). innobase_init_abort(): Merge with innobase_space_shutdown().
* | | Merge 10.3 into 10.4Marko Mäkelä2020-12-0110-127/+491
|\ \ \ | |/ /
| * | MDEV-22929 MariaBackup option to report and/or continue when corruption is ↵Vlad Lesin2020-12-011-2/+2
| | | | | | | | | | | | | | | | | | encountered Post-push Windows compilation errors fix.
| * | Merge 10.2 into 10.3Marko Mäkelä2020-12-0110-127/+491
| |\ \ | | |/
| | * MDEV-22929 MariaBackup option to report and/or continue when corruption is ↵Vlad Lesin2020-12-0110-127/+489
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | encountered The new option --log-innodb-page-corruption is introduced. When this option is set, backup is not interrupted if innodb corrupted page is detected. Instead it logs all found corrupted pages in innodb_corrupted_pages file in backup directory and finishes with error. For incremental backup corrupted pages are also copied to .delta file, because we can't do LSN check for such pages during backup, innodb_corrupted_pages will also be created in incremental backup directory. During --prepare, corrupted pages list is read from the file just after redo log is applied, and each page from the list is checked if it is allocated in it's tablespace or not. If it is not allocated, then it is zeroed out, flushed to the tablespace and removed from the list. If all pages are removed from the list, then --prepare is finished successfully and innodb_corrupted_pages file is removed from backup directory. Otherwise --prepare is finished with error message and innodb_corrupted_pages contains the list of the pages, which are detected as corrupted during backup, and are allocated in their tablespaces, what means backup directory contains corrupted innodb pages, and backup can not be considered as consistent. For incremental --prepare corrupted pages from .delta files are applied to the base backup, innodb_corrupted_pages is read from both base in incremental directories, and the same action is proceded for corrupted pages list as for full --prepare. innodb_corrupted_pages file is modified or removed only in base directory. If DDL happens during backup, it is also processed at the end of backup to have correct tablespace names in innodb_corrupted_pages.
* | | Merge 10.3 into 10.4Marko Mäkelä2020-11-033-2/+15
|\ \ \ | |/ /
| * | Merge branch '10.2' into 10.3Oleksandr Byelkin2020-10-303-2/+15
| |\ \ | | |/
| | * MDEV-24026: InnoDB: Failing assertion: os_total_large_mem_allocated >= size ↵Vlad Lesin2020-10-293-2/+15
| | | | | | | | | | | | | | | | | | | | | | | | upon incremental backup mariabackup deallocated uninitialized write_filt_ctxt.u.wf_incremental_ctxt in xtrabackup_copy_datafile() when some table should be skipped due to parsed DDL redo log record.
* | | Merge 10.3 into 10.4Marko Mäkelä2020-10-291-51/+102
|\ \ \ | |/ /
| * | Merge 10.2 into 10.3Marko Mäkelä2020-10-281-51/+102
| |\ \ | | |/
| | * MDEV-20755 InnoDB: Database page corruption on disk or a failed file read of ↵Vlad Lesin2020-10-231-51/+102
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | tablespace upon prepare of mariabackup incremental backup The problem: When incremental backup is taken, delta files are created for innodb tables which are marked as new tables during innodb ddl tracking. When such tablespace is tried to be opened during prepare in xb_delta_open_matching_space(), it is "created", i.e. xb_space_create_file() is invoked, instead of opening, even if a tablespace with the same name exists in the base backup directory. xb_space_create_file() writes page 0 header the tablespace. This header does not contain crypt data, as mariabackup does not have any information about crypt data in delta file metadata for tablespaces. After delta file is applied, recovery process is started. As the sequence of recovery for different pages is not defined, there can be the situation when crypt data redo log event is executed after some other page is read for recovery. When some page is read for recovery, it's decrypted using crypt data stored in tablespace header in page 0, if there is no crypt data, the page is not decryped and does not pass corruption test. This causes error for incremental backup --prepare for encrypted tablespaces. The error is not stable because crypt data redo log event updates crypt data on page 0, and recovery for different pages can be executed in undefined order. The fix: When delta file is created, the corresponding write filter copies only the pages which LSN is greater then some incremental LSN. When new file is created during incremental backup, the LSN of all it's pages must be greater then incremental LSN, so there is no need to create delta for such table, we can just copy it completely. The fix is to copy the whole file which was tracked during incremental backup with innodb ddl tracker, and copy it to base directory during --prepare instead of delta applying. There is also DBUG_EXECUTE_IF() in innodb code to avoid writing redo log record for crypt data updating on page 0 to make the test case stable. Note: The issue is not reproducible in 10.5 as optimized DDL's are deprecated in 10.5. But the fix is still useful because it allows to decrease data copy size during backup, as delta file contains some extra info. The test case should be removed for 10.5 as it will always pass.
* | | MDEV-23539: aws key plugin - fails to buildDaniel Black2020-10-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recent gcc/clang versions failed to compile the existing code. Updating a later upstream SDK version was simple and required only implementing a flush method. This was left blank as there was no strong requirement to keep the error log atomic or durable. Reviewed-by: wlad@mariadb.com The upstream SDK version added a flush method which was simple to complete.
* | | Merge 10.3 into 10.4Marko Mäkelä2020-10-221-2/+2
|\ \ \ | |/ /
| * | Merge 10.2 into 10.3Marko Mäkelä2020-10-221-2/+2
| |\ \ | | |/
| | * MDEV-21951: mariabackup SST fail if data-directory have lost+found directoryJulius Goryavsky2020-10-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To fix this, it is necessary to add an option to exclude the database with the name "lost+found" from processing (the database name will be checked by the check_if_skip_database_by_path() or by the check_if_skip_database() function, and as a result "lost+found" will be skipped). In addition, it is necessary to slightly modify the verification logic in the check_if_skip_database() function. Also added a new test galera_sst_mariabackup_lost_found.test
| | * MDEV-23982: Mariabackup hangs on backupMarko Mäkelä2020-10-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | MDEV-13318 introduced a condition to Mariabackup that can cause it to hang if the server goes idle after writing a log block that has no payload after the 12-byte header. Normal recovery in log0recv.cc would allow blocks with exactly 12 bytes of length, and only reject blocks where the length field is shorter than that.
* | | Fix the WolfSSL build on FreeBSDMarko Mäkelä2020-09-231-3/+3
| | | | | | | | | | | | | | | Port some CMake tweaks of commit 4adc1269cc2d487bb12f96b0827c4a74f1a05382 from 10.5.
* | | Merge 10.3 into 10.4Marko Mäkelä2020-09-211-3/+16
|\ \ \ | |/ / | | | | | | | | | | | | | | | We omit commit a3bdce8f1e268e3ac57644faf91c9c5ad43f5291 and commit a0e2a293bcc25fb10888fd00bd63bce04c195524 because they would make the test galera_3nodes.galera_gtid_2_cluster fail and disable it.
| * | Merge 10.2 into 10.3Marko Mäkelä2020-09-211-3/+16
| |\ \ | | |/
| | * MDEV-23711 fixup: GCC -Og -Wmaybe-uninitializedMarko Mäkelä2020-09-211-1/+1
| | |
| | * MDEV-23711 make mariabackup innodb redo log read error message more clearVlad Lesin2020-09-211-3/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | log_group_read_log_seg() returns error when: 1) Calculated log block number does not correspond to read log block number. This can be caused by: a) Garbage or an incompletely written log block. We can exclude this case by checking log block checksum if it's enabled(see innodb-log-checksums, encrypted log block contains checksum always). b) The log block is overwritten. In this case checksum will be correct and read log block number will be greater then requested one. 2) When log block length is wrong. In this case recv_sys->found_corrupt_log is set. 3) When redo log block checksum is wrong. In this case innodb code writes messages to error log with the following prefix: "Invalid log block checksum." The fix processes all the cases above.
* | | Merge 10.3 into 10.4Marko Mäkelä2020-09-211-1/+4
|\ \ \ | |/ /
| * | Merge 10.2 into 10.3Marko Mäkelä2020-09-211-1/+4
| |\ \ | | |/
| | * MDEV-19264 Better support MariaDB GTID for Mariabackup's --slave-info optionVlad Lesin2020-09-141-1/+4
| | | | | | | | | | | | | | | | | | Parse SHOW SLAVE STATUS output for the "Using_Gtid" column. If the value is "No", then old log file and position is backed up, otherwise gtid_slave_pos is backed up.
* | | MDEV-23663 - Add HAVE_INTEL_RDRAND flag for building WolfSSL, where appropiateVladislav Vaintroub2020-09-172-5/+15
| | |
* | | Merge 10.3 into 10.4Marko Mäkelä2020-08-201-4/+6
|\ \ \ | |/ /
| * | Merge 10.2 into 10.3Marko Mäkelä2020-08-201-4/+6
| |\ \ | | |/
| | * MDEV-23475 InnoDB performance regression for write-heavy workloadsMarko Mäkelä2020-08-191-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit fe39d02f51b96536dccca7ff89faf05e13548877 (MDEV-20638) we removed some wake-up signaling of the master thread that should have been there, to ensure a steady log checkpointing workload. Common sense suggests that the commit omitted some necessary calls to srv_inc_activity_count(). But, an attempt to add the call to trx_flush_log_if_needed_low() as well as to reinstate the function innobase_active_small() did not restore the performance for the case where sync_binlog=1 is set. Therefore, we will revert the entire commit in MariaDB Server 10.2. In MariaDB Server 10.5, adding a srv_inc_activity_count() call to trx_flush_log_if_needed_low() did restore the performance, so we will not revert MDEV-20638 across all versions.
| | * MDEV-23474 InnoDB fails to restart after SET GLOBAL innodb_log_checksums=OFFMarko Mäkelä2020-08-181-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Regretfully, the parameter innodb_log_checksums was introduced in MySQL 5.7.9 (the first GA release of that series) by mysql/mysql-server@af0acedd885eb7103e319f79d25fda7386ef1506 which partly replaced a parameter that had been introduced in 5.7.8 mysql/mysql-server@22ba38218e1d76c24f69b5a5595ad3bf5933acb0 as innodb_log_checksum_algorithm. Given that the CRC-32C operations are accelerated on many processor implementations (AMD64 with SSE4.2; since MDEV-22669 also on IA-32 with SSE4.2, POWER 8 and later, ARMv8 with some extensions) and by lookup tables when only generic SISD instructions are available, there should be no valid reason to disable checksums. In MariaDB 10.5.2, as a preparation for MDEV-12353, MDEV-19543 deprecated and ignored the parameter innodb_log_checksums altogether. This should imply that after a clean shutdown with innodb_log_checksums=OFF one cannot upgrade to MariaDB Server 10.5 at all. Due to these problems, let us deprecate the parameter innodb_log_checksums and honor it only during server startup. The command SET GLOBAL innodb_log_checksums will always set the parameter to ON.
* | | Merge 10.3 into 10.4, except MDEV-22543Marko Mäkelä2020-08-131-1/+1
|\ \ \ | |/ / | | | | | | Also, fix GCC -Og -Wmaybe-uninitialized in run_backup_stage()
| * | Merge 10.2 into 10.3Marko Mäkelä2020-08-131-1/+1
| |\ \ | | |/
| | * Fix GCC 10.2.0 -Og -Wmaybe-uninitializedMarko Mäkelä2020-08-111-1/+1
| | | | | | | | | | | | | | | | | | For some reason, GCC emits more -Wmaybe-uninitialized warnings when using the flag -Og than when using -O2. Many of the warnings look genuine.
* | | Merge 10.3 into 10.4Marko Mäkelä2020-07-311-6/+0
|\ \ \ | |/ /
| * | Merge 10.2 into 10.3Marko Mäkelä2020-07-311-6/+0
| |\ \ | | |/
| | * MDEV-20638 Remove the deadcode from srv_master_thread() and ↵Thirunarayanan Balathandayuthapani2020-07-231-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | srv_active_wake_master_thread_low() - Due to commit fe95cb2e40d73adbbe88efa0e7f48c055ccd042f (MDEV-16125), InnoDB master thread does not need to call srv_resume_thread() and therefore there is no need to wake up the thread. Due to the above patch, InnoDB should remove the following dead code. srv_check_activity(): Makes the parameter as in,out and returns the recent activity value innobase_active_small(): Removed srv_active_wake_master_thread(): Removed srv_wake_master_thread(): Removed srv_active_wake_master_thread_low(): Removed Simplify srv_master_thread() and remove switch cases, added the assert. Replace srv_wake_master_thread() with srv_inc_activity_count() INNOBASE_WAKE_INTERVAL: Removed
| * | Merge 10.2 into 10.3Marko Mäkelä2020-07-021-1/+1
| |\ \ | | |/
| | * Merge 10.1 into 10.2bb-10.2-mergeMarko Mäkelä2020-07-011-1/+1
| | |\
| | | * mtr: use env for perlDaniel Black2020-06-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On FreeBSD, perl isn't in /usr/bin, its in /usr/local/bin or elsewhere in the path. Like storage/{maria/unittest/,}ma_test_* , we use /usr/bin/env to find perl and run it.
| | | * mbstream: Remove duplicate definition of datasink_bufferMarko Mäkelä2020-04-151-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For some reason, when mbstream is compiled with GCC 10, ld will fail to link it due to a multiple definition of datasink_buffer. The code appears to have been like that since the very beginning. Let us remove the duplicate dummy definition.
* | | | MDEV-22983: Mariabackup's --help option disappearedOleksandr Byelkin2020-07-011-0/+6
| | | | | | | | | | | | | | | | return --help option
* | | | MDEV-22894: Mariabackup should not read [mariadb-client] option groupVlad Lesin2020-06-181-1/+1
| | | | | | | | | | | | | | | | from configuration files
* | | | MDEV-18215: mariabackup does not report unknown command line optionsVlad Lesin2020-06-142-94/+168
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MDEV-21298: mariabackup doesn't read from the [mariadbd] and [mariadbd-X.Y] server option groups from configuration files MDEV-21301: mariabackup doesn't read [mariadb-backup] option group in configuration file All three issues require to change the same code, that is why their fixes are joined in one commit. The fix is in invoking load_defaults_or_exit() and handle_options() for backup-specific groups separately from client-server groups to let the last handle_options() call fail on unknown backup-specific options. The order of options procesing is the following: 1) Load server groups and process server options, ignore unknown options 2) Load client groups and process client options, ignore unknown options 3) Load backup groups and process client-server options, exit on unknown option 4) Process --mysqld-args command line options, ignore unknown options New global flag my_handle_options_init_variables was added to have ability to invoke handle_options() for the same allowed options set several times without re-initialising previously set option values. --password value destroying is moved from option processing callback to mariabackup's handle_options() function to have ability to invoke server's handle_options() several times for the same possible allowed options set. Galera invokes wsrep_sst_mariabackup.sh with mysqld command line options to configure mariabackup as close to the server as possible. It is not known what server options are supported by mariabackup when the script is invoked. That is why new mariabackup option "--mysqld-args" is added, all unknown options that follow this option will be silently ignored. wsrep_sst_mariabackup.sh was also changed to: - use "--mysqld-args" mariabackup option to pass mysqld options, - remove deprecated innobackupex mode, - remove unsupported mariabackup options: --encrypt --encrypt-key --rebuild-indexes --rebuild-threads
* | | | Merge 10.3 into 10.4Marko Mäkelä2020-05-261-0/+1
|\ \ \ \ | |/ / /
| * | | Merge 10.2 into 10.3Marko Mäkelä2020-05-251-0/+1
| |\ \ \ | | |/ /
| | * | MDEV-22545: my_vsnprintf behaves not as in C standardOleksandr Byelkin2020-05-241-0/+1
| | | | | | | | | | | | | | | | Added parameter %T for string which should be visibly truncated.