Nginx: error while loading shared libraries: libpcre.so.1解決

    Shell代碼linux

    [root@tmsapp65 conf]# /usr/local/nginx/sbin/nginxnginx

    /usr/local/nginx/sbin/nginx: error while loading shared libraries: libpcre.so.1: cannot open shared object file: No such file or directoryapp

    確認已經安裝PCRE:oop

    Shell代碼spa

    [ew69@SCLABHADOOP01 lib]$ cd /lib操作系統

    [ew69@SCLABHADOOP01 lib]$ ls *pcre*hadoop

    libpcre.so.0 libpcre.so.0.0.1object

    [hadoop@SCLABCLUS01 nginx]$ find / -type f -name *libpcre.so.*file

    添加軟連接:error

    Shell代碼

    [root@tmsapp65 lib]$ ln -s /lib/libpcre.so.0.0.1 /lib/libpcre.so.1

    前面在通常的linux上能夠解決此問題.

    注: 在有的操做系統上面,安裝pcre後,安裝的位置爲/usr/local/lib/*pcre*

    在redhat 64位機器之上有這樣的狀況.

    在redhat 64位機器上, nginx可能讀取的pcre文件爲/lib64/libpcre.so.1文件.

    因此在改用下面的軟鏈接:

    Shell代碼

    [root@tmsapp65 ~]$ ln -s /usr/local/lib/libpcre.so.1 /lib64/

相關文章
相關標籤/搜索