bin/hadoop should allow callers to set jsvc pidfile even when not-detached --------------------------------------------------------------------------
Key: HADOOP-8222 URL: https://issues.apache.org/jira/browse/HADOOP-8222 Project: Hadoop Common Issue Type: Improvement Components: scripts Affects Versions: 0.23.1, 0.20.205.0 Reporter: Peter Linnell it would be nice if the jsvc pid file were properly namespaced in /var/run to avoid collisions with other jsvc instances jsvc uses /var/run/jsvc.pid for the datanode pid file. If that's configurable, it should be configured: /var/run/jsvc.pid is sorely not namespaced. if [ "$_HADOOP_DAEMON_DETACHED" = "true" ]; then _JSVC_FLAGS="-pidfile $_HADOOP_DAEMON_PIDFILE -errfile &1 -outfile $_HADOOP_DAEMON_OUT" else # Even though we are trying to run a non-detached datanode, # jsvc will not write to stdout/stderr, so we have to pipe # it and tail the logfile. log_path=/tmp/jsvc_${COMMAND}.$$ _JSVC_FLAGS="-nodetach -errfile &1 -outfile $log_path" echo Non-detached jsvc output piping to: $log_path touch $log_path tail -f $log_path & fi And the relevant argument is '-pidfile' (http://linux.die.net/man/1/jsvc). -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira