[ 
https://issues.apache.org/jira/browse/YARN-8140?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Yesha Vora updated YARN-8140:
-----------------------------
    Description: 
Steps:

 1) Launch sleeper app

{code}

RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -launch 
sleeper2-duplicate-app-stopped 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
YARN_LOG_DIR.

WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
YARN_LOGFILE.

WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
YARN_PID_DIR.

WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.

18/04/10 21:31:01 WARN util.NativeCodeLoader: Unable to load native-hadoop 
library for your platform... using builtin-java classes where applicable

18/04/10 21:31:01 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:01 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:01 INFO client.ApiServiceClient: Loading service definition from 
local FS: 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

18/04/10 21:31:03 INFO util.log: Logging initialized @2818ms

18/04/10 21:31:10 INFO client.ApiServiceClient: Application ID: 
application_1523387473707_0007

Exit Code: 0{code}

2) Stop the application

{code}

RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -stop 
sleeper2-duplicate-app-stopped

WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
YARN_LOG_DIR.

WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
YARN_LOGFILE.

WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
YARN_PID_DIR.

WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.

18/04/10 21:31:14 WARN util.NativeCodeLoader: Unable to load native-hadoop 
library for your platform... using builtin-java classes where applicable

18/04/10 21:31:15 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:15 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:16 INFO util.log: Logging initialized @3034ms

18/04/10 21:31:17 INFO client.ApiServiceClient: Successfully stopped service 
sleeper2-duplicate-app-stopped

Exit Code: 0{code}

3) Launch the application with same name

{code}

RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -launch 
sleeper2-duplicate-app-stopped 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
YARN_LOG_DIR.

WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
YARN_LOGFILE.

WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
YARN_PID_DIR.

WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.

18/04/10 21:31:19 WARN util.NativeCodeLoader: Unable to load native-hadoop 
library for your platform... using builtin-java classes where applicable

18/04/10 21:31:19 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:19 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:19 INFO client.ApiServiceClient: Loading service definition from 
local FS: 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

18/04/10 21:31:22 INFO util.log: Logging initialized @4456ms

18/04/10 21:31:22 ERROR client.ApiServiceClient: Service Instance dir already 
exists: 
hdfs://mycluster/user/hrt_qa/.yarn/services/sleeper2-duplicate-app-stopped/sleeper2-duplicate-app-stopped.json

Exit Code: 56
{code}

 

Here, launch cmd fails with "Service Instance dir already exists: 
hdfs://mycluster/user/hrt_qa/.yarn/services/sleeper2-duplicate-app-stopped/sleeper2-duplicate-app-stopped.json".

 

The log message should be more meaningful. It should return that 
"sleeper2-duplicate-app-stopped is in stopped state".

  was:
Steps:

 1) Launch sleeper app

{code}

RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -launch 
sleeper2-duplicate-app-stopped 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
YARN_LOG_DIR.

WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
YARN_LOGFILE.

WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
YARN_PID_DIR.

WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.

18/04/10 21:31:01 WARN util.NativeCodeLoader: Unable to load native-hadoop 
library for your platform... using builtin-java classes where applicable

18/04/10 21:31:01 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:01 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:01 INFO client.ApiServiceClient: Loading service definition from 
local FS: 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

18/04/10 21:31:03 INFO util.log: Logging initialized @2818ms

18/04/10 21:31:10 INFO client.ApiServiceClient: Application ID: 
application_1523387473707_0007

Exit Code: 0\{code}

2) Stop the application

{code}

RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -stop 
sleeper2-duplicate-app-stopped

WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
YARN_LOG_DIR.

WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
YARN_LOGFILE.

WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
YARN_PID_DIR.

WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.

18/04/10 21:31:14 WARN util.NativeCodeLoader: Unable to load native-hadoop 
library for your platform... using builtin-java classes where applicable

18/04/10 21:31:15 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:15 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:16 INFO util.log: Logging initialized @3034ms

18/04/10 21:31:17 INFO client.ApiServiceClient: Successfully stopped service 
sleeper2-duplicate-app-stopped

Exit Code: 0\{code}

3) Launch the application with same name

{code}

RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -launch 
sleeper2-duplicate-app-stopped 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
YARN_LOG_DIR.

WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
YARN_LOGFILE.

WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
YARN_PID_DIR.

WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.

18/04/10 21:31:19 WARN util.NativeCodeLoader: Unable to load native-hadoop 
library for your platform... using builtin-java classes where applicable

18/04/10 21:31:19 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:19 INFO client.AHSProxy: Connecting to Application History 
server at xxxxxx:10200

18/04/10 21:31:19 INFO client.ApiServiceClient: Loading service definition from 
local FS: 
/usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json

18/04/10 21:31:22 INFO util.log: Logging initialized @4456ms

18/04/10 21:31:22 ERROR client.ApiServiceClient: Service Instance dir already 
exists: 
hdfs://mycluster/user/hrt_qa/.yarn/services/sleeper2-duplicate-app-stopped/sleeper2-duplicate-app-stopped.json

