From c9e50c48de4ff7ef6bb89153362531833fd8da9f Mon Sep 17 00:00:00 2001 From: Rohith Sharma K S Date: Tue, 19 Mar 2019 12:05:28 +0530 Subject: [PATCH] YARN-9365. Fix table creation command in TimelineServiceV2.md --- .../src/site/markdown/TimelineServiceV2.md | 26 ++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-site/src/site/markdown/TimelineServiceV2.md b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-site/src/site/markdown/TimelineServiceV2.md index 73176ef3f8..eb843771aa 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-site/src/site/markdown/TimelineServiceV2.md +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-site/src/site/markdown/TimelineServiceV2.md @@ -252,9 +252,33 @@ For example, ``` ##### Step 3) Create the timeline service schema +The schema creation can be run on the hbase cluster which is going to store the timeline +service tables. The schema creator tool requires both the timelineservice-hbase as well +as the hbase-server jars. Hence, during schema creation, you need to ensure that the +hbase classpath contains the yarn-timelineservice-hbase jar. + +On the hbase cluster, you can get it from hdfs since we placed it there for the +coprocessor in the step above. + +``` + hadoop fs -get /hbase/coprocessor/hadoop-yarn-server-timelineservice-hbase-client-${project.version}.jar /. + hadoop fs -get /hbase/coprocessor/hadoop-yarn-server-timelineservice-${project.version}.jar /. + hadoop fs -get /hbase/coprocessor/hadoop-yarn-server-timelineservice-hbase-common-${project.version}.jar /. +``` + +Next, add it to the hbase classpath as follows: + +``` + export HBASE_CLASSPATH=$HBASE_CLASSPATH:/home/yarn/hadoop-current/share/hadoop/yarn/timelineservice/hadoop-yarn-server-timelineservice-hbase-client-${project.version}.jar + export HBASE_CLASSPATH=$HBASE_CLASSPATH:/home/yarn/hadoop-current/share/hadoop/yarn/timelineservice/hadoop-yarn-server-timelineservice-${project.version}.jar + export HBASE_CLASSPATH=$HBASE_CLASSPATH:/home/yarn/hadoop-current/share/hadoop/yarn/timelineservice/hadoop-yarn-server-timelineservice-hbase-common-${project.version}.jar +``` + Finally, run the schema creator tool to create the necessary tables: - bin/hadoop org.apache.hadoop.yarn.server.timelineservice.storage.TimelineSchemaCreator -create +``` + bin/hbase org.apache.hadoop.yarn.server.timelineservice.storage.TimelineSchemaCreator -create +``` The `TimelineSchemaCreator` tool supports a few options that may come handy especially when you are testing. For example, you can use `-skipExistingTable` (`-s` for short) to skip existing tables