Pages

Running storm cluster in production mode


Running storm cluster in production mode-

Follow the given steps to run storm cluster in production mode-

a) Run zookepper on nimbus machine.
     To run zookeeper follow the given steps-

          $ cd /usr/share/zookeeper/bin
          $ sudo ./zkServer.sh start

If yo see the output something like this, it means your zooleeper is running.

         JMX enabled by default
         Using config: /etc/zookeeper/conf/zoo.cfg
         Starting zookeeper ... STARTED

you can also weather zookeooper is started or not-

           $ sudo ./zkServer.sh status

b) Start the nimbus daemon on master machine. To start the
     nimbus daemon type the following command on terminal-

      $ storm nimbus

This should start the  "nimbus" daemon on your master node.

c) Run "jps' command and check the output of jps, to check wheather nimbus
    daemon is started or not.

      $ jps nimbus

      5501 Jps
      5396 nimbus


d)  Start the supervisor daemon on worker machine. To start the supervisor
   daemon on worker machine type the following command on terminal-

     $ storm supervisor

e) Run "jps' command and check the output of jps, to check wheather nimbus
    daemon is started or not.

      $ jps nimbus

      5501 Jps
      5200supervisor
f) Run storm ui (a site you can access from the browser that gives diagnostics on the cluster and   topologies)

      $ storm ui
      Type the url in your web browser http://{nimbus host}:8080

Here is a screenshot of the Storm UI as of version 0.8.2

storm ui

Adding New supervisor(worker node) on existing storm cluster


 Follow the given steps to add supervisor(worker node) 

a) Install Java ( same version as your existing cluster)

Note: To install java on linux/ubuntu folllow the given link
http://www.techie-knowledge.co.in/2013/08/installing-java-on-linuxubuntu.html
b) Install storm(storm-0.8.2 , same version as your existing cluster)

 

 Install the following native library-


a) To install ZeroMQ type the following command
 
  • make sure that libtool, autoconf, automake, g++ is installed on your machine
  •  wget http://download.zeromq.org/zeromq-2.1.7.tar.gz
  • tar -xvzf zeromq-2.1.7.tar.gz
  •  cd zeromq-2.1.7
  • ./configure 
   NOTE: If you see this error mesage on your terminal
   configure: error: cannot link with -luuid, install uuid-dev, then install theuuid-dev
   by using the command
    sudo apt -get install uuid-dev  
  • make
  • sudo make install

b) To install JZMQ,

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

c) set the storm.yaml file.

#storm.yaml
 // name of the machine where you install zookeeper in my case this is nimbus

storm.zookeeper.servers:
       - "nimbus"
#     - "server2" // name of the machine which you make your nimbus or master
#          machine in my case this is also "nimbus"

nimbus.host: "nimbus"

supervisor.slots.ports:
# - 6700
#- 6701 java.library.path: "/usr/local/lib:/opt/local/lib:/usr/lib"

 d) Add /etc/hosts file.