`
hitgnu
  • 浏览: 94576 次
  • 性别: Icon_minigender_1
  • 来自: 苏州-->上海
社区版块
存档分类
最新评论

Apache Storm安装简明手册

阅读更多

一、JDK安装:
1.    下载JDK(版本7):http://download.oracle.com/otn-pub/java/jdk/7u71-b14/jdk-7u71-linux-x64.rpm
2.    安装
    sudo rpm -ivh jdk-7u71-linux-x64.rpm
    sudo vi /etc/profile   

export JAVA_HOME=/usr/java/jdk1.7.0_71
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar

    source /etc/profile
二、Zookeeper安装
1.    下载并解压安装Zookeeper:http://zookeeper.apache.org/releases.html
2.    Zookeeper集群部署:
根据Zookeeper集群节点情况,在conf目录下创建Zookeeper配置文件zoo.cfg(示例如下)

tickTime=2000
initLimit=10
syncLimit=5
dataDir=/opt/zookeeper-3.4.6/data
clientPort=2181

server.1=ip1:2888:3888
server.2=ip2:2888:3888
server.3=ip3:2888:3888

 
 
三、storm 0.9.3安装
1.    下载安装包:http://www.apache.org/dyn/closer.cgi/storm/apache-storm-0.9.3/apache-storm-0.9.3.tar.gz
2.    解压缩安装包到安装目录
3.    修改conf目录下的配置文件storm.yaml
storm.yaml示例

storm.zookeeper.servers:
  - "zk-host1"
  - "zk-host2"
  - "zk-host3"
storm.zookeeper.port: 2181
storm.zookeeper.root: "/storm-0.9.3"
storm.local.dir: "/opt/apache-storm-0.9.3/storm-local"
storm.cluster.mode: distributed

storm.messaging.netty.server_worker_threads: 1
storm.messaging.netty.client_worker_threads: 1
storm.messaging.transport: "backtype.storm.messaging.netty.Context"
storm.messaging.netty.buffer_size: 52428800
storm.messaging.netty.max_retries: 10
storm.messaging.netty.min_wait_ms: 5000
storm.messaging.netty.max_wait_ms: 10000

logviewer.port: 80
logviewer.appender.name: "A1"

nimbus.host: "host-ip1"

worker.childopts: "-Xmx1024m -Xms1024m -Xmn500m -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:NewSize=128m -XX:CMSInitiatingOccupancyFraction=70 -XX:-CMSConcurrentMTEnabled -Djava.net.preferIPv4Stack=true"
supervisor.slots.ports:
  - 6700
  - 6701
  - 6702

topology.debug: false
topology.executor.receive.buffer.size: 16384
topology.executor.send.buffer.size: 16384

 
注:如果与其他storm集群共用zk,请确认不同的集群使用各自不同的“storm.zookeeper.root”设置,默认为:"/storm"
4.    启动
在nimbus机器执行(cd $STORM_HOME)

bin/storm nimbus >/dev/null 2>&1 &
bin/storm ui >/dev/null 2>&1 &

 
在supervisor机器执行(cd $STORM_HOME):

bin/storm supervisor> /dev/null 2>&1 &
bin/storm logviewer > /dev/null 2>&1 &

 
 

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics