您的位置:首页 > 运维架构 > Nginx

nginx: error while loading shared libraries: libGeoIP.so.1

2015-05-11 22:01 555 查看
wget http://geolite.maxmind.com/download/geoip/api/c/GeoIP.tar.gz
wget http://geolite.maxmind.com/download/geoip/database/GeoLiteCity.dat.gz
wget http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz

# tar xzvf GeoIP.tar.gz
# cd GeoIP-1.4.8
# ./configure
# make && make install

# nginx -t
nginx: error while loading shared libraries: libGeoIP.so.1: cannot open shared object file: No such file or directory

# locate libGeoIP.so.1
-bash: locate: command not found
yum -y install mlocate
-------------------------------

# locate libGeoIP.so.1
locate: can not stat () `/var/lib/mlocate/mlocate.db': No such file or directory
updatedb
-------------------------------

# locate libGeoIP.so.1
/root/GeoIP-1.4.8/libGeoIP/.libs/libGeoIP.so.1
/root/GeoIP-1.4.8/libGeoIP/.libs/libGeoIP.so.1.4.8
/usr/local/lib/libGeoIP.so.1
/usr/local/lib/libGeoIP.so.1.4.8

# echo"/usr/local/lib" >> /etc/ld.so.conf
# ldconfig

# nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  web开发 报错 GeoIP
相关文章推荐