From 043bf5a94115b605745de93ec316566f852cb6b3 Mon Sep 17 00:00:00 2001 From: Rickard Nilsson <rickynils@gmail.com> Date: Wed, 19 Mar 2014 08:38:31 +0100 Subject: [PATCH] mysql service: Shutdown with normal systemd SIGTERM instead of mysqladmin According to the MySQL manual, this is a perfectly legal way of shutting down the server. The shutdown logs also looks fine: systemd[1]: Stopping MySQL Server... mysqld[5114]: 140319 8:36:12 [Note] /nix/store/sc26mz82k97mbpx3d1abzn3rrbd155ws-mariadb-10.0.8/bin/mysqld: Normal shutdown mysqld[5114]: 140319 8:36:12 [Note] Event Scheduler: Purging the queue. 0 events mysqld[5114]: 140319 8:36:12 [Note] InnoDB: FTS optimize thread exiting. mysqld[5114]: 140319 8:36:12 [Note] InnoDB: Starting shutdown... mysqld[5114]: 140319 8:36:14 [Note] InnoDB: Shutdown completed; log sequence number 1619078 mysqld[5114]: 140319 8:36:14 [Note] /nix/store/sc26mz82k97mbpx3d1abzn3rrbd155ws-mariadb-10.0.8/bin/mysqld: Shutdown complete systemd[1]: Stopped MySQL Server. --- nixos/modules/services/databases/mysql.nix | 3 --- 1 file changed, 3 deletions(-) diff --git a/nixos/modules/services/databases/mysql.nix b/nixos/modules/services/databases/mysql.nix index 7e42438fe6d5..44fb0062f928 100644 --- a/nixos/modules/services/databases/mysql.nix +++ b/nixos/modules/services/databases/mysql.nix @@ -250,9 +250,6 @@ in rm /tmp/mysql_init fi ''; # */ - - serviceConfig.ExecStop = - "${mysql}/bin/mysqladmin ${optionalString (cfg.rootPassword != null) "--user=root --password=\"$(cat ${cfg.rootPassword})\""} shutdown"; }; };