Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Apr 2016 14:52:41 +0000 (UTC)
From:      Dmitry Sivachenko <demon@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r414111 - head/devel/hadoop2/files
Message-ID:  <201604271452.u3REqfQq072702@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: demon
Date: Wed Apr 27 14:52:41 2016
New Revision: 414111
URL: https://svnweb.freebsd.org/changeset/ports/414111

Log:
  Fix 'status' argument for rc-scripts.
  
  PR:		208639
  Submitted by:	xmj

Modified:
  head/devel/hadoop2/files/datanode.in
  head/devel/hadoop2/files/journalnode.in
  head/devel/hadoop2/files/namenode.in
  head/devel/hadoop2/files/nodemanager.in
  head/devel/hadoop2/files/resourcemanager.in
  head/devel/hadoop2/files/zkfc.in

Modified: head/devel/hadoop2/files/datanode.in
==============================================================================
--- head/devel/hadoop2/files/datanode.in	Wed Apr 27 14:50:24 2016	(r414110)
+++ head/devel/hadoop2/files/datanode.in	Wed Apr 27 14:52:41 2016	(r414111)
@@ -22,10 +22,12 @@ load_rc_config "${name}"
 : ${datanode_user:=%%HDFS_USER%%}
 
 command="%%PREFIX%%/sbin/hadoop-daemon.sh"
+command_interpreter_execution="%%JAVA_HOME%%/bin/java"
 command_args='--config %%ETCDIR%% start datanode'
 
 start_postcmd="start_postcmd"
 stop_cmd=datanode_stop
+status_precmd=find_pid
 
 start_postcmd () {
   rc_pid=$(check_pidfile ${pidfile} %%JAVA_HOME%%/bin/java)
@@ -38,4 +40,8 @@ datanode_stop () {
   su -m ${datanode_user} -c "${command} --config %%ETCDIR%% stop datanode"
 }
 
+find_pid () {
+  rc_pid=$(check_pidfile $pidfile $command_interpreter_execution)
+}
+
 run_rc_command "$1"

Modified: head/devel/hadoop2/files/journalnode.in
==============================================================================
--- head/devel/hadoop2/files/journalnode.in	Wed Apr 27 14:50:24 2016	(r414110)
+++ head/devel/hadoop2/files/journalnode.in	Wed Apr 27 14:52:41 2016	(r414111)
@@ -21,12 +21,18 @@ load_rc_config "${name}"
 : ${journalnode_user:=%%HDFS_USER%%}
 
 command="%%PREFIX%%/sbin/hadoop-daemon.sh"
+command_interpreter_execution="%%JAVA_HOME%%/bin/java"
 command_args='--config %%ETCDIR%% start journalnode'
 
 stop_cmd=journalnode_stop
+status_precmd=find_pid
 
 journalnode_stop () {
   su -m ${journalnode_user} -c "${command} --config %%ETCDIR%% stop journalnode"
 }
 
+find_pid () {
+  rc_pid=$(check_pidfile $pidfile $command_interpreter_execution)
+}
+
 run_rc_command "$1"

Modified: head/devel/hadoop2/files/namenode.in
==============================================================================
--- head/devel/hadoop2/files/namenode.in	Wed Apr 27 14:50:24 2016	(r414110)
+++ head/devel/hadoop2/files/namenode.in	Wed Apr 27 14:52:41 2016	(r414111)
@@ -21,12 +21,18 @@ load_rc_config "${name}"
 : ${namenode_user:=%%HDFS_USER%%}
 
 command="%%PREFIX%%/sbin/hadoop-daemon.sh"
+command_interpreter_execution="%%JAVA_HOME%%/bin/java"
 command_args='--config %%ETCDIR%% start namenode'
 
 stop_cmd=namenode_stop
+status_precmd=find_pid
 
 namenode_stop () {
   su -m ${namenode_user} -c "${command} --config %%ETCDIR%% stop namenode"
 }
 
+find_pid () {
+  rc_pid=$(check_pidfile $pidfile $command_interpreter_execution)
+}
+
 run_rc_command "$1"

Modified: head/devel/hadoop2/files/nodemanager.in
==============================================================================
--- head/devel/hadoop2/files/nodemanager.in	Wed Apr 27 14:50:24 2016	(r414110)
+++ head/devel/hadoop2/files/nodemanager.in	Wed Apr 27 14:52:41 2016	(r414111)
@@ -22,10 +22,12 @@ load_rc_config "${name}"
 : ${nodemanager_user:=%%MAPRED_USER%%}
 
 command="%%PREFIX%%/sbin/yarn-daemon.sh"
+command_interpreter_execution="%%JAVA_HOME%%/bin/java"
 command_args='--config %%ETCDIR%% start nodemanager'
 
 start_postcmd="start_postcmd"
 stop_cmd=nodemanager_stop
+status_precmd=find_pid
 
 start_postcmd () {
   rc_pid=$(check_pidfile ${pidfile} %%JAVA_HOME%%/bin/java)
@@ -38,4 +40,8 @@ nodemanager_stop () {
   su -m ${nodemanager_user} -c "${command} --config %%ETCDIR%% stop nodemanager"
 }
 
+find_pid () {
+  rc_pid=$(check_pidfile $pidfile $command_interpreter_execution)
+}
+
 run_rc_command "$1"

Modified: head/devel/hadoop2/files/resourcemanager.in
==============================================================================
--- head/devel/hadoop2/files/resourcemanager.in	Wed Apr 27 14:50:24 2016	(r414110)
+++ head/devel/hadoop2/files/resourcemanager.in	Wed Apr 27 14:52:41 2016	(r414111)
@@ -21,12 +21,19 @@ load_rc_config "${name}"
 : ${resourcemanager_user:=%%MAPRED_USER%%}
 
 command="%%PREFIX%%/sbin/yarn-daemon.sh"
+command_interpreter_execution="%%JAVA_HOME%%/bin/java"
 command_args='--config %%ETCDIR%% start resourcemanager'
 
 stop_cmd=resourcemanager_stop
+start_postcmd="start_postcmd"
+status_precmd=find_pid
 
 resourcemanager_stop () {
   su -m ${resourcemanager_user} -c "${command} --config %%ETCDIR%% stop resourcemanager"
 }
 
+find_pid () {
+  rc_pid=$(check_pidfile $pidfile $command_interpreter_execution)
+}
+
 run_rc_command "$1"

Modified: head/devel/hadoop2/files/zkfc.in
==============================================================================
--- head/devel/hadoop2/files/zkfc.in	Wed Apr 27 14:50:24 2016	(r414110)
+++ head/devel/hadoop2/files/zkfc.in	Wed Apr 27 14:52:41 2016	(r414111)
@@ -21,12 +21,18 @@ load_rc_config "${name}"
 : ${zkfc_user:=%%HDFS_USER%%}
 
 command="%%PREFIX%%/sbin/hadoop-daemon.sh"
+command_interpreter_execution="%%JAVA_HOME%%/bin/java"
 command_args='--config %%ETCDIR%% start zkfc'
 
 stop_cmd=zkfc_stop
+status_precmd=find_pid
 
 zkfc_stop () {
   su -m ${zkfc_user} -c "${command} --config %%ETCDIR%% stop zkfc"
 }
 
+find_pid () {
+  rc_pid=$(check_pidfile $pidfile $command_interpreter_execution)
+}
+
 run_rc_command "$1"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201604271452.u3REqfQq072702>