Pgpool install - libpq is not installed or libpq is old Based on the documentation here, I want to create a pgpool II with PostgreSQL databases. When I try to install, I encounter this error:

  configure: error: libpq is not installed or libpq is old


Searching the pgpool website, they mention to run ./configure with this command:

  --with-pgsql 


OR

   --with-pgsql-includedir


OR

   --with-pgsql-libdir 


But still I'm facing the same problem. Can anyone guide me what can I do from here?

I am running PostgreSQL 9.2 intalled from a yum package on CentOS 5.
Instead of compiling PgPool, why not just install it from package management?

yum install postgresql-pgpool-II


I don't use CentOS, but that's it's package name in Fedora 17, and the two are usually consistent. 

Since you're using a PostgreSQL 9.2 installed via Yum on CentOS 5, you're obviously using a 3rd party packaging of PostgreSQL, so you're likely to be using the yum.postgresql.org repository. This repository claims to contain PgPool-II, so try:

yum search pgpool


and see if you find any packages. Get details on them with:

yum info packagename




Otherwise, for compiling PgPool you need the development package for PostgreSQL installed:

yum install postgresql-devel


If that alone doesn't do the trick, try making sure pg_config is on the PATH:

export PATH=$PATH:/usr/pgsql-9.2/bin
./configure


You shouldn't need to specify a libdir or includedir explicitly, as the're in /usr/include and /usr/lib (or /usr/lib64) on CentOS and those are default search locations for configure and gcc. It's most likely that you just don't have the development headers installed.