Error while loading shared libraries: 'libpcre.so.0: cannot open shared object file: No such file or directory'

user908798 picture user908798 · Dec 14, 2011 · Viewed 50k times · Source

I just installed Passenger 3.0.11 and nginx and got this error:

Starting nginx: /opt/nginx/sbin/nginx: error while loading shared libraries: libpcre.so.0: cannot open shared object file: No such file or directory

Answer

Simon Ji picture Simon Ji · Jan 4, 2012

I got the same error, and I fixed the problem by running sudo ldconfig.