CodeIgniter Forums
New Server--PHP Error - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5)
+--- Forum: Installation & Setup (https://forum.codeigniter.com/forumdisplay.php?fid=9)
+--- Thread: New Server--PHP Error (/showthread.php?tid=80770)



New Server--PHP Error - bhogsett - 12-15-2021

I use inMotion for a shared server.  InMotion just moved my site to a new faster better etc. server.

I now get this error message on all the pages:

"A PHP Error was encountered
Severity: Core Warning

Message: PHP Startup: Unable to load dynamic library 'pdo_pgsql.so' (tried: /opt/cpanel/ea-php74/root/usr/lib64/php/modules/pdo_pgsql.so (libpq.so.5: cannot open shared object file: No such file or directory), /opt/cpanel/ea-php74/root/usr/lib64/php/modules/pdo_pgsql.so.so (/opt/cpanel/ea-php74/root/usr/lib64/php/modules/pdo_pgsql.so.so: cannot open shared object file: No such file or directory))"

I use MySQL(myslqi) on the site.  I am running version3.x of Codeigniter.  It has worked flawlessly for several years.

I think this is clearly a server configuration issue.  InMotion tech support looked at the issue to at least the second level and threw up their hands and said maybe check with Codeigniter.

Can anyone tell me what needs to be done?  Thanks.


Bill Hogsett


RE: New Server--PHP Error - manager - 12-15-2021

Check phpinfo(). Is pdo_pgsql extension enabled?

And check this: https://www.php.net/manual/en/pgsql.installation.php


RE: New Server--PHP Error - bhogsett - 12-16-2021

(12-15-2021, 09:46 PM)manager Wrote: Check phpinfo(). Is pdo_pgsql extension enabled?

And check this: https://www.php.net/manual/en/pgsql.installation.php

Thanks, phpinfo has this in the Configure Command section:

'--enable-pdo=shared' '--with-pdo-odbc=shared,unixODBC,/usr' '--with-pdo-mysql=shared,mysqlnd'
'--with-pdo-pgsql=shared,/usr' '--with-pdo-sqlite=shared,/usr' '--with-sqlite3=shared,/usr'

I do not use postgres.

(12-15-2021, 09:46 PM)manager Wrote: Check phpinfo(). Is pdo_pgsql extension enabled?

And check this: https://www.php.net/manual/en/pgsql.installation.php

I replied too fast!

In the PDO section of phpinfo I have:

pdo_mysql
PDO_ODBC
pdo_sqlite

BUT, no pdo_pgsql

Is that the problem?


RE: New Server--PHP Error - manager - 12-16-2021

Yes. It shoud be like: 
pdo_pgsql
PDO driver for Postgre SQL  - enabled

So to solve your problem just install this extension.


RE: New Server--PHP Error - InsiteFX - 12-17-2021

He can not install it, he's on shared hosting. He needs to get inmotion tech support to install.