From e4e5c2e598e02c5646152275a1c9cea1785dba95 Mon Sep 17 00:00:00 2001 From: vdimir Date: Mon, 24 May 2021 16:45:33 +0300 Subject: [PATCH 1/3] Fix cli argument in clickhouse-server.init --- debian/clickhouse-server.init | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/debian/clickhouse-server.init b/debian/clickhouse-server.init index 3e4e888eacd..c943d75a56b 100755 --- a/debian/clickhouse-server.init +++ b/debian/clickhouse-server.init @@ -109,7 +109,7 @@ restart() forcestop() { - ${CLICKHOUSE_GENERIC_PROGRAM} stop --force --pid-path "${CLICKHOUSE_PIDDIR}" + ${CLICKHOUSE_GENERIC_PROGRAM} stop --force true --pid-path "${CLICKHOUSE_PIDDIR}" } From d13248b8a4412760e0e27bb8f2d38a1a106242cf Mon Sep 17 00:00:00 2001 From: vdimir Date: Mon, 24 May 2021 16:51:50 +0300 Subject: [PATCH 2/3] Revert "Fix cli argument in clickhouse-server.init" This reverts commit e4e5c2e598e02c5646152275a1c9cea1785dba95. --- debian/clickhouse-server.init | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/debian/clickhouse-server.init b/debian/clickhouse-server.init index c943d75a56b..3e4e888eacd 100755 --- a/debian/clickhouse-server.init +++ b/debian/clickhouse-server.init @@ -109,7 +109,7 @@ restart() forcestop() { - ${CLICKHOUSE_GENERIC_PROGRAM} stop --force true --pid-path "${CLICKHOUSE_PIDDIR}" + ${CLICKHOUSE_GENERIC_PROGRAM} stop --force --pid-path "${CLICKHOUSE_PIDDIR}" } From fce6156e0464f3a7dda9fbfa89a0763e4065dec3 Mon Sep 17 00:00:00 2001 From: vdimir Date: Mon, 24 May 2021 16:53:30 +0300 Subject: [PATCH 3/3] Use bool_switch instead of value for 'force' option in Install.cpp --- programs/install/Install.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/programs/install/Install.cpp b/programs/install/Install.cpp index 96d336673d0..8c187978106 100644 --- a/programs/install/Install.cpp +++ b/programs/install/Install.cpp @@ -983,7 +983,7 @@ int mainEntryClickHouseStop(int argc, char ** argv) desc.add_options() ("help,h", "produce help message") ("pid-path", po::value()->default_value("/var/run/clickhouse-server"), "directory for pid file") - ("force", po::value()->default_value(false), "Stop with KILL signal instead of TERM") + ("force", po::bool_switch(), "Stop with KILL signal instead of TERM") ; po::variables_map options;