Comment 8 for bug 994194

Revision history for this message
Clint Byrum (clint-fewbar) wrote : Re: [Bug 994194] Re: Unable to load dynamic library pdo_pgsql.so

Excerpts from JazZ's message of Sat May 05 16:10:33 UTC 2012:
> When i do 'php -i | grep extension_dir', I got:
>
> PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626+lfs/pdo_mysql.so' - /usr/lib/php5/20090626+lfs/pdo_mysql.so: undefined symbol: pdo_parse_params in Unknown on line 0
> PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626+lfs/pdo_pgsql.so' - /usr/lib/php5/20090626+lfs/pdo_pgsql.so: undefined symbol: pdo_parse_params in Unknown on line 0
> extension_dir => /usr/lib/php5/20090626+lfs => /usr/lib/php5/20090626+lfs
>
> So the directory is not exactly the same that yours. But directories
> returned by 'php -i', and phpinfo() are the same.
>
> Concerning the php configuration, I know that in the past, I have
> followed a tutorial to improve the secutity of the server. But every
> thing worked and I dont think that I have changed some links (only php
> parameters).
>
>
> But there is something more interesting when I do 'debsums -e php5-common' :
> debsums: missing file /etc/php5/conf.d/pdo.ini (from php5-common package)
> /etc/cron.d/php5 OK
>
> I have reinstalled php5-common hoping to see this file created, but
> whitout any result. I have made also 'dpkg-reconfigure php5-common'
> without any result.
>
> Others debsums worked well.

Aha! The directory change was a red herring.

The missing conf file is definitely the reason you're having
problems. Without pdo loaded, you can't load any of the pdo_* extensions.

dpkg -i --force-conf-missing /var/cache/apt/archives/php5-common_5.3.10-1ubuntu3_i386.deb

(I'm using the values in your apport collected bug report, but you get
the idea)

This will force dpkg to restore the packaged version of that file. Dpkg
always honors a missing config file, since you, the admin, would only
have removed it on purpose. So the --force-conf-missing will disable
that behavior and install any missing configuration files.