i have install php8.1-fpm and setup it with apache2/FGPI. But after many operation, impossible to "enable pdo-mysql".
i have make this sudo apt-get install php8.1-pdo-mysql
with result
Note, selecting 'php8.1-mysql' instead of 'php8.1-pdo-mysql'
php8.1-mysql is already the newest version (8.1.5-1+b1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded
But, when i do php -m
mysql not appear.
[PHP Modules]
Core
curl
date
dom
filter
gd
gmp
hash
igbinary
imap
intl
json
libxml
mbstring
OAuth
openssl
pcntl
pcre
redis
Reflection
session
SimpleXML
sodium
SPL
standard
xdebug
xml
xmlreader
xmlwriter
xsl
yaml
zip
zlib
[Zend Modules]
Xdebug
When i try to know why, it seem because Pdo is include on php8.1-common, but ... not appear to.
An other action that i have doing is to remove php8.1-mysql and reinstall php8.11-pdo-mysql with sudo apt-get install php8.1-pdo-mysql
, the result is
but, nothing on mods-available
EDIT 1 When i look with phpinfo() on a php file to use php-fpm, i have this result
/etc/php/8.1/fpm/conf.d/15-xml.ini,
/etc/php/8.1/fpm/conf.d/20-curl.ini,
/etc/php/8.1/fpm/conf.d/20-dom.ini,
/etc/php/8.1/fpm/conf.d/20-gd.ini,
/etc/php/8.1/fpm/conf.d/20-gmp.ini,
/etc/php/8.1/fpm/conf.d/20-igbinary.ini,
/etc/php/8.1/fpm/conf.d/20-imap.ini,
/etc/php/8.1/fpm/conf.d/20-intl.ini,
/etc/php/8.1/fpm/conf.d/20-mbstring.ini,
/etc/php/8.1/fpm/conf.d/20-oauth.ini,
/etc/php/8.1/fpm/conf.d/20-redis.ini,
/etc/php/8.1/fpm/conf.d/20-simplexml.ini,
/etc/php/8.1/fpm/conf.d/20-xdebug.ini,
/etc/php/8.1/fpm/conf.d/20-xmlreader.ini,
/etc/php/8.1/fpm/conf.d/20-xmlwriter.ini,
/etc/php/8.1/fpm/conf.d/20-xsl.ini,
/etc/php/8.1/fpm/conf.d/20-yaml.ini,
/etc/php/8.1/fpm/conf.d/20-zip.ini
EDIT2
When i use php8.1-mysql
instead of php8.1-pdo-mysql
same result because apt automaticly switch on php8.1-mysql when you try to install pdo-mysql.
EDIT3
The command sudo phpenmod pdo_mysql
take the result
WARNING: Module pdo_mysql ini file doesn't exist under /etc/php/8.1/mods-available
WARNING: Module pdo_mysql ini file doesn't exist under /etc/php/8.1/mods-available
This is the real problem, that the needed file never been created by sudo apt-get install php8.1-mysql