mariadb/mariadb.service.in

72 lines
2.1 KiB
SYSTEMD
Raw Permalink Normal View History

Accepting request 563119 from home:kstreitova:branches:server:database - update to 10.2.12 GA * release notes and changelog: https://mariadb.com/kb/en/library/mariadb-10212-release-notes/ https://mariadb.com/kb/en/library/mariadb-10212-changelog/ - remove mysql-community-server-5.5.6-safe-process-in-bin.patch becuase this moving is done in the specfile - get rid of the archive with patches (remove mysql-patches.tar.xz and series files), handle patches in the standard way - add comments to the section with removing unused files (based on https://lists.launchpad.net/maria-developers/msg11028.html) - put rm statements together - install the new upstream systemd-tmpfiles configuration file 'tmpfiles.conf' and rename it to 'mariadb.conf' in order to follow the manual - remove the new upstream systemd-sysusers configuration file as we handle creating of mysql user in the specfile - mysql.service: remove calling of the wait function and let systemd to do this job. Switch from 'Type=simple' to 'Type=notify' and add TimeoutSec=300 - rename unit files from mysql to mariadb and add mysql alias for the backward compatibility [bsc#1067443] * mysql.service -> mariadb.service * mysql.target -> mariadb.target * mysql@.service -> mariadb@.service - remove configuration-tweaks.tar.xz and move configuration to my.ini/my.cnf file (omit default_plugins.cnf as all configuration here was commented out) - add a numeric prefix for galera.cnf file in order to allow users to speficy in which order the configs will be loaded within the my.cnf.d directory [bsc#1055268] OBS-URL: https://build.opensuse.org/request/show/563119 OBS-URL: https://build.opensuse.org/package/show/server:database/mariadb?expand=0&rev=203
2018-01-09 19:28:29 +01:00
# It's not recommended to modify this unit file because your changes
# would be overwritten during the package update.
#
# However, there are 2 methods how to customize this unit file:
#
# 1) Copy this unit file from /usr/lib/systemd/system to
# /etc/systemd/system and modify the chosen settings.
#
# 2) Create a directory named mariadb.service.d/ within /etc/systemd/system
# and place a drop-in file name.conf there that only changes the specific
# settings one is interested in.
#
# see systemd.unit(5) for details
#
# Example - increasing of the TimeoutSec= limit
# mkdir /etc/systemd/system/mariadb.service.d
# cat > /etc/systemd/system/mariadb.service.d/timeout.conf << EOF
# [Service]
# TimeoutSec=600
# EOF
[Unit]
Description=MariaDB database server
Documentation=man:mysqld(8)
Documentation=https://mariadb.com/kb/en/library/systemd/
Accepting request 563119 from home:kstreitova:branches:server:database - update to 10.2.12 GA * release notes and changelog: https://mariadb.com/kb/en/library/mariadb-10212-release-notes/ https://mariadb.com/kb/en/library/mariadb-10212-changelog/ - remove mysql-community-server-5.5.6-safe-process-in-bin.patch becuase this moving is done in the specfile - get rid of the archive with patches (remove mysql-patches.tar.xz and series files), handle patches in the standard way - add comments to the section with removing unused files (based on https://lists.launchpad.net/maria-developers/msg11028.html) - put rm statements together - install the new upstream systemd-tmpfiles configuration file 'tmpfiles.conf' and rename it to 'mariadb.conf' in order to follow the manual - remove the new upstream systemd-sysusers configuration file as we handle creating of mysql user in the specfile - mysql.service: remove calling of the wait function and let systemd to do this job. Switch from 'Type=simple' to 'Type=notify' and add TimeoutSec=300 - rename unit files from mysql to mariadb and add mysql alias for the backward compatibility [bsc#1067443] * mysql.service -> mariadb.service * mysql.target -> mariadb.target * mysql@.service -> mariadb@.service - remove configuration-tweaks.tar.xz and move configuration to my.ini/my.cnf file (omit default_plugins.cnf as all configuration here was commented out) - add a numeric prefix for galera.cnf file in order to allow users to speficy in which order the configs will be loaded within the my.cnf.d directory [bsc#1055268] OBS-URL: https://build.opensuse.org/request/show/563119 OBS-URL: https://build.opensuse.org/package/show/server:database/mariadb?expand=0&rev=203
2018-01-09 19:28:29 +01:00
Conflicts=mariadb.target
After=network.target time-sync.target
Accepting request 563119 from home:kstreitova:branches:server:database - update to 10.2.12 GA * release notes and changelog: https://mariadb.com/kb/en/library/mariadb-10212-release-notes/ https://mariadb.com/kb/en/library/mariadb-10212-changelog/ - remove mysql-community-server-5.5.6-safe-process-in-bin.patch becuase this moving is done in the specfile - get rid of the archive with patches (remove mysql-patches.tar.xz and series files), handle patches in the standard way - add comments to the section with removing unused files (based on https://lists.launchpad.net/maria-developers/msg11028.html) - put rm statements together - install the new upstream systemd-tmpfiles configuration file 'tmpfiles.conf' and rename it to 'mariadb.conf' in order to follow the manual - remove the new upstream systemd-sysusers configuration file as we handle creating of mysql user in the specfile - mysql.service: remove calling of the wait function and let systemd to do this job. Switch from 'Type=simple' to 'Type=notify' and add TimeoutSec=300 - rename unit files from mysql to mariadb and add mysql alias for the backward compatibility [bsc#1067443] * mysql.service -> mariadb.service * mysql.target -> mariadb.target * mysql@.service -> mariadb@.service - remove configuration-tweaks.tar.xz and move configuration to my.ini/my.cnf file (omit default_plugins.cnf as all configuration here was commented out) - add a numeric prefix for galera.cnf file in order to allow users to speficy in which order the configs will be loaded within the my.cnf.d directory [bsc#1055268] OBS-URL: https://build.opensuse.org/request/show/563119 OBS-URL: https://build.opensuse.org/package/show/server:database/mariadb?expand=0&rev=203
2018-01-09 19:28:29 +01:00
[Install]
WantedBy=multi-user.target
Alias=mysql.service
Accepting request 563119 from home:kstreitova:branches:server:database - update to 10.2.12 GA * release notes and changelog: https://mariadb.com/kb/en/library/mariadb-10212-release-notes/ https://mariadb.com/kb/en/library/mariadb-10212-changelog/ - remove mysql-community-server-5.5.6-safe-process-in-bin.patch becuase this moving is done in the specfile - get rid of the archive with patches (remove mysql-patches.tar.xz and series files), handle patches in the standard way - add comments to the section with removing unused files (based on https://lists.launchpad.net/maria-developers/msg11028.html) - put rm statements together - install the new upstream systemd-tmpfiles configuration file 'tmpfiles.conf' and rename it to 'mariadb.conf' in order to follow the manual - remove the new upstream systemd-sysusers configuration file as we handle creating of mysql user in the specfile - mysql.service: remove calling of the wait function and let systemd to do this job. Switch from 'Type=simple' to 'Type=notify' and add TimeoutSec=300 - rename unit files from mysql to mariadb and add mysql alias for the backward compatibility [bsc#1067443] * mysql.service -> mariadb.service * mysql.target -> mariadb.target * mysql@.service -> mariadb@.service - remove configuration-tweaks.tar.xz and move configuration to my.ini/my.cnf file (omit default_plugins.cnf as all configuration here was commented out) - add a numeric prefix for galera.cnf file in order to allow users to speficy in which order the configs will be loaded within the my.cnf.d directory [bsc#1055268] OBS-URL: https://build.opensuse.org/request/show/563119 OBS-URL: https://build.opensuse.org/package/show/server:database/mariadb?expand=0&rev=203
2018-01-09 19:28:29 +01:00
[Service]
ExecStartPre=@LIBEXECDIR@/mysql/mysql-systemd-helper install
ExecStartPre=@LIBEXECDIR@/mysql/mysql-systemd-helper upgrade
ExecStart=@LIBEXECDIR@/mysql/mysql-systemd-helper start
Accepting request 563119 from home:kstreitova:branches:server:database - update to 10.2.12 GA * release notes and changelog: https://mariadb.com/kb/en/library/mariadb-10212-release-notes/ https://mariadb.com/kb/en/library/mariadb-10212-changelog/ - remove mysql-community-server-5.5.6-safe-process-in-bin.patch becuase this moving is done in the specfile - get rid of the archive with patches (remove mysql-patches.tar.xz and series files), handle patches in the standard way - add comments to the section with removing unused files (based on https://lists.launchpad.net/maria-developers/msg11028.html) - put rm statements together - install the new upstream systemd-tmpfiles configuration file 'tmpfiles.conf' and rename it to 'mariadb.conf' in order to follow the manual - remove the new upstream systemd-sysusers configuration file as we handle creating of mysql user in the specfile - mysql.service: remove calling of the wait function and let systemd to do this job. Switch from 'Type=simple' to 'Type=notify' and add TimeoutSec=300 - rename unit files from mysql to mariadb and add mysql alias for the backward compatibility [bsc#1067443] * mysql.service -> mariadb.service * mysql.target -> mariadb.target * mysql@.service -> mariadb@.service - remove configuration-tweaks.tar.xz and move configuration to my.ini/my.cnf file (omit default_plugins.cnf as all configuration here was commented out) - add a numeric prefix for galera.cnf file in order to allow users to speficy in which order the configs will be loaded within the my.cnf.d directory [bsc#1055268] OBS-URL: https://build.opensuse.org/request/show/563119 OBS-URL: https://build.opensuse.org/package/show/server:database/mariadb?expand=0&rev=203
2018-01-09 19:28:29 +01:00
Type=notify
User=mysql
Group=mysql
KillSignal=SIGTERM
# Don't want to see an automated SIGKILL ever
SendSIGKILL=no
# Restart crashed server only, on-failure would also restart, for example, when
# my.cnf contains unknown option
Restart=on-abort
RestartSec=5s
Accepting request 563119 from home:kstreitova:branches:server:database - update to 10.2.12 GA * release notes and changelog: https://mariadb.com/kb/en/library/mariadb-10212-release-notes/ https://mariadb.com/kb/en/library/mariadb-10212-changelog/ - remove mysql-community-server-5.5.6-safe-process-in-bin.patch becuase this moving is done in the specfile - get rid of the archive with patches (remove mysql-patches.tar.xz and series files), handle patches in the standard way - add comments to the section with removing unused files (based on https://lists.launchpad.net/maria-developers/msg11028.html) - put rm statements together - install the new upstream systemd-tmpfiles configuration file 'tmpfiles.conf' and rename it to 'mariadb.conf' in order to follow the manual - remove the new upstream systemd-sysusers configuration file as we handle creating of mysql user in the specfile - mysql.service: remove calling of the wait function and let systemd to do this job. Switch from 'Type=simple' to 'Type=notify' and add TimeoutSec=300 - rename unit files from mysql to mariadb and add mysql alias for the backward compatibility [bsc#1067443] * mysql.service -> mariadb.service * mysql.target -> mariadb.target * mysql@.service -> mariadb@.service - remove configuration-tweaks.tar.xz and move configuration to my.ini/my.cnf file (omit default_plugins.cnf as all configuration here was commented out) - add a numeric prefix for galera.cnf file in order to allow users to speficy in which order the configs will be loaded within the my.cnf.d directory [bsc#1055268] OBS-URL: https://build.opensuse.org/request/show/563119 OBS-URL: https://build.opensuse.org/package/show/server:database/mariadb?expand=0&rev=203
2018-01-09 19:28:29 +01:00
# Configures the time to wait for start-up/stop
TimeoutSec=300
# CAP_IPC_LOCK To allow memlock to be used as non-root user
# CAP_DAC_OVERRIDE To allow auth_pam_tool (which is SUID root) to read /etc/shadow when it's chmod 0
# does nothing for non-root, not needed if /etc/shadow is u+r
# CAP_AUDIT_WRITE auth_pam_tool needs it on Debian for whatever reason
CapabilityBoundingSet=CAP_IPC_LOCK CAP_DAC_OVERRIDE CAP_AUDIT_WRITE
# Prevent writes to /usr, /boot, and /etc
ProtectSystem=full
# Prevent accessing /home, /root and /run/user
ProtectHome=true
# Execute pre and post scripts as root, otherwise it does it as User=
PermissionsStartOnly=true
UMask=007