云计算实战 (海量日志管理)hadoop + scribe -- scribe 介绍和安装

scribe 介绍:

 

scribe 是facebook 开源的分布式日志系统 。 可以用java 借助log4j 向分布式scribe 写入日志。

 

安装环境: centos5.2

 

所需软件:

 

 

安装过程:

一、输入gcc –v 检查gcc版本是否>3.3.5

       是,则继续下一步。否,则安装gcc

二、安装ruby python 

python 用默认安装路径。Ruby 推荐使用默认路径

    安装过程均为./configure  make  make install

三、安装lievent  

解压安装即可

       安装过程为./configure  make  make install

四、安装 boost    

解压安装即可(不可改路径)

       安装过程为./configure  make  make install  (安装用时较长)

五、安装 php libxml2 

先安装libxml2 php依赖它) 在安装php(默认安装路径)

       安装过程均为./configure  make  make install

六、安装facebook 服务-- thrift fb303

       首先解压并进入thrift 目录      

./bootstrap.sh

./configure –with-boost=/usr/local/include/boost/ -- with-php-config=/phppath /bin/php-config

make

make install    

thrift 安装完毕。

在当前目录 cd contrib/fb303/

./bootstrap.sh

./configure –with-boost=/usr/local/include/boost/

make

make install

fb303安装完毕。

七、安装scribe

       ./bootstrap

./configure –with-boost=/usr/local/include/boost/

make

make install

 

安装完毕。

 

配置环境变量 :

BOOST_ROOT=/usr/local/include/boost/

LD_LIBRARY_PATH=/usr/local/include/boost/lib::/usr/lob:/usr/local/lib

测试:

        /usr/local/bin/scribed  [scribe 解压目录]/examples/example1.conf 


    
回车会出现:

     [Sun Oct 31 23:37:38 2010] "STATUS: STARTING"

Java代码 复制代码
  1. [Sun Oct 31 23:37:38 2010"STATUS: configuring"    
  2. [Sun Oct 31 23:37:38 2010"got configuration data from file </home/setups/scribe/scribe/examples/example1.conf>"    
  3. [Sun Oct 31 23:37:38 2010"CATEGORY : default"    
  4. [Sun Oct 31 23:37:38 2010"Creating default store"    
  5. [Sun Oct 31 23:37:38 2010"configured <1> stores"    
  6. [Sun Oct 31 23:37:38 2010"STATUS: "    
  7. [Sun Oct 31 23:37:38 2010"STATUS: ALIVE"    
  8. [Sun Oct 31 23:37:38 2010"Starting scribe server on port 1463"    
  9. Thrift: Sun Oct 31 23:37:38 2010 libevent 2.0.7-rc method epoll  
[Sun Oct 31 23:37:38 2010] "STATUS: configuring" 
[Sun Oct 31 23:37:38 2010] "got configuration data from file </home/setups/scribe/scribe/examples/example1.conf>" 
[Sun Oct 31 23:37:38 2010] "CATEGORY : default" 
[Sun Oct 31 23:37:38 2010] "Creating default store" 
[Sun Oct 31 23:37:38 2010] "configured <1> stores" 
[Sun Oct 31 23:37:38 2010] "STATUS: " 
[Sun Oct 31 23:37:38 2010] "STATUS: ALIVE" 
[Sun Oct 31 23:37:38 2010] "Starting scribe server on port 1463" 
Thrift: Sun Oct 31 23:37:38 2010 libevent 2.0.7-rc method epoll

 

okay  scribe 服务已启动。 (这个不只是测试,也是启动scribe 服务的方式。)

 补充:

  关于scribe 的安装 在下载目录下有个有个readme 写的很详细(可能没我写的实用^^)

  scribe的启动和集群测试,均在examples 目录下的redme 上 写得相当详细。

  如果大家在集群上有疑问,可交流^^

 

转载 http://www.javaeye.com/topic/796858

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值