[MDEV-14884] Failed to enable encryption of temporary files in mariadb 10.3.3 Created: 2018-01-07  Updated: 2021-01-12  Resolved: 2021-01-12

Status: Closed
Project: MariaDB Server
Component/s: Encryption
Affects Version/s: 10.1, 10.3.3, 10.2
Fix Version/s: 10.2.37, 10.3.28, 10.4.18, 10.5.9

Type: Bug Priority: Major
Reporter: atomd Assignee: Sergei Golubchik
Resolution: Fixed Votes: 2
Labels: None


 Description   

I want to use rest encryption and set encrypt-tmp-files in the config file, and encounter the following error:

mariadb_1  | ERROR: mysqld failed while attempting to check config
mariadb_1  | command was: "mysqld --verbose --help --log-bin-index=/tmp/tmp.5KIX2Ab1Oo"
mariadb_1  |
mariadb_1  | 2018-01-07  8:58:45 0 [Note] Plugin 'FEEDBACK' is disabled.
mariadb_1  | 2018-01-07  8:58:45 0 [Warning] Could not open mysql.plugin table. Some options may be missing from the help text
mariadb_1  | 2018-01-07  8:58:45 0 [ERROR] Failed to enable encryption of temporary files
mariadb_1  | 2018-01-07  8:58:45 0 [ERROR] Aborting

config file is:

[mysqld]
 
plugin-load-add = file_key_management
file-key-management-filename = /mnt/keys/keys.enc
file_key_management_filekey = secret
file_key_management_encryption_algorithm = AES_CTR
 
innodb-encrypt-tables
innodb-encrypt-log
innodb-encryption-threads = 4
innodb-tablespaces-encryption
 
aria-encrypt-tables
encrypt_binlog
encrypt-tmp-files
encrypt-tmp-disk-tables = 1

I run mariadb(10.3.3) in docker. when I set encrypt-tmp-files = 0, everything is fine.
How can I fix it?



 Comments   
Comment by Elena Stepanova [ 2018-01-07 ]

I assume that mysqld --verbose --help does need to create a temporary file, but nothing else, hence the problem with this option specifically.

The warning about plugin table is irrelevant to this.

Comment by Doug Cain [ 2018-06-06 ]

Same issue with 10.2.11 when using the file-key-management plugin. Works as expected with the AWS KMS plugin though.

Comment by Dario Seidl [ 2021-01-12 ]

There is a fix for this in the MariaDB docker image: https://github.com/docker-library/mariadb/issues/339

Generated at Thu Feb 08 08:17:01 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.