Error php startup unable to load dynamic library

guys, i already install this driver before, and worked very well, but this time, i upgraded my windows to 10, then i reinstalled my Vagrant and virtualbox again, now... when i try install the drive...

guys, i already install this driver before, and worked very well, but this time, i upgraded my windows to 10, then i reinstalled my Vagrant and virtualbox again, now… when i try install the drivers at step 3.

i got the error:

PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php/20160303/pdo_sqlsrv.so' - /usr/lib/php/20160303/pdo_sqlsrv.so: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php/20160303/sqlsrv.so' - /usr/lib/php/20160303/sqlsrv.so: cannot open shared object file: No such file or directory in Unknown on line 0

ubuntu 16.04

my output of odbcinst -j:

unixODBC 2.3.1
DRIVERS............: /etc/odbcinst.ini
SYSTEM DATA SOURCES: /etc/odbc.ini
FILE DATA SOURCES..: /etc/ODBCDataSources
USER DATA SOURCES..: /home/vagrant/.odbc.ini
SQLULEN Size.......: 8
SQLLEN Size........: 8
SQLSETPOSIROW Size.: 8

output of odbcinst -q -d -n "ODBC Driver 13 for SQL Server" :

[ODBC Driver 13 for SQL Server]
Description=Microsoft ODBC Driver 13 for SQL Server
Driver=/opt/microsoft/msodbcsql/lib64/libmsodbcsql-13.1.so.9.1
UsageCount=1

my output of php -m :

[PHP Modules]
bcmath
blackfire
calendar
Core
ctype
curl
date
dom
exif
fileinfo
filter
ftp
gd
gettext
hash
iconv
igbinary
imap
intl
json
libxml
mbstring
mcrypt
memcached
msgpack
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
pdo_pgsql
pdo_sqlite
pgsql
Phar
posix
readline
Reflection
session
shmop
SimpleXML
soap
sockets
SPL
sqlite3
standard
sysvmsg
sysvsem
sysvshm
tokenizer
wddx
xml
xmlreader
xmlwriter
xsl
Zend OPcache
zip
zlib

[Zend Modules]
Zend OPcache
blackfire

Note: when i type php -v i got the same error above of the version.

my php version:

PHP 7.1.12-3+ubuntu16.04.1+deb.sury.org+1 (cli) (built: Dec 14 2017 15:37:13) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies
    with Zend OPcache v7.1.12-3+ubuntu16.04.1+deb.sury.org+1, Copyright (c) 1999-2017, by Zend Technologies
    with blackfire v1.18.0~linux-x64-non_zts71, https://blackfire.io, by SensioLabs

How to resolve warning messages when loading dynamic libraries (DLL) (a.k.a extensions) under PHP on Windows.

Problem

When running PHP on Windows XP/2000/2003, you may encounter the following errors that appear in dialog boxes. Additional errors may be printed when running PHP CLI on the command line.

  • php.exe — Unable To Locate Component

    This application has failed to start because php_mbstring.dll was not found. Re-installing the application may fix this problem.
  • Warning

    PHP Startup: Unable to load dynamic library ‘c:Program FilesPHPextphp_exif.dll’ — The specified module could not be found.
  • php.exe — Entry Point Not Found

    The procedure entry point _ZOOM_scanset_display_term@16 could not be located in the dynamic link library yaz.dll.

Causes

The most common cause may be a misconfigured extension_dir setting in your php.ini.

You may also encounter the above errors if you enable all the extensions in PHP. The errors are generally caused by misconfigured extensions. Some extensions (e.g. Oracle) require additional setup, software, and support DLLs, which come from outside the main PHP installer.

You may have out-of-date extension DLLs in your extensions directory.

Some extensions may also have bugs that are causing warnings.

The PATH environment variable does not contain the PHP base install location.

IIS may not have been restarted since changes were made to php.ini.

You did not install the correct build of PHP.

The DLL is listed more than once in the php.ini file. (This may be caused by using the MSI installer.)

Solutions

You must configure extension_dir correctly to point to the folder with the DLL files. This setting is edited in your php.ini file. (How to find your php.ini)

