Return-Path: X-Original-To: apmail-cassandra-commits-archive@www.apache.org Delivered-To: apmail-cassandra-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2F37318390 for ; Tue, 22 Dec 2015 08:20:47 +0000 (UTC) Received: (qmail 28212 invoked by uid 500); 22 Dec 2015 08:20:46 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 28174 invoked by uid 500); 22 Dec 2015 08:20:46 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 28161 invoked by uid 99); 22 Dec 2015 08:20:46 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Dec 2015 08:20:46 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id A8E902C1F4E for ; Tue, 22 Dec 2015 08:20:46 +0000 (UTC) Date: Tue, 22 Dec 2015 08:20:46 +0000 (UTC) From: "Severin Leonhardt (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (CASSANDRA-10920) Let systemd know if Cassandra is running MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Severin Leonhardt created CASSANDRA-10920: --------------------------------------------- Summary: Let systemd know if Cassandra is running Key: CASSANDRA-10920 URL: https://issues.apache.org/jira/browse/CASSANDRA-10920 Project: Cassandra Issue Type: Improvement Reporter: Severin Leonhardt Priority: Minor Checking the status of the Cassandra service on CentOS 7 shows this: {noformat} $ systemctl status cassandra =E2=97=8F cassandra.service - SYSV: Starts and stops Cassandra Loaded: loaded (/etc/rc.d/init.d/cassandra) Active: active (exited) since Fri 2015-12-18 13:30:02 CET; 3 days ago Docs: man:systemd-sysv-generator(8) ... {noformat} The same is shown after the Cassandra process is killed or dies by itself. = Notice this part: _Active: active (exited)_ Starting Cassandra through {{systemctl start cassandra}} will not work, bec= ause systemd still thinks the service is running. According to the [systemd documentation regarding compatibility with SysV|h= ttp://www.freedesktop.org/wiki/Software/systemd/Incompatibilities/] this is= expected behavior. Systemd doesn't know the PID of the Cassandra process a= nd thus can't check if the service is running or not. It is suggested to add the following to the SysV script header comment: {noformat} # pidfile: /var/run/cassandra/cassandra.pid {noformat} After adding this manually systemd correctly detected the state of the Cass= andra process on our machines. -- This message was sent by Atlassian JIRA (v6.3.4#6332)