在CentOS 6.5上将PHP 5.4降级到5.3?

前端之家收集整理的这篇文章主要介绍了在CentOS 6.5上将PHP 5.4降级到5.3?前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我试图将 PHP从5.5.8降级到5.3.x.
我试过这个,但它对我有用.
  1. yum downgrade PHP

我得到的错误

  1. Loaded plugins: fastestmirror,refresh-packagekit,security
  2. Setting up Downgrade Process
  3. Loading mirror speeds from cached hostfile
  4. * Webmin: webmin.mirror.somersettechsolutions.co.uk
  5. * base: centos.excellmedia.net
  6. * epel: epel.mirror.net.in
  7. * extras: centos.excellmedia.net
  8. * updates: centos.excellmedia.net
  9. No Match for available package: PHP-5.3.3-26.el6.x86_64
  10. Nothing to do

我也试过这个,但即便是这个对我有用.

  1. sudo yum downgrade PHP PHP-common PHP-cli

我得到的错误日志是

  1. Loaded plugins: fastestmirror,security
  2. Setting up Downgrade Process
  3. Loading mirror speeds from cached hostfile
  4. * Webmin: webmin.mirror.somersettechsolutions.co.uk
  5. * base: centos.excellmedia.net
  6. * epel: epel.mirror.net.in
  7. * extras: centos.excellmedia.net
  8. * updates: centos.excellmedia.net
  9. No Match for available package: PHP-5.3.3-26.el6.x86_64
  10. Resolving Dependencies
  11. --> Running transaction check
  12. ---> Package PHP-cli.x86_64 0:5.3.3-27.el6_5 will be a downgrade
  13. ---> Package PHP-cli.x86_64 0:5.5.8-1.el6.remi will be erased
  14. ---> Package PHP-common.x86_64 0:5.3.3-27.el6_5 will be a downgrade
  15. ---> Package PHP-common.x86_64 0:5.5.8-1.el6.remi will be erased
  16. ---> Package PHP-pecl-zip.x86_64 0:1.12.4-1.el6.remi.5.5 will be obsoleted
  17. --> Finished Dependency Resolution
  18. Error: Package: PHP-pecl-memcached-2.1.0-7.el6.remi.5.5.x86_64 (@remi-PHP55)
  19. Requires: PHP(api) = 20121113-64
  20. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  21. PHP(api) = 20121113-64
  22. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  23. PHP(api) = 20090626
  24. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  25. PHP(api) = 20090626
  26. Error: Package: PHP-process-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  27. Requires: PHP-common(x86-64) = 5.5.8-1.el6.remi
  28. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  29. PHP-common(x86-64) = 5.5.8-1.el6.remi
  30. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  31. PHP-common(x86-64) = 5.3.3-27.el6_5
  32. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  33. PHP-common(x86-64) = 5.3.3-26.el6
  34. Error: Package: PHP-pecl-igbinary-1.1.2-0.5.git3b8ab7e.el6.remi.1.x86_64 (@remi-PHP55)
  35. Requires: PHP(zend-abi) = 20121212-64
  36. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  37. PHP(zend-abi) = 20121212-64
  38. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  39. PHP(zend-abi) = 20090626
  40. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  41. PHP(zend-abi) = 20090626
  42. Error: Package: PHP-pecl-memcached-2.1.0-7.el6.remi.5.5.x86_64 (@remi-PHP55)
  43. Requires: PHP(zend-abi) = 20121212-64
  44. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  45. PHP(zend-abi) = 20121212-64
  46. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  47. PHP(zend-abi) = 20090626
  48. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  49. PHP(zend-abi) = 20090626
  50. Error: Package: PHP-pecl-mongo-1.4.5-1.el6.remi.5.5.x86_64 (@remi-PHP55)
  51. Requires: PHP(zend-abi) = 20121212-64
  52. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  53. PHP(zend-abi) = 20121212-64
  54. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  55. PHP(zend-abi) = 20090626
  56. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  57. PHP(zend-abi) = 20090626
  58. Error: Package: PHP-pecl-mongo-1.4.5-1.el6.remi.5.5.x86_64 (@remi-PHP55)
  59. Requires: PHP(api) = 20121113-64
  60. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  61. PHP(api) = 20121113-64
  62. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  63. PHP(api) = 20090626
  64. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  65. PHP(api) = 20090626
  66. Error: Package: PHP-pecl-igbinary-1.1.2-0.5.git3b8ab7e.el6.remi.1.x86_64 (@remi-PHP55)
  67. Requires: PHP(api) = 20121113-64
  68. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  69. PHP(api) = 20121113-64
  70. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  71. PHP(api) = 20090626
  72. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  73. PHP(api) = 20090626
  74. Error: Package: PHP-gd-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  75. Requires: PHP-common(x86-64) = 5.5.8-1.el6.remi
  76. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  77. PHP-common(x86-64) = 5.5.8-1.el6.remi
  78. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  79. PHP-common(x86-64) = 5.3.3-27.el6_5
  80. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  81. PHP-common(x86-64) = 5.3.3-26.el6
  82. Error: Package: PHP-pecl-sqlite-2.0.0-0.4.svn332053.el6.remi.5.5.x86_64 (@remi-PHP55)
  83. Requires: PHP(zend-abi) = 20121212-64
  84. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  85. PHP(zend-abi) = 20121212-64
  86. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  87. PHP(zend-abi) = 20090626
  88. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  89. PHP(zend-abi) = 20090626
  90. Error: Package: PHP-pecl-memcache-3.0.8-1.el6.remi.1.x86_64 (@remi-PHP55)
  91. Requires: PHP(zend-abi) = 20121212-64
  92. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  93. PHP(zend-abi) = 20121212-64
  94. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  95. PHP(zend-abi) = 20090626
  96. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  97. PHP(zend-abi) = 20090626
  98. Error: Package: PHP-pecl-apcu-4.0.3-1.el6.remi.5.5.x86_64 (@remi-PHP55)
  99. Requires: PHP(zend-abi) = 20121212-64
  100. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  101. PHP(zend-abi) = 20121212-64
  102. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  103. PHP(zend-abi) = 20090626
  104. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  105. PHP(zend-abi) = 20090626
  106. Error: Package: PHP-pecl-memcache-3.0.8-1.el6.remi.1.x86_64 (@remi-PHP55)
  107. Requires: PHP(api) = 20121113-64
  108. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  109. PHP(api) = 20121113-64
  110. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  111. PHP(api) = 20090626
  112. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  113. PHP(api) = 20090626
  114. Error: Package: PHP-mbstring-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  115. Requires: PHP-common(x86-64) = 5.5.8-1.el6.remi
  116. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  117. PHP-common(x86-64) = 5.5.8-1.el6.remi
  118. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  119. PHP-common(x86-64) = 5.3.3-27.el6_5
  120. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  121. PHP-common(x86-64) = 5.3.3-26.el6
  122. Error: Package: PHP-mcrypt-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  123. Requires: PHP-common(x86-64) = 5.5.8-1.el6.remi
  124. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  125. PHP-common(x86-64) = 5.5.8-1.el6.remi
  126. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  127. PHP-common(x86-64) = 5.3.3-27.el6_5
  128. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  129. PHP-common(x86-64) = 5.3.3-26.el6
  130. Error: Package: PHP-pecl-jsonc-1.3.3-1.el6.remi.5.5.x86_64 (@remi-PHP55)
  131. Requires: PHP(zend-abi) = 20121212-64
  132. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  133. PHP(zend-abi) = 20121212-64
  134. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  135. PHP(zend-abi) = 20090626
  136. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  137. PHP(zend-abi) = 20090626
  138. Error: Package: PHP-pecl-jsonc-1.3.3-1.el6.remi.5.5.x86_64 (@remi-PHP55)
  139. Requires: PHP(api) = 20121113-64
  140. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  141. PHP(api) = 20121113-64
  142. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  143. PHP(api) = 20090626
  144. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  145. PHP(api) = 20090626
  146. Error: Package: PHP-xml-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  147. Requires: PHP-common(x86-64) = 5.5.8-1.el6.remi
  148. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  149. PHP-common(x86-64) = 5.5.8-1.el6.remi
  150. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  151. PHP-common(x86-64) = 5.3.3-27.el6_5
  152. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  153. PHP-common(x86-64) = 5.3.3-26.el6
  154. Error: Package: PHP-pecl-apcu-4.0.3-1.el6.remi.5.5.x86_64 (@remi-PHP55)
  155. Requires: PHP(api) = 20121113-64
  156. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  157. PHP(api) = 20121113-64
  158. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  159. PHP(api) = 20090626
  160. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  161. PHP(api) = 20090626
  162. Error: Package: PHP-pecl-sqlite-2.0.0-0.4.svn332053.el6.remi.5.5.x86_64 (@remi-PHP55)
  163. Requires: PHP(api) = 20121113-64
  164. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  165. PHP(api) = 20121113-64
  166. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  167. PHP(api) = 20090626
  168. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  169. PHP(api) = 20090626
  170. Error: Package: PHP-pdo-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  171. Requires: PHP-common(x86-64) = 5.5.8-1.el6.remi
  172. Removing: PHP-common-5.5.8-1.el6.remi.x86_64 (@remi-PHP55)
  173. PHP-common(x86-64) = 5.5.8-1.el6.remi
  174. Downgraded By: PHP-common-5.3.3-27.el6_5.x86_64 (updates)
  175. PHP-common(x86-64) = 5.3.3-27.el6_5
  176. Available: PHP-common-5.3.3-26.el6.x86_64 (base)
  177. PHP-common(x86-64) = 5.3.3-26.el6
  178. You could try using --skip-broken to work around the problem
  179. You could try running: rpm -Va --nofiles --nodigest
  180. [root@centos1 /]# PHP -v
  181. PHP 5.5.8 (cli) (built: Jan 9 2014 08:14:44)
  182. Copyright (c) 1997-2013 The PHP Group
  183. Zend Engine v2.5.0,Copyright (c) 1998-2013 Zend Technologies

请帮帮我.

看来你已经从remi存储库安装了很多额外的PHP模块.当您降级PHP时,依赖性不再可用.您也可以尝试降级它们
  1. yum downgrade PHP*

但这可能也会失败,因为标准存储库中并非所有这些软件包都可用

我建议先删除所有PHP包:

  1. yum remove PHP*

之后,您可以从标准仓库重新安装所需的软件包:

  1. yum install PHP PHP-cli ...

猜你在找的CentOS相关文章