Disable all unused DLLs. You can easily disable an extension by commenting-out the corresponding line from your php.ini file. (How to find your php.ini) Comment-out lines by placing a semi-colon at the beginning of the line.

Remove duplicate references to DLLs from your php.ini file.

Make sure you installed the correct version of PHP for your server configuration.

Visit the PHP For Windows Download Page and download the correct ZIP package by following the instructions on the PHP Windows Mannual Installation Steps page under «Selecting and downloading the PHP distribution package». Unzip the file into your PHP installation directory. For example, for PHP 5.2.x + IIS 6 + Windows Server 2003, you need to use the VC6 non-thread safe build. If you get the standard build from the main PHP download page, you will get errors.

If your DLLs versions are out-of-date or mismatched, make sure to download and install the latest Windows binary zip packages as described above.

These errors may also occur if you do not have the Windows PATH environment variable pointing to your base PHP install.
In particular, for php_curl.dll, the Windows PATH environment variable must contain the location of the files libeay32.dll and ssleay32.dll. Furthermore, adequate permissions must be granted to those files (usually read permissions to IUSR_MachineName).

Try restarting IIS if you have made changes to php.ini.

If there are still warnings, then you must read the documentation for each enabled extension, and install and configure any necessary third-party software. For example, many database extensions, such as ODBC and Oracle, require third-party software. Look in the «Installation» section of the PHP documentation for the specific extension.

If that fails, try searching for bugs in bugs.php.net for the error message you encounter.

Notes

The MSI installer that comes with PHP 5.2.0 makes it very easy to configure PHP to load all the extensions. This means it is more likely for people to encounter the above issue.

Where is my PHP.ini file?

Go to «Start > Run…», type in cmd and press «OK». Type php --ini and press «Enter». Look for the following line:

Loaded Configuration File:         C:Program FilesPHPphp.ini

The «Loaded Configuration File» setting tells you which php.ini file PHP is loading. php.ini is generally located in c:program filesphp, c:windows, or c:php.

Links

  • Bug #34398 some PHP extension fail to load…
  • Bug #28137 about half the extensions don’t load

Error Output of php.exe

The following was captured by running PHP CLI with «php -v >out.txt 2<&1» from a Windows XP SP2 command line. This is with all extensions enabled even though most are not used or configured properly.


PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_exif.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_exif.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_ifx.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_ifx.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_oci8.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_oci8.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_pdo_oci.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_pdo_oci.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_pdo_oci8.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_pdo_oci8.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_pspell.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_pspell.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_sybase_ct.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_sybase_ct.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_ibm_db2.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_ibm_db2.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_imagick.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_imagick.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_ingres.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_ingres.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_netools.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_netools.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_oracle.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_oracle.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_svn.dll’ — The specified module could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_svn.dll’ — The specified module could not be found.

in Unknown on line 0

PHP Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_yaz.dll’ — The specified procedure could not be found.

in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘C:Program FilesPHPextphp_yaz.dll’ — The specified procedure could not be found.

in Unknown on line 0

Cannot find module (IP-MIB): At line 0 in (none)

Cannot find module (IF-MIB): At line 0 in (none)

Cannot find module (TCP-MIB): At line 0 in (none)

Cannot find module (UDP-MIB): At line 0 in (none)

Cannot find module (SNMPv2-MIB): At line 0 in (none)

Cannot find module (SNMPv2-SMI): At line 0 in (none)

Cannot find module (UCD-SNMP-MIB): At line 0 in (none)

Cannot find module (UCD-DEMO-MIB): At line 0 in (none)

Cannot find module (SNMP-TARGET-MIB): At line 0 in (none)

Cannot find module (SNMP-VIEW-BASED-ACM-MIB): At line 0 in (none)

Cannot find module (SNMP-COMMUNITY-MIB): At line 0 in (none)

Cannot find module (UCD-DLMOD-MIB): At line 0 in (none)

Cannot find module (SNMP-FRAMEWORK-MIB): At line 0 in (none)

Cannot find module (SNMP-MPD-MIB): At line 0 in (none)

Cannot find module (SNMP-USER-BASED-SM-MIB): At line 0 in (none)

Cannot find module (SNMP-NOTIFICATION-MIB): At line 0 in (none)

