AMH 社区首页
AMH社区 - 开放自由有价值的社区
[求助帖] [开发日志] centos5.*修复libxml2与重装/安装yum |
|
---|---|
amysql |
amysql 发表于 2013-07-04 14:39:24
[开发日志] centos5.*修复libxml2与重装/安装yum
在libxml2出错的情况下,PHP-FPM启动会报错, # amh php restart /usr/local/php/sbin/php-fpm: error while loading shared libraries: libxml2.so.2: cannot open shared object file: No such file or directory 尝试yum安装libxml2报错: # yum install libxml2 -bash: /usr/bin/yum: No such file or directory yum都没有了,libxml2是与yum存在依赖关系。 下面先修复yum吧。yum是基于python,那先卸载当前python, [root@amysql tmp]# rpm -qa | grep python python-2.4.3-56.el5 ... rpm -e python-2.4.3 --nodeps --force; 不过看到版本也相同。 卸载完成后,shell脚本rpm包安装yum。 #!/bin/bash PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin url='http://mirror.centos.org/centos-5/5/os/i386/CentOS/'; for package in python-2.4.3-56.el5.i386.rpm python-devel-2.4.3-56.el5.i386.rpm python-elementtree-1.2.6-5.i386.rpm python-iniparse-0.2.3-6.el5.noarch.rpm python-setuptools-0.6c5-2.el5.noarch.rpm python-sqlite-1.1.7-1.2.1.i386.rpm python-urlgrabber-3.1.0-6.el5.noarch.rpm rpm-python-4.4.2.3-31.el5.i386.rpm yum-3.2.22-40.el5.centos.noarch.rpm yum-metadata-parser-1.1.2-4.el5.i386.rpm ; do rpm -Uvh $url$package --nodeps --force; done; 再次yum, [root@amysql tmp]# yum 提示没找到libxml2, There was a problem importing one of the Python modules required to run yum. The error leading to this problem was: libxml2.so.2: cannot open shared object file: No such file or directory 安装libxml2, # rpm -Uvh http://mirror.centos.org/centos-5/5/os/i386/CentOS/libxml2-2.6.26-2.1.15.el5_8.6.i386.rpm --nodeps --force 最后,yum更新libxml2 #yum install libxml2 Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package libxml2.i386 0:2.6.26-2.1.21.el5_9.2 set to be updated --> Finished Dependency Resolution Dependencies Resolved ====================================================================== Package Arch Version ====================================================================== Updating: libxml2 i386 2.6.26-2.1.21.el5_9.2 Transaction Summary ====================================================================== Install 0 Package(s) Upgrade 1 Package(s) Total size: 798 k Is this ok [y/N]: y Downloading Packages: Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Updating : libxml2 1/2 Cleanup : libxml2 2/2 Updated: libxml2.i386 0:2.6.26-2.1.21.el5_9.2 Complete! ====================================================================== libxml2、yum修复完成。 /etc/init.d/amh-start 重启面板。
点赞,加油! (0分)
2013-07-04 14:39:24 1
AMH面板 - 好用高效低占用、安全可靠极稳定 |
沧桑 |
:time:表示没看懂
回复
2013-07-05 16:39:33 2
|
ylx |
debian 不影响~
回复
2013-07-05 20:12:12 3
|
nginx |
回复
2013-07-08 05:44:36 4
|