PostgreSQL in the core

From FreeSWITCH Wiki
Jump to: navigation, search

Postgres native support was added in FreeSWITCH 1.2.5.

Contents

Dependencies

libpq and the associated dev packages are required

CentOS

yum install libpq-devel

Debian

sudo apt-get install libpq-dev

Configure

If you have installed a later version of PostgreSQL from a source other then your distro's repositories, and its installed to a non-standard location such as /usr/pgsql-9.3 you will need to adjust your PATH and/or PKG_CONFIG_PATH environment variables to properly locate either pg_config or libpq.pc

export PKG_CONFIG_PATH=/usr/pgsql-9.3/lib/pkgconfig
export PATH=/usr/pgsql-9.3/bin:$PATH
./configure --enable-core-pgsql-support 

Adjust your PKG_CONFIG_PATH and PATH as required for your platform.

switch.conf.xml

<param name="core-db-dsn" value="pgsql://hostaddr=127.0.0.1 dbname=freeswitch user=freeswitch password= options='-c client_min_messages=NOTICE' application_name='freeswitch'" />

Additional Information

http://fisheye.freeswitch.org/changelog/freeswitch.git?cs=1f4dba6b60c85e0bbbb2ddb0cf09dc6f677932ef