Cannot find module (SNMPv2-TM): At line 0 in (none)

PHP Notice: Constant XML_ELEMENT_NODE already defined in Unknown on line 0

Notice: Constant XML_ELEMENT_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_NODE already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_TEXT_NODE already defined in Unknown on line 0

Notice: Constant XML_TEXT_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_CDATA_SECTION_NODE already defined in Unknown on line 0

Notice: Constant XML_CDATA_SECTION_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_ENTITY_REF_NODE already defined in Unknown on line 0

Notice: Constant XML_ENTITY_REF_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_ENTITY_NODE already defined in Unknown on line 0

Notice: Constant XML_ENTITY_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_PI_NODE already defined in Unknown on line 0

Notice: Constant XML_PI_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_COMMENT_NODE already defined in Unknown on line 0

Notice: Constant XML_COMMENT_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_DOCUMENT_NODE already defined in Unknown on line 0

Notice: Constant XML_DOCUMENT_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_DOCUMENT_TYPE_NODE already defined in Unknown on line 0

Notice: Constant XML_DOCUMENT_TYPE_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_DOCUMENT_FRAG_NODE already defined in Unknown on line 0

Notice: Constant XML_DOCUMENT_FRAG_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_NOTATION_NODE already defined in Unknown on line 0

Notice: Constant XML_NOTATION_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_HTML_DOCUMENT_NODE already defined in Unknown on line 0

Notice: Constant XML_HTML_DOCUMENT_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_DTD_NODE already defined in Unknown on line 0

Notice: Constant XML_DTD_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_ELEMENT_DECL_NODE already defined in Unknown on line 0

Notice: Constant XML_ELEMENT_DECL_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_DECL_NODE already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_DECL_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_ENTITY_DECL_NODE already defined in Unknown on line 0

Notice: Constant XML_ENTITY_DECL_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_NAMESPACE_DECL_NODE already defined in Unknown on line 0

Notice: Constant XML_NAMESPACE_DECL_NODE already defined in Unknown on line 0

PHP Notice: Constant XML_LOCAL_NAMESPACE already defined in Unknown on line 0

Notice: Constant XML_LOCAL_NAMESPACE already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_CDATA already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_CDATA already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_ID already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_ID already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_IDREF already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_IDREF already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_IDREFS already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_IDREFS already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_ENTITY already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_ENTITY already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_NMTOKEN already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_NMTOKEN already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_NMTOKENS already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_NMTOKENS already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_ENUMERATION already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_ENUMERATION already defined in Unknown on line 0

PHP Notice: Constant XML_ATTRIBUTE_NOTATION already defined in Unknown on line 0

Notice: Constant XML_ATTRIBUTE_NOTATION already defined in Unknown on line 0

Normal output is below.

PHP 5.2.0 (cli) (built: Nov 2 2006 11:57:36)

Copyright (c) 1997-2006 The PHP Group

Zend Engine v2.2.0, Copyright (c) 1998-2006 Zend Technologies

php.ini Loaded Extensions

Below shows relevant portions of php.ini from version 5.2.0.

; Directory in which the loadable extensions (modules) reside.
extension_dir = C:Program FilesPHPext
error_reporting  =  E_ALL
display_startup_errors = On

