You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by ms...@apache.org on 2017/01/04 16:01:56 UTC

[04/15] cassandra git commit: Create PID directory in RPM init for CASSANDRA-13046

Create PID directory in RPM init for CASSANDRA-13046


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/0cf0f67d
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/0cf0f67d
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/0cf0f67d

Branch: refs/heads/cassandra-3.11
Commit: 0cf0f67dfb770e0cb321d77398cf8916d52386e5
Parents: 8a112ca
Author: Michael Shuler <mi...@pbandjelly.org>
Authored: Wed Jan 4 09:56:37 2017 -0600
Committer: Michael Shuler <mi...@pbandjelly.org>
Committed: Wed Jan 4 09:56:37 2017 -0600

----------------------------------------------------------------------
 redhat/cassandra | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/0cf0f67d/redhat/cassandra
----------------------------------------------------------------------
diff --git a/redhat/cassandra b/redhat/cassandra
index 3e59534..3079487 100644
--- a/redhat/cassandra
+++ b/redhat/cassandra
@@ -53,6 +53,8 @@ case "$1" in
     start)
         # Cassandra startup
         echo -n "Starting Cassandra: "
+        [ -d `dirname "$pid_file"` ] || \
+            install -m 755 -o $CASSANDRA_OWNR -g $CASSANDRA_OWNR -d `dirname $pid_file`
         su $CASSANDRA_OWNR -c "$CASSANDRA_PROG -p $pid_file" > $log_file 2>&1
         retval=$?
         [ $retval -eq 0 ] && touch $lock_file