Shell Code
[Email protected] conf]#/usr/local/nginx/sbin/nginx
/usr/local/nginx/sbin/nginx:error while loading shared libraries:libpcre.so.1:cannot open shared object file:no such F Ile or Directory
Confirm that Pcre is installed:
Shell Code
[Email protected] lib]$ Cd/lib
[[email protected] lib]$ ls *pcre*
libpcre.so.0 libpcre.so.0.0.1
[[email protected] nginx]$ Find/-type f-name *libpcre.so.*
To add a soft link:
Shell Code
[Email protected] lib]$ ln-s/lib/libpcre.so.0.0.1/lib/libpcre.so.1
This problem can be resolved in front of the General Linux.
Note: On some operating systems, after installing PCRE, the installation location is/usr/local/lib/*pcre*
There is such a situation on the Redhat 64-bit machine.
On the Redhat 64-bit machine, nginx may read the Pcre file as a/lib64/libpcre.so.1 file.
So instead, use the following soft connection:
Shell Code
[Email protected] ~]$ ln-s/usr/local/lib/libpcre.so.1/lib64/
Nginx:error while loading shared libraries:libpcre.so.1 solution