Hello,
On 2/9/12 2:06 PM, Perazim wrote:
I got a little further but still not working. Here are changes I have made to default:
kamailio.cfg:
... # *** To enable mysql: #!define WITH_MYSQL # # *** To enable authentication execute: # - enable mysql #!define WITH_AUTH # - add users using 'kamctl' ...
... ####### Defined Values #########
# *** Value defines - IDs used later in config #!ifdef WITH_MYSQL # - database URL - used to connect to database server by modules such # as: auth_db, acc, usrloc, a.s.o. #!define DBURL "sqlite:////usr/local/etc/kamailio/db.sqlite" #!endif ...
... ####### Modules Section ########
# set paths to location of modules (to sources or installation folders) #!ifdef WITH_SRCPATH mpath="modules_k:modules" #!else mpath="/usr/local/lib/kamailio/modules_k/:/usr/local/lib/kamailio/modules/" #!endif
#!ifdef WITH_MYSQL loadmodule "db_sqlite.so" #!endif ...
and kamctlrc:
... ## your SIP domain SIP_DOMAIN=perazim.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=SQLITE
## database host # DBHOST=localhost ...
Still looks like kamailio is looking for mysql:
[root@travelmate yossi]# kamctl db show user psql: could not connect to server: Connection refused Is the server running on host "localhost" and accepting TCP/IP connections on port 5432? [root@travelmate yossi]#
I checked db.sqlite permissions and this should not be a problem.
Tried it with firewall disabled just in case.
What did I miss?
psql is for postgres, are you sure you set sqlite as db driver for kamctl (in kamctlrc)?
Cheers, Daniel