downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | conferences | my php.net

search for in the

Runtime Configuration> <Overview
[edit] Last updated: Fri, 24 Jun 2011

view this page in

Installation

Installation on Unix

By default the MySQL database extensions are configured to use MySQL Client Library. In order to use the MySQL Native Driver, PHP needs to be built specifying that the MySQL database extensions are compiled with MySQL Native Driver support. This is done through configuration options prior to building the PHP source code.

For example, to build the MySQL extension, mysqli and PDO MYSQL using the MySQL Native Driver, the following command would be given:

./configure --with-mysql=mysqlnd \
--with-mysqli=mysqlnd \
--with-pdo-mysql=mysqlnd \
[other options]

Installation on Windows

In the official PHP distributions from 5.3 onwards, MySQL Native Driver is enabled by default, so no additional configuration is required to use it. All MySQL database extensions will use MySQL Native Driver in this case.



add a note add a note User Contributed Notes Installation - [2 notes]
up
1
jose dot nobile at gmail dot com
2 years ago
On CentOS 5.4, installing php 5.3.3, is without mysqlnd

But is available mysql, mysqli, pdo_mysql
up
-1
Den
10 months ago
On ubuntu mysqlnd can be installed without source php code using synaptic package manager. However, phpmyadmin works I guess only with mysql, so if you use it you must keep an old driver.

After installing mysqlnd package you must restart apache in order new changes to take effect:

sudo service apache2 restart

or (if first doesn't work for you):

sudo /etc/init.d/apache2 restart

 
show source | credits | stats | sitemap | contact | advertising | mirror sites