Resolve MySQL Unable to load dynamic library error

Source: Internet
Author: User
Tags apache php php and root directory

1. Description of the problem

PHP's MySQL is suddenly bad today. The following error message is prompted:

No Libmysql.dll found so this application failed to start Apache PHP

startup:unable to load Dynamic Library:c:/apachegroup/php5/ext\php_mysql.dll

In turn, there will be an error when invoking the MySQL function:

Fatal error:call to undefined Function:mysql_connect ()

The production looked down my system, PHP.ini has been properly configured in the Extension_dir:

Extension_dir = "C:/apachegroup/php5/ext"

And Extension_dir inside also does exist php_mysql.dll, but why he must not hang up.

2. The cause of the problem

Google found the original:

To load "Php_mysql.dll" This DLL, you must first load "Libmysql.dll" the base DLL,

Although the former in the Ext directory, you can find.

Then the latter is not in the Ext directory (although even if he is also uncertain), also not a system can find his place.

3. There are, therefore, two types of solutions:

(1). Copy these DLLs to Windows below.

(2). Add the PHP root directory to the path.

4. Reference Link:

The nature of this type of error is the same, but there are some variations of the causes,

For example, upgrade PHP and so on, the details can refer to the following links:

Http://www.javatang.com/archives/2007/07/04/1548182.html

This article is from the "Technology Achievement Dream" blog, please be sure to keep this source http://ixdba.blog.51cto.com/2895551/526425

Related Article

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.