1.1安裝tomcat-native的時候提示apr和openssl版本過低無法安裝

科技小能手發表於2017-11-12

由於在安裝tomcat-native軟體做關於tomcat與mysql資料庫通過nvtive提升tomcat效能的時候編譯安裝tc-native由於相關軟體版本過低,導致無法繼續安裝,以下是解決思路過程和方法,及缺啥升級啥的原則進行解決思路.完成了相關的工作,

# wget http://archive.apache.org/dist/apr/apr-1.5.2.tar.gz
# wget http://archive.apache.org/dist/apr/apr-util-1.6.1.tar.bz2
# wget http://archive.apache.org/dist/apr/apr-iconv-1.2.2.tar.gz

解決環境依賴:

# yum -y install autoconf
# yum -y install libtool
# tar xvf apr-1.5.2.tar.gz
# cd apr-1.5.2
# ./configure --prefix=/usr/apr
# make
# make install
# echo "/usr/apr/lib" >> /etc/ld.so.conf
```~~
安裝apr-util

tar jxvf apr-util-1.6.1.tar.bz2

./configure –prefix=/usr/local/apr-util –with-apr=/usr/apr/

#make

#make install

echo “/usr/local/apr-util/lib” >> /etc/ld.so.conf

安裝apr-iconv

cd apr-iconv-1.2.2

./configure –prefix=/usr/local/apr-iconv –with-apr=/usr/apr/

make

make install

echo “/usr/local/apr-iconv/lib/iconv” >> /etc/ld.so.conf

./configure –with-apr=/usr/bin/apr-1-config

–with-java-home=/usr/java/jdk-9.0.1/

–with-ssl=yes

–prefix=/usr/local/native

Error1:configure: error: Found APR 1.3.9. You need version 1.4.3 or newer

“` installed.由於安裝的系統自帶apr版本過低,,需要先升級相關軟體版再重新編譯.

# ./configure --with-apr=/usr/apr/ --with-java-home=/usr/java/jdk-9.0.1/ --with-ssl=yes --prefix=/usr/local/native
Error2: configure: error: Your version of OpenSSL is not compatible with this version of tcnative 

Openssl不滿足要求,需要升級:

# wget https://www.openssl.org/source/openssl-1.1.0g.tar.gz
# tar xvf openssl-1.1.0g.tar.gz
# cd openssl-1.1.0g
# ./config --prefix=/usr/local/openssl
# ./config -t
# make      編譯

# make install 安裝


本文轉自 CARYFLASH 51CTO部落格,原文連結:
http://blog.51cto.com/maoxiaoxiong/2051202



相關文章