我有一个特定的情况,我需要将Kamailio连接到PostgreSQL DB,而不是MySQL。有没有人能提供这方面的步骤。尝试了论坛中的多个步骤,但失败了。
面临的问题:每当kamailio在PostgreSQL中创建数据库时,它都会不断询问密码,最终都会失败。
Ubuntu版本: 16.04 LTS Kamailio: 5.0
到目前为止,我做了以下工作: 1.包含postgre模块2.修改了kamailio.cfg,增加了以下几行:
#!ifdef WITH_PGSQL
# - database URL - used to connect to database server by modules such
# as: auth_db, acc, usrloc, a.s.o.
#!ifndef DBURL
#!define DBURL "postgres://kamailio:password@localhost/kamailio"
#!endif
#!endif这是我的文件kambdctlrc:
# The Kamailio configuration file for the control tools.
#
# Here you can set variables used in the kamctl and kamdbctl setup
# scripts. Per default all variables here are commented out, the control tools
# will use their internal default values.
## your SIP domain
SIP_DOMAIN=sip.<DOMAIN>.net
## chrooted directory
# $CHROOT_DIR="/path/to/chrooted/directory"
## database type: MYSQL, PGSQL, ORACLE, DB_BERKELEY, DBTEXT, or SQLITE
# by default none is loaded
#
# If you want to setup a database with kamdbctl, you must at least specify
# this parameter.
DBENGINE=PGSQL
## database host
DBHOST=localhost
## database host
# DBPORT=3306
## database name (for ORACLE this is TNS name)
DBNAME=kamailio
# database path used by dbtext, db_berkeley or sqlite
# DB_PATH="/usr/local/etc/kamailio/dbtext"
## database read/write user
DBRWUSER="kamailio"
## password for database read/write user
DBRWPW="password"
## database read only user
DBROUSER="kamailioro"提前感谢!!
发布于 2018-04-06 19:12:52
最后,我们解决了这个问题,这只是.pgpass文件中的一个小错误,最终导致了身份验证问题。
https://stackoverflow.com/questions/48735686
复制相似问题