Skip to main content

StandAlone Apache Storm Installation in Ubuntu 14.04 LTS

Deploying Apache Storm 


1) If Java 7 is not present, please install it.

2) Zookeeper Installation

Download zookeeper-3.4.6 from Apache site
      $ tar -xvf zookeeper-3.4.6.tar.gz
      $ cd zookeeper-3.4.6/
      $ cp conf/zoo_sample.cfg conf/zoo.cfg
      $ bin/zkServer.sh start

3) Storm Cluster Installation

Download the storm tarball from official Apache Mirror. 
Untar it.

      $ tar xzvf apache-storm-0.9.2-incubating.tar.gz

Move to new directory.

      $ sudo cp -R apache-storm-0.9.2-incubating /usr/lib/

Go to /usr/lib/apache-storm-0.9.2-incubating/ and configure storm.yaml present in conf folder, add the followuing line, this folder must have write permissions too.

storm.zookeeper.servers:
    - "localhost"
storm.zookeeper.port: 2181
nimbus.host: "localhost"
storm.local.dir: "/var/stormtmp"     
java.library.path: "/usr/lib/jvm/java-7-openjdk-amd64"
supervisor.slots.ports:
    - 6700
    - 6701
    - 6702
    - 6703
worker.childopts: "-Xmx768m"
nimbus.childopts: "-Xmx512m"

supervisor.childopts: "-Xmx256m"

4) Installing Native Dependencies

Before installing ZeroMQ and JZMQ make sure following dependencies are installed on Ubuntu system

libtool
autoconf
pkg-config

In any case to be sure just run following command on terminal

$ sudo apt-get install libtool autoconf pkg-config

(i) ZeroMQ - Download the ZeroMQ tarball from official ZeroMQ site

    $ wget http://download.zeromq.org/zeromq-4.0.4.tar.gz
    $ Untar it tar –xzf zeromq-2.1.7.tar.gz
    $ cd zeromq-2.1.7
    $ ./configure
    $ make
    $ sudo make install

(ii) JZMQ - Clone JZMQ from official git repository

    $ git clone https://github.com/zeromq/jzmq.git
    $ cd jzmq
    $ ./autogen.sh
    $ ./configure
    $ make
    $ sudo make install

5) Starting Storm Cluster and submitting the topology

Then start Storm Cluster by starting master(nimbus) and worker nodes(supervisor).
Go to the ‘bin’ directory of the Storm installation and execute following command. [separate command line window]

    $ sudo ./storm nimbus

To start worker i.e. supervisor go to the ‘bin’ directory of the Storm installation and execute following command. [separate command line window]
    
    $ sudo ./storm supervisor    

6) Upload topology using Storm Client

To upload topology to Storm Cluster go to the ‘bin’ directory of the Storm installation and execute following command. [separate command line window]

    $ sudo ./storm jar <path-to-topology-jar> <class-with-the-main> <arg1> <arg2> ...<argN>

A) <path-to-topology-jar>: is the complete path to the complied jar where your topology code and all your libraries are.
B) <class-with-the-main>: will be the class in jar file having main method where the StormSubmitter is executed.
C) <arg1> <arg2> <argN>:  rest of the arguments will be the parameter that will be received by main method.

Comments

Post a Comment

Popular posts from this blog

Multi Node Apache Kafka 0.9 in Linux

Manually Deploying Apache Kafka Please Install Java version 8 before proceeding the Kafka installation. 1) Edit the  /etc/hostname in each  node.         $  vi /etc/hostname                    kafka1 or kafka2 or kafka3 2) Check hostname.         $ hostname 3)  Confirm everything went right.      $ sudo hostname -F /etc/hostname 4) Now edit /etc/hosts to point one node to other nodes and do the same in each node.      $ nano /etc/hosts          127.0.0.1       localhost 127.0.1.1       ubuntu <IP of node1 >   kafka1 <IP of node2>    kafka2 <IP of node3>    kafka3 # The following lines are desirable for IPv6 capable hosts ::1     localhost ip6-localhost ip6-loopba...

Play Song From Terminal

1) sudo apt-get install sox For formating to mp3 and other extension we need decoder of Sox 2 ) sudo apt - get install libsox - fmt - mp3 Now go to the directory of your Music and give command as play *.mp3 it will play music and if you want to go to another song then press `ctrl + c`  To terminate press `ctrl+c+c` Thanks For seeing and i hope you like this  ENJOY ------------------------------------- Please if you like this Post so do not Forget to Comment and like