[PHP_BZ2]
extension=php_bz2.dll
[PHP_CURL]
extension=php_curl.dll
[PHP_DBA]
extension=php_dba.dll
[PHP_DBASE]
extension=php_dbase.dll
[PHP_EXIF]
extension=php_exif.dll
[PHP_FDF]
extension=php_fdf.dll
[PHP_GD2]
extension=php_gd2.dll
[PHP_GETTEXT]
extension=php_gettext.dll
[PHP_GMP]
extension=php_gmp.dll
[PHP_IFX]
extension=php_ifx.dll
[PHP_IMAP]
extension=php_imap.dll
[PHP_INTERBASE]
extension=php_interbase.dll
[PHP_LDAP]
extension=php_ldap.dll
[PHP_MBSTRING]
extension=php_mbstring.dll
[PHP_MCRYPT]
extension=php_mcrypt.dll
[PHP_MHASH]
extension=php_mhash.dll
[PHP_MIME_MAGIC]
extension=php_mime_magic.dll
[PHP_MING]
extension=php_ming.dll
[PHP_MSQL]
extension=php_msql.dll
[PHP_MSSQL]
extension=php_mssql.dll
[PHP_MYSQL]
extension=php_mysql.dll
[PHP_MYSQLI]
extension=php_mysqli.dll
[PHP_OCI8]
extension=php_oci8.dll
[PHP_OPENSSL]
extension=php_openssl.dll
[PHP_PDO]
extension=php_pdo.dll
[PHP_PDO_FIREBIRD]
extension=php_pdo_firebird.dll
[PHP_PDO_MSSQL]
extension=php_pdo_mssql.dll
[PHP_PDO_MYSQL]
extension=php_pdo_mysql.dll
[PHP_PDO_OCI]
extension=php_pdo_oci.dll
[PHP_PDO_OCI8]
extension=php_pdo_oci8.dll
[PHP_PDO_ODBC]
extension=php_pdo_odbc.dll
[PHP_PDO_PGSQL]
extension=php_pdo_pgsql.dll
[PHP_PDO_SQLITE]
extension=php_pdo_sqlite.dll
[PHP_PGSQL]
extension=php_pgsql.dll
[PHP_PSPELL]
extension=php_pspell.dll
[PHP_SHMOP]
extension=php_shmop.dll
[PHP_SNMP]
extension=php_snmp.dll
[PHP_SOAP]
extension=php_soap.dll
[PHP_SOCKETS]
extension=php_sockets.dll
[PHP_SQLITE]
extension=php_sqlite.dll
[PHP_SYBASE_CT]
extension=php_sybase_ct.dll
[PHP_TIDY]
extension=php_tidy.dll
[PHP_XMLRPC]
extension=php_xmlrpc.dll
[PHP_XSL]
extension=php_xsl.dll
[PHP_ZIP]
extension=php_zip.dll
[PHP_APD]
extension=php_apd.dll
[PHP_BCOMPILER]
extension=php_bcompiler.dll
[PHP_BITSET]
extension=php_bitset.dll
[PHP_BLENC]
extension=php_blenc.dll
[PHP_BZ2_FILTER]
extension=php_bz2_filter.dll
[PHP_CLASSKIT]
extension=php_classkit.dll
[PHP_CPDF]
extension=php_cpdf.dll
[PHP_CRACK]
extension=php_crack.dll
[PHP_CVSCLIENT]
extension=php_cvsclient.dll
[PHP_DB]
extension=php_db.dll
[PHP_DBX]
extension=php_dbx.dll
[PHP_DIO]
extension=php_dio.dll
[PHP_DOCBLOCK]
extension=php_docblock.dll
[PHP_DOMXML]
extension=php_domxml.dll
[PHP_EVENT]
extension=php_event.dll
[PHP_FILEINFO]
extension=php_fileinfo.dll
[PHP_FILEPRO]
extension=php_filepro.dll
[PHP_FRIBIDI]
extension=php_fribidi.dll
[PHP_GOPHER]
extension=php_gopher.dll
[PHP_HTTP]
extension=php_http.dll
[PHP_HYPERWAVE]
extension=php_hyperwave.dll
[PHP_IBM_DB2]
extension=php_ibm_db2.dll
[PHP_ID3]
extension=php_id3.dll
[PHP_IISFUNC]
extension=php_iisfunc.dll
[PHP_IMAGICK]
extension=php_imagick.dll
[PHP_INGRES]
extension=php_ingres.dll
[PHP_JAVA]
extension=php_java.dll
[PHP_LZF]
extension=php_lzf.dll
[PHP_MAILPARSE]
extension=php_mailparse.dll
[PHP_MCRYPT_FILTER]
extension=php_mcrypt_filter.dll
[PHP_MEMCACHE]
extension=php_memcache.dll
[PHP_NETOOLS]
extension=php_netools.dll
[PHP_NTUSER]
extension=php_ntuser.dll
[PHP_OGGVORBIS]
extension=php_oggvorbis.dll
[PHP_OPERATOR]
extension=php_operator.dll
[PHP_ORACLE]
extension=php_oracle.dll
[PHP_PARSEKIT]
extension=php_parsekit.dll
[PHP_PDF]
extension=php_pdf.dll
[PHP_PHAR]
extension=php_phar.dll
[PHP_PHPDOC]
extension=php_phpdoc.dll
[PHP_POP3]
extension=php_pop3.dll
[PHP_PRINTER]
extension=php_printer.dll
[PHP_RADIUS]
extension=php_radius.dll
[PHP_RAR]
extension=php_rar.dll
[PHP_SDO]
extension=php_sdo.dll
[PHP_SMTP]
extension=php_smtp.dll
[PHP_SSH2]
extension=php_ssh2.dll
[PHP_STATS]
extension=php_stats.dll
[PHP_STEM]
extension=php_stem.dll
[PHP_SVN]
extension=php_svn.dll
[PHP_SWISH]
extension=php_swish.dll
[PHP_THREADS]
extension=php_threads.dll
[PHP_TIMEZONEDB]
extension=php_timezonedb.dll
[PHP_TRANSLIT]
extension=php_translit.dll
[PHP_WIN32PS]
extension=php_win32ps.dll
[PHP_WIN32SCHEDULER]
extension=php_win32scheduler.dll
[PHP_WIN32SERVICE]
extension=php_win32service.dll
[PHP_WIN32STD]
extension=php_win32std.dll
[PHP_YAZ]
extension=php_yaz.dll
[PHP_ZLIB_FILTER]
extension=php_zlib_filter.dll

