MySQL Enterprise Backup User's Guide (Version 8.0.36)

4.2.1 OS User for Running mysqlbackup

For Linux and other Unix-like platforms: mysqlbackup does not record file ownership or permissions of the files that are backed up. To ensure no file permission issues prevent a server to be backed up, restored, and restarted successfully, it is highly recommended that you run mysqlbackup with the same OS user who runs the MySQL server (typically mysql).

Note

For Linux and other Unix-like platforms, the mysql user was typically created using the -r and -s /bin/false options of the useradd command, so that it does not have login permissions to your server host (see Creating the mysql User and Group for details). To switch to the mysql user on your OS, use the --shell=/bin/bash option for the su command:

su - mysql --shell=/bin/bash

If it is not possible run mysqlbackup with the OS user mysql, pay attention to the following guidelines: