ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AMBARI-8185) Services fail to start when pid file is empty
Date Thu, 06 Nov 2014 17:25:33 GMT

    [ https://issues.apache.org/jira/browse/AMBARI-8185?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14200496#comment-14200496
] 

Hudson commented on AMBARI-8185:
--------------------------------

SUCCESS: Integrated in Ambari-trunk-Commit #844 (See [https://builds.apache.org/job/Ambari-trunk-Commit/844/])
AMBARI-8185. Services fail to start when pid file is empty (dlysnichenko) (dlysnichenko: http://git-wip-us.apache.org/repos/asf?p=ambari.git&a=commit&h=a9092f99087d4305bc323352204d2005fed0053d)
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/webhcat_service.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HBASE/package/scripts/hbase_service.py
* ambari-server/src/test/python/stacks/1.3.2/HBASE/test_hbase_regionserver.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6.GlusterFS/services/YARN/package/scripts/service.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HIVE/package/scripts/hive_service.py
* ambari-server/src/test/python/stacks/2.0.6/HDFS/test_namenode.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/HDFS/package/scripts/utils.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/webhcat_service.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/ZOOKEEPER/package/scripts/zookeeper_service.py
* ambari-server/src/test/python/stacks/1.3.2/HDFS/test_namenode.py
* ambari-server/src/test/python/stacks/2.1/HIVE/test_hive_metastore.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/HDFS/package/scripts/service_check.py
* ambari-server/src/main/resources/stacks/HDP/2.2/services/KNOX/package/scripts/knox_gateway.py
* ambari-server/src/test/python/stacks/2.1/STORM/test_storm_supervisor.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/scripts/service_check.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/OOZIE/package/scripts/oozie.py
* ambari-server/src/test/python/stacks/2.0.6/YARN/test_nodemanager.py
* ambari-server/src/test/python/stacks/2.0.6/HIVE/test_webhcat_server.py
* ambari-server/src/test/python/stacks/2.1/STORM/test_storm_nimbus.py
* ambari-server/src/test/python/stacks/1.3.2/HIVE/test_webhcat_server.py
* ambari-server/src/main/resources/stacks/HDP/2.2/services/KAFKA/package/scripts/kafka_broker.py
* ambari-server/src/test/python/stacks/2.0.6/HDFS/test_snamenode.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/WEBHCAT/package/scripts/webhcat_service.py
* ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/STORM/package/scripts/service.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/scripts/service_check.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/ZOOKEEPER/package/scripts/zookeeper_service.py
* ambari-server/src/test/python/stacks/1.3.2/HBASE/test_hbase_master.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HBASE/package/scripts/hbase_service.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HIVE/package/scripts/hive_service.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/HDFS/package/scripts/utils.py
* ambari-server/src/test/python/stacks/2.1/STORM/test_storm_rest_api_service.py
* ambari-server/src/test/python/stacks/2.0.6/HDFS/test_journalnode.py
* ambari-server/src/test/python/stacks/1.3.2/HIVE/test_hive_server.py
* ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_metastore.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/HDFS/package/scripts/utils.py
* ambari-server/src/test/python/stacks/1.3.2/OOZIE/test_oozie_server.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/HIVE/package/scripts/hive_service.py
* ambari-server/src/test/python/stacks/1.3.2/HDFS/test_datanode.py
* ambari-agent/conf/unix/ambari-agent
* ambari-server/src/test/python/stacks/2.0.6/YARN/test_resourcemanager.py
* ambari-server/src/test/python/stacks/2.1/STORM/test_storm_ui_server.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/OOZIE/package/scripts/oozie_service.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/OOZIE/package/scripts/oozie_service.py
* ambari-server/src/test/python/stacks/2.0.6/HBASE/test_hbase_master.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/OOZIE/package/scripts/oozie_service.py
* ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py
* ambari-server/src/test/python/stacks/1.3.2/HDFS/test_snamenode.py
* ambari-server/src/test/python/stacks/2.0.6/YARN/test_historyserver.py
* ambari-server/src/main/resources/stacks/HDP/2.1/services/STORM/package/scripts/service.py
* ambari-server/src/test/python/stacks/2.1/STORM/test_storm_drpc_server.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/OOZIE/package/scripts/oozie.py
* ambari-server/src/test/python/stacks/1.3.2/MAPREDUCE/test_mapreduce_jobtracker.py
* ambari-server/src/test/python/stacks/1.3.2/HIVE/test_hive_metastore.py
* ambari-server/src/test/python/stacks/1.3.2/MAPREDUCE/test_mapreduce_historyserver.py
* ambari-server/src/test/python/stacks/2.0.6/HDFS/test_zkfc.py
* ambari-server/src/test/python/stacks/1.3.2/MAPREDUCE/test_mapreduce_tasktracker.py
* ambari-server/src/test/python/stacks/1.3.2/ZOOKEEPER/test_zookeeper_server.py
* ambari-server/src/test/python/stacks/2.1/YARN/test_apptimelineserver.py
* ambari-server/src/test/python/stacks/2.0.6/HDFS/test_datanode.py
* ambari-server/src/main/resources/stacks/HDP/2.1.GlusterFS/services/YARN/package/scripts/service.py
* ambari-server/src/main/resources/stacks/HDP/1.3.2/services/MAPREDUCE/package/scripts/service.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/YARN/package/scripts/service.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/YARN/package/scripts/service.py
* ambari-server/src/test/python/stacks/2.1/STORM/test_storm_supervisor_prod.py
* ambari-server/src/main/resources/stacks/HDP/2.0.6/services/OOZIE/package/scripts/oozie.py
* ambari-server/src/test/python/stacks/2.0.6/HIVE/test_hive_server.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/HBASE/package/scripts/hbase_service.py
* ambari-server/src/main/resources/stacks/BIGTOP/0.8/services/ZOOKEEPER/package/scripts/zookeeper_service.py
* ambari-server/src/test/python/stacks/2.0.6/ZOOKEEPER/test_zookeeper_server.py
* ambari-server/src/test/python/stacks/2.0.6/HBASE/test_hbase_regionserver.py


> Services fail to start when pid file is empty
> ---------------------------------------------
>
>                 Key: AMBARI-8185
>                 URL: https://issues.apache.org/jira/browse/AMBARI-8185
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: 1.6.1
>            Reporter: Dmitry Lysnichenko
>            Assignee: Dmitry Lysnichenko
>             Fix For: 2.0.0
>
>         Attachments: AMBARI-8185.patch
>
>
> Witnessed at a customer site:
> * Storm Supervisor server had a pid file at {{/var/run/storm/supervisor.pid}}
> * This file, while present, had no content
> * The stack file, {{service.py}} detects a running process using this call:
> {noformat}
>   no_op_test = format("ls {pid_file} >/dev/null 2>&1 && ps `cat {pid_file}`
>/dev/null 2>&1")
> {noformat}
> * When the file is empty, this command returns 0 (success), and the startup command does
not run.
> * Changed the command to
> {noformat}
>   no_op_test = format("ls {pid_file} >/dev/null 2>&1 && ps -p `cat
{pid_file}` >/dev/null 2>&1")
> {noformat}
> which returns properly that the process is not running and startup can continue.
> The customer reports that they have seen this behavior with other services, but could
not reproduce on-site.  This pattern is used frequently through the code base and should be
addressed for all services including Storm.  Validation of this change is the critical task
here since the change is "small" - the effects are large in scope.
> Also, at ambari/ambari-agent/conf/unix/ambari-agent we have few invocations of a similar
code with another bug:
> {code}
>           PID=`cat $PIDFILE`
>           echo "Found $AMBARI_AGENT PID: $PID"
>           if [ -z "`ps ax -o pid | grep $PID`" ]; then
> {code}
> Here if $PID is for example 2111 and there is a running process with pid like 22111,
we will get a false positive (agent will refuse to start saying it is already running).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message