Created 2006-11-06, Last Modified 2011-07-24, © Shailesh N. Humbad
Disclaimer: This content is provided as-is. The information may be incorrect.

Warning

This extension was deprecated in PHP 5.5.0, and it was removed in PHP 7.0.0.
Instead, the MySQLi or PDO_MySQL extension should be used.
See also MySQL: choosing an API guide.
Alternatives to this function include:

For compiling, simply use the
—with-mysql[=DIR]
configuration option where the optional [DIR] points to
the MySQL installation directory.

Although this MySQL extension is compatible with MySQL 4.1.0 and greater,
it doesn’t support the extra functionality that these versions provide.
For that, use the MySQLi extension.

If you would like to install the mysql extension along with the mysqli extension
you have to use the same client library to avoid any conflicts.

Installation on Linux Systems

Note: [DIR] is the path to the MySQL client library
files (headers and libraries), which can be downloaded from
» MySQL.

ext/mysql compile time support matrix

PHP Version Default Configure Options: mysqlnd Configure Options: libmysqlclient Changelog
4.x.x libmysqlclient Not Available —without-mysql to disable MySQL enabled by default, MySQL client libraries are bundled
5.0.x, 5.1.x, 5.2.x libmysqlclient Not Available —with-mysql=[DIR] MySQL is no longer enabled by default, and the MySQL client libraries
are no longer bundled
5.3.x libmysqlclient —with-mysql=mysqlnd —with-mysql=[DIR] mysqlnd is now available
5.4.x mysqlnd —with-mysql —with-mysql=[DIR] mysqlnd is now the default

Installation on Windows Systems

PHP 5.0.x, 5.1.x, 5.2.x

MySQL is no longer enabled by default, so the
php_mysql.dll DLL must be enabled inside of
php.ini. Also, PHP needs access to the MySQL client library. A file
named libmysql.dll is included in the Windows PHP
distribution and in order for PHP to talk to MySQL this file needs to be
available to the Windows systems PATH. See the FAQ
titled «How do I add my PHP
directory to the PATH on Windows» for information on how to do
this. Although copying libmysql.dll to the Windows
system directory also works (because the system directory is by default in
the system’s PATH), it’s not recommended.

As with enabling any PHP extension (such as
php_mysql.dll), the PHP directive
extension_dir should be set to
the directory where the PHP extensions are located. See also the
Manual Windows Installation
Instructions. An example extension_dir value for PHP 5 is
c:phpext

Note:

If when starting the web server an error similar to the following occurs:
"Unable to load dynamic library './php_mysql.dll'",
this is because php_mysql.dll and/or
libmysql.dll cannot be found by the system.

PHP 5.3.0+

