[asterisk-bugs] [Asterisk 0017392]: pgsql realtime module not using local unix socket

Asterisk Bug Tracker noreply at bugs.digium.com
Tue May 25 12:42:56 CDT 2010


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=17392 
====================================================================== 
Reported By:                dps
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   17392
Category:                   Resources/res_config_pgsql
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
Asterisk Version:           1.6.2.7 
JIRA:                        
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-05-25 00:39 CDT
Last Modified:              2010-05-25 12:42 CDT
====================================================================== 
Summary:                    pgsql realtime module not using local unix socket
Description: 
Hello,

I am using asterisk realtime with a postgresql database on same server.

In res_pgsql.conf if I specify dbhost=localhost and dbport=5423 then a tcp
connection is established with the pgsql db and everything works fine.

However I would like to connect to db using local unix socket. When I
remove the dbhost and dbport entries and instead specify
dbsock=/tmp/.s.PGSQL.5432 then I get the following warnings on startup, but
no connection with db is established.

WARNING[1819]: res_config_pgsql.c:1367 parse_config: PostgreSQL RealTime:
No database host found, using localhost via socket.
WARNING[1819]: res_config_pgsql.c:1383 parse_config: PostgreSQL RealTime:
No database port found, using 5432 as default.

The asterisk version I am using is 1.6.2.7


====================================================================== 

---------------------------------------------------------------------- 
 (0122413) dps (reporter) - 2010-05-25 12:42
 https://issues.asterisk.org/view.php?id=17392#c122413 
---------------------------------------------------------------------- 
The following entries in res_pgsql.conf works
[general]
dbhost=localhost
dbport=5432
dbname=asteriskdb
dbuser=psql
;dbsock=/tmp/.s.PGSQL.5432

And if I change it to
[general]
;dbhost=localhost
;dbport=5432
dbname=asteriskdb
dbuser=psql
dbsock=/tmp/.s.PGSQL.5432

then it does not work 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-05-25 12:42 dps            Note Added: 0122413                          
======================================================================




More information about the asterisk-bugs mailing list