Sahara Installation Guide¶
We recommend installing sahara in a way that will keep your system in a consistent state. We suggest the following options:
To install with Fuel¶
- Start by following the MOS Quickstart to install and setup OpenStack.
- Enable the sahara service during installation.
To install with RDO¶
- Start by following the RDO Quickstart to install and setup OpenStack.
- Install sahara:
# yum install openstack-sahara
- Configure sahara as needed. The configuration file is located in
/etc/sahara/sahara.conf. For details see Sahara Configuration Guide - Create the database schema:
# sahara-db-manage --config-file /etc/sahara/sahara.conf upgrade head
- Go through Common installation steps and make any necessary changes.
- Start the sahara-all service:
# systemctl start openstack-sahara-all
- (Optional) Enable sahara to start on boot
# systemctl enable openstack-sahara-all
To install into a virtual environment¶
- First you need to install a number of packages with your OS package manager. The list of packages depends on the OS you use. For Ubuntu run:
$ sudo apt-get install python-setuptools python-virtualenv python-dev
For Fedora:
$ sudo yum install gcc python-setuptools python-virtualenv python-devel
For CentOS:
$ sudo yum install gcc python-setuptools python-devel
$ sudo easy_install pip
$ sudo pip install virtualenv
- Setup a virtual environment for sahara:
$ virtualenv sahara-venv
This will install a python virtual environment intosahara-venvdirectory in your current working directory. This command does not require super user privileges and can be executed in any directory where the current user has write permissions.
- You can install the latest sahara release from pypi:
$ sahara-venv/bin/pip install sahara
Or you can get a sahara archive from http://tarballs.openstack.org/sahara/ and install it using pip:
$ sahara-venv/bin/pip install 'http://tarballs.openstack.org/sahara/sahara-master.tar.gz'
Note thatsahara-master.tar.gzcontains the latest changes and might not be stable at the moment. We recommend browsing http://tarballs.openstack.org/sahara/ and selecting the latest stable release.
- After installation you should create a configuration file from the sample
file located in
sahara-venv/share/sahara/sahara.conf.sample-basic:
$ mkdir sahara-venv/etc
$ cp sahara-venv/share/sahara/sahara.conf.sample-basic sahara-venv/etc/sahara.conf
Make any necessary changes tosahara-venv/etc/sahara.conf. For details see Sahara Configuration Guide
Common installation steps¶
The steps below are common to both the RDO and virtual environment installations of sahara.
- If you use sahara with a MySQL database, then for storing big job binaries
in the sahara internal database you must configure the size of the maximum
allowed packet. Edit the
my.cnffile and change themax_allowed_packetparameter as follows:
...
[mysqld]
...
max_allowed_packet = 256M
Then restart the mysql server to ensure these changes are active.
- Create the database schema:
$ sahara-venv/bin/sahara-db-manage --config-file sahara-venv/etc/sahara.conf upgrade head
- To start sahara call:
$ sahara-venv/bin/sahara-all --config-file sahara-venv/etc/sahara.conf
- For sahara to be accessible in the OpenStack Dashboard and for python-saharaclient to work properly you must register sahara in the Identity service catalog. For example:
keystone service-create --name sahara --type data-processing \
--description "Sahara Data Processing"
keystone endpoint-create --service sahara --region RegionOne \
--publicurl "http://10.0.0.2:8386/v1.1/%(tenant_id)s" \
--adminurl "http://10.0.0.2:8386/v1.1/%(tenant_id)s" \
--internalurl "http://10.0.0.2:8386/v1.1/%(tenant_id)s"
- For more information on configuring sahara with the OpenStack Dashboard please see OpenStack Dashboard Configuration Guide.
Notes:¶
Ensure that your operating system is not blocking the sahara port (default: 8386). You may need to configure iptables in CentOS and other Linux distributions to allow this access.
To get the list of all possible options run:
$ sahara-venv/bin/python sahara-venv/bin/sahara-all --help
Further, consider reading Getting Started for general sahara concepts and Provisioning Plugins for specific plugin features/requirements.