编译安装rsyslog
2018-09-21 本文已影响0人
Miracle001
Linux-centos7.4 系统自带rsylog,无需编译安装
MySQL-5.7 编译安装
PHP-7.0.30 编译安装
Nginx-1.10.2 编译安装
编译安装时,已经安装了"gcc c++"和"gcc-c++"
下载包
libestr-0.1.10.tar.gz http://libestr.adiscon.com/download/
libee-0.4.1.tar.gz http://www.libee.org/download/
liblognorm-2.0.5.tar.gz http://www.liblognorm.com/download/
libfastjson-0.99.8.tar.gz http://download.rsyslog.com/libfastjson/
rsyslog-8.37.0.tar.gz https://www.rsyslog.com/downloads/download-other/
tar xzf libestr-0.1.10.tar.gz
tar xzf libee-0.4.1.tar.gz
tar zxf libfastjson-0.99.8.tar.gz
tar zxf liblognorm-2.0.5.tar.gz
tar zxf rsyslog-8.37.0.tar.gz
cd libestr-0.1.10
./configure CC="gcc -m64" --prefix=/usr --libdir=/usr/lib64 如图1
make && make install 如图2
1
2
cd /root/libee-0.4.1
./configure CC="gcc -m64" --prefix=/usr --libdir=/usr/lib64 PKG_CONFIG_PATH="/usr/lib64/pkgconfig" 如图3
make && make install 如图4
3
4
cd /root/libfastjson-0.99.8
./configure CC="gcc -m64" --prefix=/usr --libdir=/usr/lib64 PKG_CONFIG_PATH="/usr/lib64/pkgconfig" 如图5
make && make install 如图6
5
6
cd /root/liblognorm-2.0.5
./configure CC="gcc -m64" --prefix=/usr --libdir=/usr/lib64 PKG_CONFIG_PATH="/usr/lib64/pkgconfig" 如图7
make && make install 如图8
7
8
编译安装np时,已经装过,无需再安装
zlib-devel
curl-devel
libgcrypt-devel
liblogging-devel 无此包
yum -y install libuuid-devel 需要安装
cd /root/rsyslog-8.37.0
./configure --enable-elasticsearch --enable-mmnormalize --enable-imfile --disable-liblogging-stdlog --enable-mysql --prefix=/usr/local/rsyslog
如图9
make && make install 如图10
9
10
参考文章:https://www.cnblogs.com/redheat/p/7069765.html