The contents in this cookbook might change without deprecation before version 1.0
This cookbook helps maintain a Hypertable distributed database in a single node (local DFS) or a cluster of nodes (Hadoop) using a hosted or private Opscode Chef server.
More information:
##Cluster Management
The cluster is managed by capistrano
.
cap -f /opt/hypertable/current/conf/Capfile start
cap -f /opt/hypertable/current/conf/Capfile stop
You can also start
cap -f /opt/hypertable/current/conf/Capfile start_hyperspace
cap -f /opt/hypertable/current/conf/Capfile stop_hyperspace
cap -f /opt/hypertable/current/conf/Capfile start_master
cap -f /opt/hypertable/current/conf/Capfile stop_master
cap -f /opt/hypertable/current/conf/Capfile start_slaves
cap -f /opt/hypertable/current/conf/Capfile stop_slaves
cap -f /opt/hypertable/current/conf/Capfile start_thriftbroker
cap -f /opt/hypertable/current/conf/Capfile start_thriftbroker
cap -f /opt/hypertable/current/conf/Capfile start_thriftbroker_additional
cap -f /opt/hypertable/current/conf/Capfile start_thriftbroker_additional
For more information refer to capistrano
documentation and templates/default/Capfile.erb
template.
##High Availability (HA)
By setting up more than one Hyperspace, Master and Slave nodes using a DFS other than local
.
- SSH root access between nodes for Capistrano access.
- capistrano 2.0 or greater
- capistrano-chef
The user running capistrano cap
command line needs access to a Chef Server. Refer to Chef Documentation.
Include recipe[hypertable]
in your run_list to keep a latent installation of Hypertable in this node.
Include the recipes into your run_list for the node to operate as:
-
Hyperspace
recipe[hypertable::hyperspace]
Sets the node as an active master in the cluster. A Hyperspace node runs a Hyperspace. A cluster requires at least ONE hyperspace, more hyperspaces will be set as replicas. -
Master
recipe[hypertable::master]
Sets the node as an active master in the cluster. A Master node runs a Hyperspace Master. More than one Master nodes in the cluster provide HA. -
Slave
recipe[hypertable::slave]
Sets the node as an active slave in the cluster. A Slave node runs a RangeServer and a ThriftBroker. -
ThriftBroker
recipe[hypertable::thriftbroker]
Sets the node as an active ThriftBroker in the cluster. ThriftBroker is required for the nodes that run HyperTable applications (ht, or thriftbroker client enabled apps).
Due the multinode nature of the
TODO A major structuration of attributes is being required and documented
hypertable
Installs Hypertable
hypertable::admin
Installs Capistrano
hypertable::master
Enables node as Master replica and includes hypertable::monitoring
hypertable::monitoring
Installs required modules for monitoring
hypertable::hyperspace
Enables node as Hyperspace replica
hypertable::slave
Enables node as RangeServer
hypertable::thriftbroker
Enables node as ThriftBroker
- Support other OSes: Fedora, Redhat, CentOS, Debian, OSX.
- Support all Hypertable supported DFS's.
- Run as user...
- Upgrades with data compatibility, as
cap upgrade
does. - Finetune chef notifies and actions.
- Test cases.
Feel free to fork https://github.com/llonchj/cookbook_hypertable and pull request your modifications.
#License and Authors
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2013, by his authors:
- Jordi Llonch llonchj@gmail.com