The MySQL Native Driver is enabled by
default. Include php_mysql.dll, but libmysql.dll
is no longer required or used.

MySQL Installation Notes

Warning

Crashes and startup problems of PHP may be encountered
when loading this extension in conjunction with the recode extension.
See the recode extension for more
information.

Note:

If you need charsets other than latin (default), you
have to install external (not bundled) libmysqlclient with compiled charset
support.

heneryville at gmail dot com

12 years ago


I believe that this is happens especially with Windows 7.  As far I I've been able to tell XP and Vista come with this line enabled, but windows 7 comments it out and notes that the DNS will handle this.

jonnus

14 years ago


In windows systems, the same error "unable to load dynamic library php_mysql.dll" will happen, if there's an old version of the file in the "windowssystem32" folder.
Either remove it or update it.

buzzr515 at gmx dot de

12 years ago


i've experienced a similar (if not the same) problem.

to enable the mysql_... and mysqli_... funtionality, i opened the php.ini file to uncomment the following lines:
;extension=php_mysql.dll
;extension=php_mysqli.dll
;extension=php_pdo_mysql.dll

but phpinfo() still stated that no mysql extensions were loaded.
i tried the fixes and suggestions above with no success.
so i invoked the windows shell and typed ("Path" environment variable set to the PHP & MySQL directories):
php.exe -m

this returned the following error: "PHP Startup: Unable to load dynamic library 'C:php5php_mysql.dll' - Module not found."

this told me that PHP didn't recognize what i thought was the extensions directory. it searched all other places first (sys-dir, workin'-dir, the MySQL "bin" dir because of the "Path" variable set, and even a curious directory "C:php5" that doesn't even exist on my mashine) but not the expected "ext" directory.

so the fix was to go to "php.ini" again and uncomment the following line:
;extension_dir="ext"

this fixed it for me.
so if module loading is done improperly, first of all check the "Path" environment variable and the "php.ini" file - especially the "extension_dir" config value - and check if all values are set to their correct values.

hope this helps any1.

----------------------------------------
OS: Win7 Ultimate x86
Apache v2.2.16
PHP v5.3.3
MySQL v5.1.50


mail dot umlcat at gee mail dot com

10 years ago


Could not install mysql, on windows, had several conflicts or bugs.

In order to solve it:

* Used the "libmysql.dll" provided by PHP zip files, not the one that comes with Mysql, the mysql file had to be moved or deleted from its folder. Put it on the "apache/bin" folder, altought some use it in "windows" folder.

* Originally, moved "*mysql*.dll" files from its extension folder, and returned back.

* enabled mysql driver extensions in the "php.ini" file, but also enabled some extensions, that seemed not to be required, but, it did, like "php_openssl.dll" or "php_pdo.dll" on an early version of php.

Added the "PHPIniDir xxx"" to the "httpd.conf" apache config. file, where xxx is the path to the folder where the "php.ini" file is located, and make sure its the same.

Be warned, that this fixes, may help or not, for your installation, since there are many ways to configure the same thing (to solve a problem).


Steve in Weston-Super-Mare

11 years ago


I had problems when moving from a version of PHP that used the isapi dll to the fast cgi version. The script to register the script maps compained that there was already a script map in place.

I went to the IIS control panel, right clicked on websites and removed the php association in the Home Directory | Configuration screen.

However, the fastcgi script still complained about existing script map. Finally I tracked it down, I had to right click on Default Web Site and clear out the php mappings from there too.

Then it all worked, except that for some strange reason, the php.ini file that gets picked up is the one from my old PHP directory, not the latest upgrade one. But this can be detected by running phpinfo which shows the loaded php.ini file so I knew which one to amend with the fastcgi options.

Bit of a hassle to figure it all out but it does work in the end.


amatsak at gmail dot com

13 years ago


I have experienced exactly the same problem as flo_stefi at yahoo dot com below. It appears that instead of loading libmysql.dll that came with the PHP package, the PHP engine was loading libmySQL.dll located in MySQL's bin directory, which was causing Apache to crash.

I fixed the problem by renaming MySQL's libmySQL.dll into libmySQL_renamed.dll. Now PHP loads the library that came with its package and everything works fine.


