Score:1

pdo_mysql.so problem when try to install composer

cn flag

I want to install composer by apt install or composer-setup.php.

After composer made the setup, and says composer -V I am getting this error message.

Warning: PHP Startup: Unable to load dynamic library 'pdo_mysql.so' (tried: /usr/lib/php/20210902/pdo_mysql.so (/usr/lib/php/20210902/pdo_mysql.so: undefined symbol: pdo_parse_params), /usr/lib/php/20210902/pdo_mysql.so.so (/usr/lib/php/20210902/pdo_mysql.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

The file is there.

ls /usr/lib/php/20210902/pdo_mysql.so /usr/lib/php/20210902/pdo_mysql.so

My sites works on localhost, sql running, what could be wrong?

I've tried purge and reinstall the php8.1-mysql but does not helps.

It also happens with any command by php, like php -i. It runs, but I am getting this error.

EDIT:

I've compeletely purged the whole PHP and reinstall, it helps.

uz flag
Jos
Please add the output of `php -i | grep 20210902`. It should list `/usr/lib/php/20210902` as the extension directory.
vaso123 avatar
cn flag
did you read my post? `ls /usr/lib/php/20210902/pdo_mysql.so /usr/lib/php/20210902/pdo_mysql.so` it is there.
uz flag
Jos
That wasn't my point. My point was, is that directory getting picked up as the directory for extensions?
vaso123 avatar
cn flag
oh man, no that is not a directoy. I've checked the relevant file and there it is. anyway, solved.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.