[MDEV-26734] wsrep_sst_mariabackup does not error that mariabackup is missing Created: 2021-09-30  Updated: 2023-03-03

Status: Open
Project: MariaDB Server
Component/s: wsrep
Affects Version/s: 10.4.21
Fix Version/s: 10.4, 10.5, 10.6

Type: Bug Priority: Minor
Reporter: Brendon Abbott Assignee: Julius Goryavsky
Resolution: Unresolved Votes: 0
Labels: None
Environment:

Actually running head of 10.4 branch whilst investigating an unrelated issue.



 Description   

Apologies if I had a little more time, I would have had a go at submitting an actual change.

Whilst investingating some other problem, I accidentally uninstalled mariabackup without realising. My wsrep join began failing. however, it is failing without the intended error.

Having looked at how other wsrep providers handle this, I see there is a method in `wsrep_sst_common` called `wsrep_check_programs`. I wasn't sure of this was an oversight, or if there was a specific reason mariabackup is checked using an alternative mechanism.

BACKUP_BIN="$(command -v mariabackup)"
if [ ! -x "$BACKUP_BIN" ]; then
    wsrep_log_error 'mariabackup binary not found in path'
    exit 42
fi

+ pcmd='pv -f -i 10 -N joiner -F '\''%N => Rate:%r Avg:%a Elapsed:%t %e Bytes: %b %p'\'''
+ declare -a RC
++ command -v mariabackup
+ BACKUP_BIN=
UKQA DB-02:/etc/mysql/conf.d# echo $?
1

In contrast, this is what wsrep_sst_rsync uses

wsrep_check_programs rsync


Generated at Thu Feb 08 09:47:32 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.