From 17b25aa8a3ff2f5042a6495ead2f4df4b122fb94 Mon Sep 17 00:00:00 2001 From: Pavel Kartavyy Date: Tue, 9 Dec 2014 16:17:38 +0300 Subject: [PATCH] init.d: better --- tools/init.d/template | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/init.d/template b/tools/init.d/template index 6529c33e609..d7248b4c408 100755 --- a/tools/init.d/template +++ b/tools/init.d/template @@ -45,7 +45,11 @@ generate_program_name() generate_pid_name() { - echo $PIDFILE_PREFIX$1.pid + if [ $NUMBER_OF_PROCESSES -gt 1 ]; then + echo $PIDFILE_PREFIX$1.pid + else + echo $PIDFILE_PREFIX.pid + fi } specific_log_file_for_each_process()