When I ran a script that uses PDO, I received an error from the console:
Can't connect to database: could not find driver
After which I read that I need to uncomment the line with pdo_mysql in php.ini. Unfortunately, this led to the following error now popping up in me:
Warning: PHP Startup: Unable to load dynamic library 'pdo_mysql'
PHP set through brew install php#7.2
I tried to install via pecl, but it produces:
running: make INSTALL_ROOT="/private/tmp/pear/temp/pear-build-artemsokoloviZ2ILB/install-
PDO-1.0.3" install
Installing shared extensions: /private/tmp/pear/temp/pear-build-artemsokoloviZ2ILB/install-PDO-1.0.3/usr/local/Cellar/php#7.2/7.2.31_1/pecl/20170718/
cp: modules/*: No such file or directory
make: *** [install-modules] Error 1
ERROR: `make INSTALL_ROOT="/private/tmp/pear/temp/pear-build-artemsokoloviZ2ILB/install-PDO-1.0.3" install' failed
Related
I have an application in symfony using doctrine and PGSQL.
I'm using MacOsx BigSur.
When I run my projet I have this error:
PHP Startup: Unable to load dynamic library 'pgsql.so'
I have install php#7.3 with brew install php#7.3
In the /etc/php.ini I added the line extension=pgsql.so of the end of file.
I have restart my services with: brew services restart php#7.3
When I run php -v I have a warning : PHP Startup: Unable to load dynamic library 'pgsql.so'
And when I run my symfony application I have this error:
In AbstractPostgreSQLDriver.php line 79:
An exception occurred in driver: could not find driver
In PDOConnection.php line 31:
could not find driver
In PDOConnection.php line 27:
could not find driver
How can I install pgsql to run my application correctly ?
Thanks
To resolve my problem I have installed php#7.3 with brew
brew install php#7.3
After that you need to do:
echo ‘export PATH=“/usr/local/opt/php#7.3/bin:$PATH”’ >> ~/.profile
echo ‘export PATH=“/usr/local/opt/php#7.3/sbin:$PATH”’ >> ~/.profile
You can run again and that's work.
I want to use imap_append command in my PHP code. But, when I enabled extension=php_imap.dll in the /etc/php.ini file on my Mac, I am seeing following warning when I fire any PHP command:
Example:
php --version
gives output:
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/extensions/no-debug-non-zts-20160303/php_imap.dll' - dlopen(/usr/lib/php/extensions/no-debug-non-zts-20160303/php_imap.dll, 0x0009): dlopen(): file not found: /usr/lib/php/extensions/no-debug-non-zts-20160303/php_imap.dll in Unknown on line 0
I have already tried installing following but no use:
brew tap kabel/php-ext
brew install php-imap
brew install php#7.1-imap
Any clue?
I'm having problems with installation of Couchbase PHP extension (module) to official PHP 7.0 Alpine docker image.
I've managed to install and enable XDebug and OPCache extensions, but couldn't do that for intl and Couchbase extensions.
I've used PECL, Alpine packages and docker-php-ext-* commands, but all are giving me various kinds of error messages in the end. Like the following:
#RUN docker-php-ext-enable /usr/lib/php7/intl.so
# nm: /usr/lib/php7/intl.so: no symbols
#RUN cp /etc/php7/conf.d/00_intl.ini $PHP_CONFIG_SCAN_DIR/intl.ini
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20151012/intl.so' - Error loading shared library /usr/local/lib/php/extensions/no-debug-non-zts-20151012/intl.so: No such file or directory in Unknown on line 0
# not even with echo extension=/usr/lib/php7/intl.so > $PHP_CONFIG_SCAN_DIR/intl.ini
#COPY ./php/couchbase.ini $PHP_CONFIG_SCAN_DIR/couchbase.ini
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php7/couchbase.so' - Error relocating /usr/lib/php7/couchbase.so: php_log_err_with_severity: symbol not found in Unknown on line 0
#RUN docker-php-ext-enable /usr/lib/php7/couchbase.so
# nm: /usr/lib/php7/couchbase.so: no symbols
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php7/couchbase.so' - Error relocating /usr/lib/php7/couchbase.so: php_log_err_with_severity: symbol not found in Unknown on line 0
#RUN docker-php-ext-enable /usr/lib/php7/opcache.so
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php7/opcache.so' - Error relocating /usr/lib/php7/opcache.so: zend_vm_set_opcode_handler_ex: symbol not found in Unknown on line 0
#RUN docker-php-ext-enable /usr/lib/php7/modules/couchbase.so
# error: does not exist
My Dockerfile with results of all the experiments is in this gist.
You can find installation instruction in the official documentation
https://developer.couchbase.com/documentation/server/current/sdk/php/start-using-sdk.html
Are you sure you have installed all dependencies? libcouchbase in particular. Your dockerfile has this section commented out.
I've installed XAMPP on osx 10.10 .
I need php_gmp so i tried to setup it using:
$ brew install php55 --with-gmp
Then, I activated the dependency by modifing php.ini
extension=gmp.so
Apache restarted does not work, so i tried to activate in php.ini:
extension=php_gmp.so
Resterting the server but nothing anyway
PHP error Log
[24-Mar-2016 08:00:26 Europe/Berlin] PHP Warning: PHP Startup: Unable to load dynamic library '/Applications/XAMPP/xamppfiles/lib/php/extensions/no-debug-non-zts-20121212/php_gmp.so' - dlopen(/Applications/XAMPP/xamppfiles/lib/php/extensions/no-debug-non-zts-20121212/php_gmp.so, 9): image not found in Unknown on line 0
[24-Mar-2016 08:00:26 Europe/Berlin] PHP Warning: PHP Startup: Unable to load dynamic library '/Applications/XAMPP/xamppfiles/lib/php/extensions/no-debug-non-zts-20121212/gmp.so' - dlopen(/Applications/XAMPP/xamppfiles/lib/php/extensions/no-debug-non-zts-20121212/gmp.so, 9): image not found in Unknown on line 0
Try reinstalling it but using the code
brew install homebrew/php/php55-gmp
I m new to php and rabbitmq.In Debian I have installed composer.phar in /bin direcoty. Now I want to run below command to fetch the defined dependencies for local project.
php composer.phar install
But it throws an error message using red background as below
[Composer\Downloader\TransportException]
The "https://packagist.org/packages.json" file could not be downloaded: SSL
operation failed with code 1. OpenSSL Error messages:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify
failed
Failed to enable crypto
failed to open stream: operation failed
Please help what to do ?
when enable openSSL in php.ini it throws below warning
Warning: PHP Startup: Unable to load dynamic library '/opt/lampp/lib/php/extensions/no-debug-non-zts-20131226/php_openssl.dll' - /opt/lampp/lib/php/extensions/no-debug-non-zts-20131226/php_openssl.dll: cannot open shared object file: No such file or directory in Unknown on line 0
You have to enable openssl otherwise you can't make a ssl connection.
You can do that in your php.ini if its already installed. Otherwise you have to install it first.
Perhaps as another solution install the php5-cli version with openssl and don't use the lampp stack. You can install the command with apt-get install php5-cli php5-openssl. Then you should use the internal package and it should work.