天天看點

storm的叢集安裝與配置

 storm叢集安裝

機器:(storm及zookeeper都是這3台機器)

192.168.80.20

192.168.80.21

192.168.80.22

須要準備的軟體有:

zookeeper(zookeeper-3.4.4.tar.gz),storm(storm-0.8.1.zip) ,jdk

1、配置zookeeper

這裡就不介紹了!

2、配置storm

解壓storm

進入conf檔案夾,編輯storm.yaml檔案

########## These MUST be filled in for a storm configuration

 storm.zookeeper.servers:

     - "192.168.80.20"

     - "192.168.80.21"

     - "192.168.80.22"

 nimbus.host: "192.168.80.20"

 storm.local.dir: "/opt/storm/data"

 ##### These may optionally be filled in:

# List of custom serializations

# topology.kryo.register:

#     - org.mycompany.MyType

#     - org.mycompany.MyType2: org.mycompany.MyType2Serializer

#

## List of custom kryo decorators

# topology.kryo.decorators:

#     - org.mycompany.MyDecorator

# Locations of the drpc servers

# drpc.servers:

    # - "127.0.0.1"

     #- "server2"

## to nimbus 

#nimbus.childopts: "-Xmx1024m" 

## to supervisor 

#supervisor.childopts: "-Xmx1024m" 

## to worker 

#worker.childopts: "-Xmx768m"

3、配置完畢之後。開始啟動zookeeper和storm

啟動zookeeper

bin/zkServer.sh start

啟動storm

bin/storm nimbus(在192.168.80.20啟動主節點) 或者 nohup bin/storm nimbus > /dev/null 2>&1 &

bin/storm supervisor (在192.168.80.21啟動從節點)或者  nohup

bin/storm

supervisor > /dev/null 2>&1 &

bin/storm

supervisor (在192.168.80.22啟動從節點)或者 nohup

bin/storm supervisor >

/dev/null 2>&1 &

bin/storm ui (在192.168.80.20啟動界面) 或者 nohup

bin/storm ui >

浏覽器打開: http://192.168.80.20:8080 檢視叢集的執行狀态

搞定了!

。!!!

。!