Modified TSDR HBase Installation Guide and corrected some formatting issues.
[docs.git] / manuals / getting-started-guide / src / main / asciidoc / tsdr / tsdr-hbase-install.adoc
1 == TSDR HBase Data Store Installation Guide
2 This document is for the user to install the artifacts that are needed
3 for using HBase Data Store in Time Series Data Repository, which is
4 a new feature available in OpenDaylight Lithium release.
5
6 === Overview
7 The Time Series Data Repository (TSDR) project in OpenDaylight (ODL) creates a framework for collecting, storing, querying, and maintaining time series data in the OpenDaylight SDN controller. It contains  the following services and components:
8
9 * Data Collection Service
10 * Data Storage Service
11 * TSDR Persistence Layer with data stores as plugins
12 * TSDR Data Stores
13 * Data Query Service
14 * Data Aggregation Service
15 * Data Purging Service
16
17 Data Collection Service handles the collection of time series data into TSDR and hands it over to Data Storage Service. Data Storage Service stores the data into TSDR through TSDR Persistence Layer. TSDR Persistence Layer provides generic Service APIs allowing various data stores to be plugged in. Data Aggregation Service aggregates time series fine-grained raw data into course-grained roll-up data to control the size of the data. Data Purging Service periodically purges both fine-grained raw data and course-granined aggregated data according to user-defined schedules.
18
19
20 In Lithium, we implemented Data Collection Service, Data Storage Service, TSDR Persistence Layer, TSDR HBase Data Store, and TSDR H2 Data Store. Among these services and components, time series data is communicated using a common TSDR data model, which is designed and implemented for the abstraction of the time series data commonalities. With these functions, TSDR will be able to collect the data from the data sources and store them into one of the TSDR data stores: either HBase Data Store or H2 Data Store. We also provided a simple query command from Karaf console for the user to retrieve TSDR data from the data stores.
21
22 A future release will contain Data Aggregation service, Data Purging Service, and a full-fledged Data Query Service with Norghbound APIs.
23
24
25 === Prerequisites for Installing TSDR HBase Data Store
26 The hardware requirements are the same as those for standard ODL controller installation. 
27
28 The software requirements for TSDR HBase Data Store are as follows:
29
30 * The supported operating system for TSDR HBase Data Store is Linux. We do not support TSDR HBase Data Store on Windows.
31 * Besides the software that ODL requires, we also require HBase database running on top of Hadoop single node.
32
33 === Preparing for Installation
34 Download HBase (version number to be finalized) from the following website.
35
36 http://archive.apache.org/dist/hbase/hbase-0.94.15/
37
38
39 === Installing TSDR HBase Data Store 
40 Installing TSDR HBase Data Store contains two steps:
41
42     * Installing HBase server, and
43     * Installing TSDR HBase Data Store features from ODL Karaf console.
44
45 This installation guide will only cover the first step. For installing TSDR HBase Data Store features, please refer to TSDR HBase Data Store User Guide.
46
47 In Lithium, we only support HBase single node running together on the same machine as ODL controller. Therefore, follow the steps to download and install HBase server onto the same box as where ODL controller is running:
48
49 * Create a folder in Linux operating system for the HBase server.
50
51 For example, create an hbase directory under /usr/lib:
52
53       mkdir /usr/lib/hbase
54
55 * Unzip the downloaded HBase server tar file.
56
57 Run the following command to unzip the installation package:
58
59       tar xvf <hbase-installer-name>  /usr/lib/hbase 
60
61 * Make proper changes in hbase-site.xml
62
63    .. Under <hbase-install-directory>/conf/, there is a hbase-site.xml. Although it is not recommended, an experience user with HBase canmodify the data directory for hbase server to store the data.
64
65    .. Modify the value of the property with name "hbase.rootdir" in the file to reflect the desired file directory for storing hbase data.
66
67 The following is an example of the file:
68
69     <configuration>
70       <property>
71         <name>hbase.rootdir</name>
72         <value>file:///usr/lib/hbase/data</value>
73       </property>
74       <property>
75         <name>hbase.zookeeper.property.dataDir</name>
76         <value>/usr/lib/hbase/zookeeper</value>
77       </property>
78     </configuration>
79  
80
81 === Verifying your Installation
82 After the HBase server is properly installed, start hbase server and hbase shell.
83
84 .. start hbase server
85
86    cd <hbase-installation-directory> 
87    ./start-hbase.sh
88
89 .. start hbase shell
90
91    cd <hbase-insatllation-directory>
92    ./hbase shell
93
94 === Post Installation Configuration
95 Please refer to HBase Data Store User Guide.
96
97 === Upgrading From a Previous Release
98 Lithium is the first release of TSDR. Upgrading is not applicable for TSDR Lithium release.
99
100 === Uninstalling HBase Data Store 
101 To uninstall TSDR HBase Data Store, 
102
103 .. stop hbase server
104
105    cd <hbase-installation-directory>
106    ./stop-hbase.sh
107
108 .. remove the file directory that contains the HBase server installation.
109
110    rm -r <hbase-installation-directory>