When phpMyAdmim and Yii are connected to Mysql, an error is returned.

Source: Internet
Author: User

When phpMyAdmim and Yii are connected to Mysql, an error is returned.
Faults:

Before phpMyAdmim and Yii connected to Mysql, one day, the following error was reported:

1. "The mysqli extension is missing in phpMyAdmin in linux. Check the PHP configuration ."

2. Yii shows CDbConnection failed to open the DB connection: cocould not find driver

Troubleshooting:

1. Check whether the Mysql service is normal (login or port)

2. the Mysql service is normal. It is estimated that PHP lacks mysql-related extensions because there are problems with both phpMyAdmim and Yii.

Cause:

The extension mysqli is not installed, or you have not added extension = mysqli. d to php. ini.

Solution:

1. yum list | grep php-mysql check whether php-mysql is installed

2. install php-mysql, yum-y install php-mysql

3. Add extension = mysqli. d to the PHP configuration file php. ini.

4. Restart Apache.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.