The mysql extension is missing

Главное меню » Блог-платформа wordpress » Как исправить Missing MySQL Extension Error в WordPress

Отсутствующее расширение PHP не такая уж большая проблема. Если вы видите следующее сообщение на экране при попытке получить доступ к установке WordPress через веб-браузер, то вы один из многих пользователей WordPress, кто сталкивался с этой же проблемой.

Чтобы решить эту проблему, вы должны иметь доступ SSH к серверу. Подключитесь к Linux VPS через сетевой протокол SSH и проверьте текущую версию PHP, которая используется в настоящее время:

Вы также можете проверить текущую версию PHP, создав простой файл info.php в директории public_html со следующим содержанием:

После создания и сохранения файла откройте ваш любимый веб-браузер и получите доступ к файлу набрав в командной строке http://ваш_домен.ру/info.php.

Если вы работаете на сервере Ubuntu VPS и, PHP 7 , то выполните следующие команды в командной строке:

Затем перезапустите службу Apache для того, чтобы изменения вступили в силу, или если вы используете связку Nginx + PHP-FPM, то перезапустите службу PHP-FPM.

В случае, если вы работаете с PHP 5 , выполните следующие команды:

Перезапустите соответствующую службу для того, чтобы изменения вступили в силу.

Для поиска всех доступных пакетов, содержащие в mysql , вы можете использовать следующую команду в Ubuntu:

С другой стороны, если вы работаете на сервере CentOS VPS и вы установили PHP 7 на сервере, то запустите следующие команды, чтобы решить эту проблему:

Перезапустите Apache или PHP-FPM в случае, если вы используете Nginx + PHP-FPM в качестве веб-сервера.

Если вы установили PHP 5 на сервере CentOS, выполните следующие команды:

Перезапустите соответствующую службу для того, чтобы изменения на сервере вступили в силу.

Для поиска всех доступных пакетов, содержащихся в mysql , вы можете использовать следующую команду в CentOS:

Читайте также:  79 Service error turn off then on

После того, как вы установите расширение MySQL для PHP, сообщение о пропавших расширениях не должно больше появиться и вы можете продолжить установку WordPress.

Если вы нашли ошибку, пожалуйста, выделите фрагмент текста и нажмите Ctrl+Enter.

В этой мини статье пойдет речь о том, как быстро исправить ошибку, возникающую при отсутствии нужного модуля для php. Итак, если вы получили вот такое сообщение в phpMyAdmin:

phpMyAdmin — Error
The mysqli extension is missing. Please check your PHP configuration. See our documentation for more information.

То это скорей всего произошло из-за того, что для php не установлен модуль, отвечающий за работу с mysql.
Решение проблемы:

I installed everything separately (Apache, PHP, MySQL and phpMyAdmin) and do not use a compilation, everything works fine till now except phpMyAdmin.

The problem I am experiencing is, that the error message states that the "MySQL extension is missing", as soon as I try to call up:

And when I call up

I have two messages where I do not know if it is supposed to be like that:

Bzip2 compression and decompression requires functions (bzopen, bzcompress) which are unavailable on this system.

Zip decompression requires functions (zip_open) which are unavailable on this system.

10 Answers 10

At first make sure you have mysql installed properly. You can ensure it just by checking that whether you can access mysql using mysql command promp. So if you mysql is working then probably it is not loading. For that follow the steps given below

First of all, you must find your php.ini. It could be anywhere but if you create a small php file with the

Читайте также:  Optiarc dvd rw ad 5260s прошивка

script it will tell you where it is. Just look at the path of loaded configuration file. Common places include /etc/apache/, /etc/php4/apache2/php.ini, /etc/php5/apache2/php.ini or even /usr/local/lib/php.ini for Windows it may be C:UsersusernamePHPphp.ini

Edit your server’s php.ini and look for the following line. Remove the ‘;’ from the start of the line and restart Apache. Things should work fine now!

For windows it will be

Some linux distributions have a php_mysql and php_mysqli package to install.

Installing bzip2 and zip PHP extensions solved my issue in Ubuntu:

Use php(you version)-(extension) to install and enable any missing modules that is required in the phpmyadmin readme.

You need to put the full path in the php ini when loading the mysql dll, i.e :-

Then you don’t need to move them to the windows folder.

In my case I had to install the extension:

and then restart apache:

That solved the problem.

Just as others stated you need to remove the ‘ ; ‘ from:
;extension=php_mysql.dll and
;extension=php_mysqli.dll

in your php.ini to enable mysql and mysqli extensions. But MOST IMPORTANT of all, you should set the extension_dir in your php.ini to point to your extensions directory. The default most of the time is " ext ". You should change it to the absolute path to the extensions folder. i.e. if you have your xampp installed on drive C, then C:/xampp/php/ext is the absolute path to the ext folder, and It should work like a charm!

This will ask to overwrite mysql.so from "php5-mysql".

This work for me.

Читайте также:  Thomas twin t1 фильтр

Your installation is missing some php modules, there should be a list of required modules in the phpmyadmin readme. If you recently enabled the modules, try restarting the apache service / daemon.

Edit: As it seems, there is no single "enable these modules" in the docs, so enable either mysql or mysqli in your php.ini (you might need to install it first).

The two messages are not important if you do not intend to upload or download compressed file within phpMyAdmin. If you do, enable the zlib and / or bz2 modules.

I had a similar issue, but it d >

Just check your php.ini file, In this file Semicolon(;) used for comment if you see then remove semicolon ;.

Now your extension is enable but you need to restart appache

Rate this post

Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *