Managing MySQL Server with systemd •For some parameters,  override.conf  must be used because systemd itself must know their values and it cannot read MySQL option files to get them. •Parameters that specify values otherwise settable only using options known to  mysqld_safe  must be specified using systemd because there is no corresponding  mysqld  parameter. For additional information about using systemd rather than  mysqld_safe , see Migrating from mysqld_safe to systemd. You can set the following parameters in  override.conf : There are multiple ways to specify environment variable values for use by the MySQL server process managed by systemd: Some MySQL parameters are configured using environment variables: In MySQL 8.0,  mysqld  uses the  Type=notify  process startup type. ( Type=forking  was used in MySQL 5.7.) With  Type=notify , systemd automatically configures a socket file and exports the path to the  NOTIFY_SOCKET  environment variable. After modifying  /etc/sysconfig/mysql , restart the server to make the changes effective: To specify options for  mysqld  without modifying systemd configuration files directly, set or unset the MYSQLD_OPTS  systemd variable. For example: MYSQLD_OPTS  can also be set in the  /etc/sysconfig/mysql  file. 199 •To set the number of file descriptors available to the MySQL server, use  LimitNOFILE  in override.conf  rather than the  open_files_limit  system variable for  mysqld  or  --open-files- limit  option for  mysqld_safe . •To set the maximum core file size, use  LimitCore  in  override.conf  rather than the  --core-file- size  option for  mysqld_safe . •To set the scheduling priority for the MySQL server, use  Nice  in  override.conf  rather than the  -- nice  option for  mysqld_safe . • LD_PRELOAD : Set this variable if the MySQL server should use a specific memory-allocation library. • NOTIFY_SOCKET : This environment variable specifies the socket that  mysqld  uses to communicate notification of startup completion and service status change with systemd. It is set by systemd when the  mysqld  service is started. The  mysqld  service reads the variable setting and writes to the defined location. • TZ : Set this variable to specify the default time zone for the server. •Use  Environment  lines in the  override.conf  file. For the syntax, see the example in the preceding discussion that describes how to use this file. •Specify the values in the  /etc/sysconfig/mysql  file (create the file if it does not exist). Assign values using the following syntax: LD_PRELOAD= /path/to/malloc/library TZ= time_zone_setting systemctl restart mysqld # RPM platforms systemctl restart mysql # Debian platforms systemctl set-environment MYSQLD_OPTS="--general_log=1" systemctl unset-environment MYSQLD_OPTS