在 CPanel 上安装 PDO_MYSQL PHP 扩展?

发布于 2024-08-06 06:49:32 字数 433 浏览 3 评论 0原文

我在客户服务器上安装 Magento 时收到此错误,“必须加载 PHP 扩展“pdo_mysql””。如何通过 CPanel Accelerated 安装/启用此扩展?

服务器信息如下:

  • cPanel Version 11.24.5-STABLE
  • cPanel Build 38506
  • Apache version 2.2.13 (Unix)
  • PHP version 5.2.8
  • MySQL version 5.0.81-community
  • Architecture i686
  • 操作系统 Linux
  • Kernel version 2.6.18-128.1.6 .el5
  • cPanel Pro 1.0 (RC1)

谢谢!

I recieved this error while installing Magento on a customer's server, 'PHP Extension "pdo_mysql" must be loaded'. How would one go about installing/enabling this extension through CPanel Accelerated?

Server information is as follows:

  • cPanel Version 11.24.5-STABLE
  • cPanel Build 38506
  • Apache version 2.2.13 (Unix)
  • PHP version 5.2.8
  • MySQL version 5.0.81-community
  • Architecture i686
  • Operating system Linux
  • Kernel version 2.6.18-128.1.6.el5
  • cPanel Pro 1.0 (RC1)

Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

爱你是孤单的心事 2024-08-13 06:49:33

如果您安装了cloudlinux,您可以在cPanel 中启用PDO。在 cPanel 中搜索 PHP 版本,然后在出现的屏幕上选择并启用 PDO,最后选择保存。
* http://docs.cloudlinux.com/index.html?using_php_selector.html

如果您没有安装 CloudLinux 和 PhpSelector,您将需要一个管理员帐户才能通过 easyapache 安装 PDO。在 WHM 中,请遵循以下指南:

在 Easyapache 中启用 PDO

  1. 登录到 WHM ( http://domain.com/whm )
  2. 转到 WHM »软件 »EasyApache(Apache 更新)
  3. 选择“以前保存的配置(**默认**)”,然后单击“根据配置文件开始自定义”
  4. 在“Apache 版本”页面上单击“下一步”
  5. 在“PHP 版本”页面上单击“下一步”
  6. 在“简短选项列表”页面上单击“详尽选项列表”
  7. 在“详尽选项列表”上确保选择 PDO、PDO sqlite 和 PDO MySQL。
  8. 然后单击页面底部的构建。

附言。我注意到您使用的是 11.24.5-STABLE。这是 WHM/cPanel 的一个非常旧的版本。您应该更新您的服务器,因为 cPanel 不再支持此版本的 cPAnel。

You can enable PDO in cPanel if you have cloudlinux installed. In cPanel search for PHP Version and on the resulting screen select and enable PDO and finally select save.
* http://docs.cloudlinux.com/index.html?using_php_selector.html

If you do not have CloudLinux and PhpSelector installed you will need an administrator account to install PDO through easyapache. In WHM follow this guide:

Enabling PDO in Easyapache

  1. Log in to WHM ( http://domain.com/whm )
  2. Goto WHM »Software »EasyApache (Apache Update)
  3. Select "Previously Saved Config (** DEFAULT **)" and click "Start customizing based on profile"
  4. On the "Apache Version" page click "Next"
  5. On the "PHP Version" page click "Next"
  6. On the "Short Options List" page click"Exhaustive Options List"
  7. On the "Exhaustive Options List" ensure that PDO, PDO sqlite and PDO MySQL are selected.
  8. Then Click Build on the bottom of the page.

PS. I note that you are on 11.24.5-STABLE. This is a extremely old version of WHM/cPanel. You should update your server as this version of cPAnel is no longer supported by cPanel.

时光磨忆 2024-08-13 06:49:33

我正在使用 Magento CE 1.7、CentOS 6 和 WHM 11.38,以下是我为解决在 Magento 安装过程中收到的“PHP 扩展“pdo_mysql”必须加载”错误所做的操作:

  1. 打开 WHM 并转到主页 » 软件 » Easy Apache(Apache 更新)
  2. 滚动到底部并选择“根据配置文件开始自定义”
  3. 单击“下一步”两次
  4. 滚动到底部并选择“详尽选项列表”
  5. 选择 PDO 和 PDO MySQL 的复选框,然后重建 Apache
  6. 转到 Magento 的root,将 php.ini.sample 复制到 php.ini
  7. 打开新创建的 php.ini 文件并添加以下内容:

    扩展名=pdo.so
    扩展名=pdo_sqlite.so
    扩展名=sqlite.so
    extension=pdo_mysql.so

这可能是使用终端重新启动 Apache 的好时机(# service httpd restart)。希望有帮助!

I'm using Magento CE 1.7, CentOS 6, and WHM 11.38, and here's what I did to resolve the 'PHP Extension "pdo_mysql" must be loaded' error I received during my Magento install:

  1. Open WHM and go to Home » Software » Easy Apache (Apache Update)
  2. Scroll to the bottom and select "Start customizing based on profile"
  3. Click "Next step" twice
  4. Scroll to the bottom and select "Exhaustive Options List"
  5. Select checkboxes for PDO and PDO MySQL, and rebuild Apache
  6. Go to Magento's root, copy php.ini.sample to php.ini
  7. Open the newly created php.ini file and add the following:

    extension=pdo.so
    extension=pdo_sqlite.so
    extension=sqlite.so
    extension=pdo_mysql.so

This might be a good time to restart Apache using terminal (# service httpd restart). Hope that helps!

半世蒼涼 2024-08-13 06:49:33

我认为您无法在共享主机或 cPanel 中完成此操作。

说服虚拟主机为您安装它。

I don't think you can do it in a shared host or with cPanel.

Convince the webhost to install it for you.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文