A user has a very interesting setup where mysqld runs inside of a chroot jail. Inside the chroot jail, their instance's plugin dir is located at /lib/plugin/, but outside the chroot jail, the actual full path of this directory is located at /usr/local/mariadb/mariadb_base/lib/plugin/.
This user needed to use an encryption key manager plugin with mariabackup. The plugin is located in the system's plugin dir. mariabackup is running outside of the chroot jail, so this means it would be located at /usr/local/mariadb/mariadb_base/lib/plugin/. Therefore, when running the backup tool, the user provided the following argument:
Unfortunately, mariabackup ignored this parameter, and got plugin_dir from the server with the following statement:
The value of @@plugin_dir captured by this statement is not valid outside of the chroot jail, so this resulted in a failed backup.
If --plugin_dir is supplied on the command-line, do not use the value received from the server.