Exit Code: 56

{code}

 

Here, launch cmd fails with "Service Instance dir already exists: 
hdfs://mycluster/user/hrt_qa/.yarn/services/sleeper2-duplicate-app-stopped/sleeper2-duplicate-app-stopped.json".

 

The log message should be more meaningful. It should return that 
"sleeper2-duplicate-app-stopped is in stopped state".


> Improve log message when launch cmd is ran for stopped yarn service
> -------------------------------------------------------------------
>
>                 Key: YARN-8140
>                 URL: https://issues.apache.org/jira/browse/YARN-8140
>             Project: Hadoop YARN
>          Issue Type: Improvement
>          Components: yarn-native-services
>    Affects Versions: 3.1.0
>            Reporter: Yesha Vora
>            Priority: Major
>
> Steps:
>  1) Launch sleeper app
> {code}
> RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -launch 
> sleeper2-duplicate-app-stopped 
> /usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json
> WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
> YARN_LOG_DIR.
> WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
> YARN_LOGFILE.
> WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
> YARN_PID_DIR.
> WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.
> 18/04/10 21:31:01 WARN util.NativeCodeLoader: Unable to load native-hadoop 
> library for your platform... using builtin-java classes where applicable
> 18/04/10 21:31:01 INFO client.AHSProxy: Connecting to Application History 
> server at xxxxxx:10200
> 18/04/10 21:31:01 INFO client.AHSProxy: Connecting to Application History 
> server at xxxxxx:10200
> 18/04/10 21:31:01 INFO client.ApiServiceClient: Loading service definition 
> from local FS: 
> /usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json
> 18/04/10 21:31:03 INFO util.log: Logging initialized @2818ms
> 18/04/10 21:31:10 INFO client.ApiServiceClient: Application ID: 
> application_1523387473707_0007
> Exit Code: 0{code}
> 2) Stop the application
> {code}
> RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -stop 
> sleeper2-duplicate-app-stopped
> WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
> YARN_LOG_DIR.
> WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
> YARN_LOGFILE.
> WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
> YARN_PID_DIR.
> WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.
> 18/04/10 21:31:14 WARN util.NativeCodeLoader: Unable to load native-hadoop 
> library for your platform... using builtin-java classes where applicable
> 18/04/10 21:31:15 INFO client.AHSProxy: Connecting to Application History 
> server at xxxxxx:10200
> 18/04/10 21:31:15 INFO client.AHSProxy: Connecting to Application History 
> server at xxxxxx:10200
> 18/04/10 21:31:16 INFO util.log: Logging initialized @3034ms
> 18/04/10 21:31:17 INFO client.ApiServiceClient: Successfully stopped service 
> sleeper2-duplicate-app-stopped
> Exit Code: 0{code}
> 3) Launch the application with same name
> {code}
> RUNNING: /usr/hdp/current/hadoop-yarn-client/bin/yarn app -launch 
> sleeper2-duplicate-app-stopped 
> /usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json
> WARNING: YARN_LOG_DIR has been replaced by HADOOP_LOG_DIR. Using value of 
> YARN_LOG_DIR.
> WARNING: YARN_LOGFILE has been replaced by HADOOP_LOGFILE. Using value of 
> YARN_LOGFILE.
> WARNING: YARN_PID_DIR has been replaced by HADOOP_PID_DIR. Using value of 
> YARN_PID_DIR.
> WARNING: YARN_OPTS has been replaced by HADOOP_OPTS. Using value of YARN_OPTS.
> 18/04/10 21:31:19 WARN util.NativeCodeLoader: Unable to load native-hadoop 
> library for your platform... using builtin-java classes where applicable
> 18/04/10 21:31:19 INFO client.AHSProxy: Connecting to Application History 
> server at xxxxxx:10200
> 18/04/10 21:31:19 INFO client.AHSProxy: Connecting to Application History 
> server at xxxxxx:10200
> 18/04/10 21:31:19 INFO client.ApiServiceClient: Loading service definition 
> from local FS: 
> /usr/hdp/3.0.0.0-xxx/hadoop-yarn/yarn-service-examples/sleeper/sleeper.json
> 18/04/10 21:31:22 INFO util.log: Logging initialized @4456ms
> 18/04/10 21:31:22 ERROR client.ApiServiceClient: Service Instance dir already 
> exists: 
> hdfs://mycluster/user/hrt_qa/.yarn/services/sleeper2-duplicate-app-stopped/sleeper2-duplicate-app-stopped.json
> Exit Code: 56
> {code}
>  
> Here, launch cmd fails with "Service Instance dir already exists: 
> hdfs://mycluster/user/hrt_qa/.yarn/services/sleeper2-duplicate-app-stopped/sleeper2-duplicate-app-stopped.json".
>  
> The log message should be more meaningful. It should return that 
> "sleeper2-duplicate-app-stopped is in stopped state".



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org

Reply via email to