o dot kochetilov at gmail dot com

11 years ago


Please note that libmySQL.dll in MySQL bin directory should be renamed in order to use right library (that comes with PHP).

Server wide errors are always a panic situation for server owners. A single server wide error can affect multiple websites in a split-second.

To maintain business credibility, its therefore crucial to fix server wide errors promptly. At Bobcares, we do this for our shared hosting customers, with our technical support services.

Recently we were contacted by a server owner, with this concern – “Hi, All my PHP sites show the same error:”

PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20090626/ffmpeg.so' - libavformat.so.54: cannot open shared object file: No such file or directory in Unknown on line 0

What this error means?

FFmpeg is a module that helps to record, convert and stream audio and video in websites. Many websites require this PHP module for audio and video streaming.

For any PHP module to work fine, it should be compiled and configured correctly. If not, it would give errors when the websites try to use these modules.

The error shown here says that PHP is unable to load the dynamic library for FFmpeg module. This error is a server wide one and can affect all websites using this module.

How to debug this error?

FFmpeg error can happen in PHP sites if the module is not properly installed or if there are any configuration issues.

Today we’ll see which all factors can trigger this error and how to fix them one by one.

1. FFmpeg module is not properly installed

The first step is to check that the FFmpeg module is properly installed in the server. The command ‘which ffmpeg’ helps to know if its installed.

If the module is not installed, you can install it using:

yum install ffmpeg ffmpeg-devel

2. The path to the library is wrong

By default, all required libraries for FFmpeg would be installed under /usr/local/lib/ directory. But if the FFmpeg binary looks in a different path, these libraries would not be found.

Using the command 'ldd which ffmpeg', it is possible to know the path to the library to which ffmpeg binary is linked to.

To make ffmpeg check the libraries in the correct path, do the following steps:

export LD_LIBRARY_PATH=/usr/local/lib/ echo /usr/local/lib > /etc/ld.so.conf.d/custom-libs.conf ldconfig

It is also possible to correct this error by adding symbolic links to the library files.

3. Library files missing

This error can also happen due to related libraries for FFmpeg missing. Installing the ‘ffmpeg-devel’ module will install all the required libraries for FFmpeg.

4. Configuration errors in php.ini

Improper settings in the php.ini file can cause the FFmpeg module of PHP to show errors. So its important to verify that the settings in the php.ini file, say ‘/usr/local/lib/php.ini’, are correct.

Make sure that the FFmpeg module is added correctly in the php.ini.

[ffmpeg]
extension=ffmpeg.so

Also confirm that the extension_dir in php.ini is set correctly, which should ideally be ” ” (empty).

extension_dir = " "

Once the settings are corrected, restart apache. You can confirm that FFmpeg is now enabled with php, using a phpinfo() file.

In short..

Here we discussed some of the basic reasons why FFmpeg errors can happen and what are the checks to be performed to fix the error.

During our support experience, we have also noticed that other issues like dependency errors during install, module added twice, wrongly set paths, extension directory, etc., cause FFmpeg errors.

Bobcares engineers debug server errors using a step-by-step approach, ruling out all possible causes, in the order of its priority and probability.

This helps us pinpoint the actual issue and come up with a permanent solution for the errors. If you’d like to know how to fix you server errors, we’d be happy to talk to you.

Get a FREE consultation

Do you spend all day answering technical support queries?

Wish you had more time to focus on your business? Let us help you.

We free up your time by taking care of your customers and servers. Our engineers monitor your servers 24/7, and support your customers over help desk, live chat and phone.

Talk to our technical support specialist today to know how we can keep your service top notch!

TALK TO AN EXPERT NOW!

var google_conversion_label = «Blp0CLCojHIQ0aD71QM»;

Bobcares provides Outsourced Hosting Support for online businesses. Our services include Outsourced Web Hosting Support, Outsourced Server Support, Outsourced Help Desk Support, Outsource Live Chat Support and Phone Support Services.

Понравилась статья? Поделить с друзьями:
  • Error php is not running wordpress
  • Error php home is not specified or invalid press fix to edit your project configuration
  • Error phone code invalid
  • Error phasmophobia ошибка
  • Error pg hba conf