mysqld-systemd error when MySQL error-log doesn't exist in Centos/RHEL7

Bug #1724811 reported by Iwo on 2017-10-19
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona XtraDB Cluster moved to

Bug Description

If MySQL error-log doesn't exist a MySQL restart will cause mysqld-systemd to throw an error:

    mysql-systemd[5691]: install: invalid user â@MYSQLD_USER@â

There's an unreplaced variable @MYSQLD_USER@ in mysqld-systemd script:

   # If log file is not specified it's put into datadir by default
    if [ ! -z $log ]; then
        if [ ! -e "$log" -a ! -h "$log" -a x$(dirname "$log") = "x/var/log" ]; then
            case $(basename "$log") in
                mysql*.log) install /dev/null -m0640 -o@MYSQLD_USER@ -g@MYSQLD_USER@ "$log" ;;
                *) ;;
        if [ -x /usr/sbin/restorecon ]; then
            [ -e "$log" ] && /usr/sbin/restorecon $log

The problem occurs only in PXC 5.7 (I've tested it against 5.7.19-29.22.1.el7) on Centos/RHEL 7.

Przemek (pmalkowski) on 2017-10-19
tags: added: i209060
Iwo (percona.imp) wrote :

The workaround for this issue is to change log-error directive in MySQL's configuration to other directory (for example, MySQL's data directory) or create an empty file with correct owner and group.

Changed in percona-xtradb-cluster:
assignee: nobody → EvgeniyPatlan (evgeniy-patlan)

Percona now uses JIRA for bug reports so this bug report is migrated to:

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers