Storm实战之监听节点服务

2019年7月16日 0 条评论 736 次阅读 0 人点赞
  • 创建数据软件文件夹
mkdir -p /hadoop/dc/ && cd /hadoop/dc/
  • 下载资源文件并解压
wget http://software.cdn.ttxit.com/opensource/daemontools-0.76.tar.gz && tar -xvzf daemontools-0.76.tar.gz
  • 编译源码生成可用应用
cd /hadoop/dc/admin/daemontools-0.76/
./package/install

如果出现以下错误

./makelib unix.a alloc.o alloc_re.o buffer.o buffer_0.o buffer_1.o \
    buffer_2.o buffer_get.o buffer_put.o buffer_read.o buffer_write.o \
    coe.o env.o error.o error_str.o fd_copy.o fd_move.o fifo.o lock_ex.o \
    lock_exnb.o ndelay_off.o ndelay_on.o open_append.o open_read.o \
    open_trunc.o open_write.o openreadclose.o pathexec_env.o \
    pathexec_run.o prot.o readclose.o seek_set.o sgetopt.o sig.o \
    sig_block.o sig_catch.o sig_pause.o stralloc_cat.o stralloc_catb.o \
    stralloc_cats.o stralloc_eady.o stralloc_opyb.o stralloc_opys.o \
    stralloc_pend.o strerr_die.o strerr_sys.o subgetopt.o wait_nohang.o \
    wait_pid.o
./load envdir unix.a byte.a
/usr/bin/ld: errno: TLS definition in /lib64/libc.so.6 section .tbss mismatches non-TLS reference in envdir.o
/lib64/libc.so.6: could not read symbols: Bad value
collect2: ld 返回 1
make: *** [envdir] 错误 1

修改src/error.h文件第六行中的extern int errno;修改为#include <errno.h>重新编译即可提示下面信息表示成功编译安装

cat systype compile load >> sysdeps
grep sysdep direntry.h >> sysdeps
grep sysdep haswaitp.h >> sysdeps
grep sysdep hassgact.h >> sysdeps
grep sysdep hassgprm.h >> sysdeps
grep sysdep select.h >> sysdeps
grep sysdep uint64.h >> sysdeps
grep sysdep iopause.h >> sysdeps
grep sysdep hasmkffo.h >> sysdeps
grep sysdep hasflock.h >> sysdeps
grep sysdep hasshsgr.h >> sysdeps
Copying commands into ./command...
Creating symlink daemontools -> daemontools-0.76...
Making command links in /command...
Making compatibility links in /usr/local/bin...
Creating /service...
Adding svscanboot to inittab...
init should start svscan now.
  • 创建storm服务监听脚本
mkdir -p /hadoop/dc/apache-storm-1.2.2/service/supervisor && cd /hadoop/dc/apache-storm-1.2.2/service/supervisor

supervisor脚本配置

vim /hadoop/dc/apache-storm-1.2.2/service/supervisor/run

在文件中增加以下内容

#!/bin/bash
exec 2>&1
exec /hadoop/dc/apache-storm-1.2.2/bin/storm supervisor

启动监听脚本

supervise /hadoop/dc/apache-storm-1.2.2/service/supervisor &

nimbus脚本配置

# 创建文件夹
mkdir -p /hadoop/dc/apache-storm-1.2.2/service/nimbus
# 创建监听服务
vim /hadoop/dc/apache-storm-1.2.2/service/supervisor/nimbus/run

#!/bin/bash
exec 2>&1
exec /hadoop/dc/apache-storm-1.2.2/bin/storm nimbus

ui脚本配置

# 创建文件夹
mkdir -p /hadoop/dc/apache-storm-1.2.2/service/ui
# 创建监听服务
vim /hadoop/dc/apache-storm-1.2.2/service/supervisor/ui/run

#!/bin/bash
exec 2>&1
exec /hadoop/dc/apache-storm-1.2.2/bin/storm ui
qianmoQ

qianmoQ

这个人太懒什么东西都没留下

文章评论(0)