云计算实战 (海量日志管理)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    

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

       http://hi.baidu.com/maydaygmail/blog/item/9e38993bf4a176dc7c1e716c.html

五、安装 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"

[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 上 写得相当详细。

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

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章