1.修改环境变量 export LD_LIBRARY_PATH=path_name 2.修改配置文件 修改/etc/ld.so.conf的内容在最后添加库加载的新的路径,然后执行:ldconfig 使配置生效。