sahara-image-elements/elements
Pino Toscano 4cd8af1b4e Use the dib-utils repository too
Newer diskimage-builder versions require the external dib-utils
repository, as dib-run-parts has been moved there.

In preparation for using a newer diskimage-builder, checkout and use the
dib-utils repository; thus dib-run-parts from dib-utils will be used
instead of the one currently in diskimage-builder (if using a version
shipping it), which works the same way.
The dib-utils version used is the current last one, 0.0.9.

Change-Id: I7f537486279c40123b65d8206f9405774e9ebcbf
2015-03-20 14:31:26 +01:00
..
apt-mirror Fix bashate errors 2014-10-14 12:49:42 +04:00
centos-mirror Fix bashate errors 2014-10-14 12:49:42 +04:00
disable-firewall Fix building fedora images 2015-01-13 12:51:18 +03:00
fedora-mirror Fix bashate errors 2014-10-14 12:49:42 +04:00
hadoop Merge "Fix datanode launch performance caused by entropy pool depletion" 2015-03-16 13:42:07 +00:00
hadoop-cdh Rename more 0-check scripts to avoid duplicate names 2015-02-27 13:40:57 +01:00
hadoop-cloudera Fix building RHEL images for CDH plugin 2015-02-22 17:00:32 +03:00
hadoop-hdp Simplification: wget+rpm -> rpm 2014-12-04 10:02:09 -05:00
hadoop-mapr mapr: use disable-firewall only on centos 2015-03-05 12:42:28 +01:00
hive Rename a couple of scripts to avoid duplicated names 2015-02-23 17:26:07 +01:00
java Fix bashate errors 2014-10-14 12:49:42 +04:00
mysql Fix bashate errors 2014-10-14 12:49:42 +04:00
oozie Rename a couple of scripts to avoid duplicated names 2015-02-23 17:26:07 +01:00
openjdk/install.d Install openjdk-jdk instead openjdk-jre for Ubuntu 2015-03-02 16:17:57 +03:00
redhat-lsb/pre-install.d Add CentOS support 2013-12-06 16:04:25 +04:00
root-passwd Fix bashate errors 2014-10-14 12:49:42 +04:00
sahara-version/install.d Use the dib-utils repository too 2015-03-20 14:31:26 +01:00
spark spark: small syntax hiccup in the vars check 2015-03-09 10:46:25 +01:00
ssh Fix bashate errors 2014-10-14 12:49:42 +04:00
storm Rename more 0-check scripts to avoid duplicate names 2015-02-27 13:40:57 +01:00
swift_hadoop Add the swift_hadoop element to Spark images 2015-01-16 15:49:03 -05:00
updater/install.d Add update script for yum based images 2015-03-03 11:39:08 +03:00
zookeeper Creating Zookeeper symlink folder name to not use version 2015-02-12 13:39:40 -03:00
.gitignore Add a .gitignore. 2013-09-02 12:58:57 +04:00
README.rst Renaming all Savanna references to Sahara 2014-03-13 15:26:47 +04:00

README.rst

Diskimage-builder tools for creation cloud images

Steps how to create cloud image with Apache Hadoop installed using diskimage-builder project:

  1. Clone the repository "https://github.com/openstack/diskimage-builder" locally. Note: Make sure you have commit 43b96d91 in your clone, it provides a mapping for default-jre.
git clone https://github.com/openstack/diskimage-builder
  1. Add ~/diskimage-builder/bin/ directory to your path (for example, PATH=$PATH:/home/$USER/diskimage-builder/bin/ ).
  2. Export the following variable ELEMENTS_PATH=/home/$USER/diskimage-builder/elements/ to your .bashrc. Then source it.
  3. Copy file "img-build-sudoers" from ~/disk-image-builder/sudoers.d/ to your /etc/sudoers.d/.
chmod 440 /etc/sudoers.d/img-build-sudoers
chown root:root /etc/sudoers.d/img-build-sudoers
  1. Export sahara-elements commit id variable (from sahara-extra directory):
export SAHARA_ELEMENTS_COMMIT_ID=`git show --format=%H | head -1`
  1. Move elements/ directory to disk-image-builder/elements/
mv elements/*  /path_to_disk_image_builder/diskimage-builder/elements/
  1. Export DIB commit id variable (from DIB directory):
export DIB_COMMIT_ID=`git show --format=%H | head -1`
  1. Call the following command to create cloud image is able to run on OpenStack:

8.1. Ubuntu cloud image

JAVA_FILE=jdk-7u21-linux-x64.tar.gz DIB_HADOOP_VERSION=1.2.1 OOZIE_FILE=oozie-4.0.0.tar.gz disk-image-create base vm hadoop oozie ubuntu root-passwd -o ubuntu_hadoop_1_2_1

8.2. Fedora cloud image

JAVA_FILE=jdk-7u21-linux-x64.tar.gz DIB_HADOOP_VERSION=1.2.1 OOZIE_FILE=oozie-4.0.0.tar.gz DIB_IMAGE_SIZE=10 disk-image-create base vm fedora hadoop root-passwd oozie -o fedora_hadoop_1_2_1

Note: If you are building this image from Ubuntu or Fedora 18 OS host, you should add element 'selinux-permissive'.

JAVA_FILE=jdk-7u21-linux-x64.tar.gz DIB_HADOOP_VERSION=1.2.1 OOZIE_FILE=oozie-4.0.0.tar.gz DIB_IMAGE_SIZE=10 disk-image-create base vm fedora hadoop root-passwd oozie selinux-permissive -o fedora_hadoop_1_2_1

In this command 'DIB_HADOOP_VERSION' parameter is version of hadoop needs to be installed. You can use 'JAVA_DOWNLOAD_URL' parameter to specify download link for JDK (tarball or bin). 'DIB_IMAGE_SIZE' is parameter that specifes a volume of hard disk of instance. You need to specify it because Fedora and CentOS don't use all available volume. If you have already downloaded the jdk package, move it to "elements/hadoop/install.d/" and use its filename as 'JAVA_FILE' parameter. In order of working EDP components with Sahara DIB images you need pre-installed Oozie libs. Use OOZIE_DOWNLOAD_URL to specify link to Oozie archive (tar.gz). For example we have built Oozie libs here: http://sahara-files.mirantis.com/oozie-4.0.0.tar.gz If you have already downloaded archive, move it to "elements/oozie/install.d/" and use its filename as 'OOZIE_FILE' parameter.