TSDR H2 user and install documentation 71/18571/10
authorBasheeruddin Ahmed <syedbahm@cisco.com>
Sat, 18 Apr 2015 00:41:16 +0000 (17:41 -0700)
committerColin Dixon <colin@colindixon.com>
Tue, 2 Jun 2015 19:11:27 +0000 (15:11 -0400)
<patchset 8>: incorporated review comments and updated the tsdr:list command details
<patchset 9>: incorporated review comments
<patchset 10>: fixing some grammar/formatting issues

Change-Id: I615bc1eab76407096ddcde2184df205067168595
Signed-off-by: Basheeruddin Ahmed <syedbahm@cisco.com>
Signed-off-by: Basheeruddin <syedbahm@cisco.com>
manuals/install-guide/src/main/asciidoc/tsdr/tsdr-h2-install.adoc [new file with mode: 0644]
manuals/user-guide/src/main/asciidoc/tsdr/tsdr-h2-user.adoc

diff --git a/manuals/install-guide/src/main/asciidoc/tsdr/tsdr-h2-install.adoc b/manuals/install-guide/src/main/asciidoc/tsdr/tsdr-h2-install.adoc
new file mode 100644 (file)
index 0000000..0283cf3
--- /dev/null
@@ -0,0 +1,43 @@
+== TSDR H2 Default Datastore Installation Guide
+This document is for the user to install the artifacts that are needed
+for using Time Series Data Repository (TSDR) functionality in the ODL Controller by enabling the default JPA (H2) Datastore. TSDR is new functionality added in OpenDayLight in Lithium Release. 
+
+=== Overview
+In Lithium Release the time deries data records of OpenFlow statistics are collected periodically and stored in a persistent store. For non-production usage, the bundled default JPA based datastore (H2) is utilized based on odl-tsdr-all feature installation. The TSDR records get persisted in H2 store in <install folder>/tsdr/ folder by default.  
+
+=== Pre Requisites for Installing TSDR with default H2 datastore 
+There are no additional pre-requisites for TSDR based on default datastore 
+
+=== Preparing for Installation
+No additional steps required for preparation of installing TSDR feature 
+
+=== Installing TSDR with default H2 datastore 
+Once Opendaylight distribution is up, from karaf console install the TSDR feature with default datastore (JPA based datastore H2 store used) can be installed by 
+
+feature:install odl-tsdr-all 
+
+This will install all dependency features (and can take sometime) before returning control to the console. 
+
+=== Verifying your Installation
+If the feature install was successful you should be able to see the following tsdr commands added 
+
+**tsdr:list 
+**tsdr:purgeAll 
+
+==== Troubleshooting
+Check the ../data/log/karaf.log for any exception related to TSDR or JPA related features  
+
+=== Post Installation Configuration
+The feature installation takes care of automated configuration of the datasource by installing a file in <install folder>/etc named org.ops4j.datasource-metric.cfg. This contains the default location of <install folder>/tsdr where the H2 datastore files are stored. If you want to change the default location of the datastore files to some other location update the last portion of the url property in the org.ops4j.datasource-metric.cfg and then restart the karaf container 
+
+=== Upgrading From a Previous Release
+Lithium being the first release supporting TSDR functionality, only fresh installation is possible.However if you want to move to production usage by enabling the store HBase for TSDR usage, you can do it by uninstalling the TSDR with default H2 datastore, restarting the Karaf container and then enabling the TSDR with HBase store as documented in tsdr-hbase-install.doc  
+
+=== Uninstalling TSDR with default H2 datastore 
+To uninstall the TSDR functionality with the default store, you need to do the following from karaf console 
+* feature:uninstall odl-tsdr-all 
+* feature:uninstall odl-tsdr-core 
+* feature:uninstall odl-tsdr-H2-persistence
+
+Its recommended to restart the Karaf container after uninstallation of the TSDR functionality with the default store 
+
index d626be0922e048fea17b6d83c49bb18e91277875..9d1cbaceaa393691c971538ea3dedda090138474 100644 (file)
@@ -1,36 +1,37 @@
-== TSDR H2 data store User Guide
-This document describes how to use the embedded JDBC data store H2
-inside the controller to capture time series data using Time Series Data
-Repository (TSDR) feature in OpenDaylight Lithium release. This document contains
-configuration, administration, management, using, and troubleshooting
+== TSDR H2 datastore User Guide
+This document describes how to use the embedded JPA datastore H2, which is the default datastore (recommended for non-production use case) introduced as part of OpenDaylight Time Series Data Respository(TSDR) project. This store captures the  time series data. This document contains configuration, administration, management, using, and troubleshooting
 sections for the feature.
 
 === Overview
-TBD.
+In the Lithium Release of Time Series Data Repository (TSDR), time series metrics corresponding to the OpenFlow statistics are captured. For users trying out things on their laptop or non-production environment, TSDR functionality can be enabled with default datastore H2 by installing the feature odl-tsdr-all.  
 
-=== <Feature> Architecture
-TBD.
+=== TSDR Architecture
+The following wiki pages capture the TSDR Model/Architecture 
 
-=== Configuring <feature>
-TBD.
+a. https://wiki.opendaylight.org/view/TSDR_Data_Storage_Service_and_Persistence_with_HBase_Plugin
+b. https://wiki.opendaylight.org/view/TSDR_Data_Collection_Service
 
-=== Administering or Managing <feature>
-TBD.
+Note in Lithium the DataCollection Service is implemented just for OpenFlow Statistics metrics. 
 
-=== Tutorials
-TBD.
 
-==== <Tutorial Name>
-TBD.
+=== Configuring TSDR with default datastore H2
+The H2 based storage files get stored automatically in <karaf install folder>/tsdr/ directory. If you want to change the default storage location, the configuration file to change can be found in <karaf install folder>/etc directory. The filename is org.ops4j.datasource-metric.cfg. Change the last portion of the  url=jdbc:h2:./tsdr/metric  to point to different directory. 
+=== Administering or Managing TSDR with default datastore H2 
+Once the TSDR default datastore feature (odl-tsdr-all) is enabled, the TSDR captured OpenFlow statistics metrics can be accessed from Karaf Console by executing the command 
 
-===== Overview
-TBD.
+ tsdr:list <metric-category> <starttimestamp> <endtimestamp>
 
-===== Prerequisites
-TBD.
+wherein
 
-===== Target Environment
-TBD.
+* <metric-category> = any one of the following categories FlowGroupStats, FlowMeterStats, FlowStats, FlowTableStats, PortStats, QueueStats
+* <starttimestamp> = to filter the list of metrics starting this timestamp 
+* <endtimestamp>   = to filter the list of metrics ending this timestamp 
 
-===== Instructions
-TBD.
+If either of <starttimestamp> or <endtimestamp> is not specified, this command displays the latest 1000 metrics captured. 
+
+With TSDR functionality with default H2 datastore you get an additional command 
+
+ tsdr:purgeAll 
+
+This will  purge the entire collected tsdr metrics record.