這裡安裝flume是因為游戲業務日志搜集和分析用的
1.安裝java 環境
rpm -ivh jdk-8u51-linux-x64.rpm
Preparing... ########################################### [100%]
1:jdk1.8.0_51 ########################################### [100%]
Unpacking JAR files...
rt.jar...
jsse.jar...
charsets.jar...
tools.jar...
localedata.jar...
jfxrt.jar...
plugin.jar...
javaws.jar...
deploy.jar...
2. 下載flume
wget http://www.apache.org/dist/flume/stable/apache-flume-1.6.0-bin.tar.gz
解壓
tar -xf apache-flume-1.6.0-bin.tar.gz -C /usr/local/
重命名目錄
mv apache-flume-1.6.0-bin flume
3.修改環境變量
123456export
JAVA_HOME=
/usr/java/jdk1
.8.0_51
export
JRE_HOME=
/usr/java/jdk1
.8.0_51
/jre
exportCLASSPATH=.:$JAVA_HOME
/lib/dt
.jar:$JAVA_HOME
/lib/tools
.jar
export
PATH=$PATH:
/sbin
:
/bin
:
/usr/sbin
:
/usr/bin
:
/usr/X11R6/bin
:$JAVA_HOME
/bin
export
FLUME_HOME=
/usr/local/flume
export
PATH=$PATH:
/sbin
:
/bin
:
/usr/sbin
:
/usr/bin
:
/usr/X11R6/bin
:$JAVA_HOME
/bin
:$FLUME_HOME
/bin
4.讓環境變量生效
source /etc/profile
5.測試
flume-ng version
Flume 1.6.0
Source code repository: https://git-wip-us.apache.org/repos/asf/flume.git
Revision: 2561a23240a71ba20bf288c7c2cda88f443c2080
Compiled by hshreedharan on Mon May 11 11:15:44 PDT 2015
From source with checksum b29e416802ce9ece3269d34233baf43f
http://xxxxxx/Linuxjc/1156049.html TechArticle