Saving CEL and CDR to postgres

Hey there, I’m pretty new to logs and modules on asterisk and wanted to store it in Postgres, configured the cel_pgsql.conf

; Sample Asterisk config file for CEL logging to PostgresSQL
[global]
hostname=localhost
port=5432
dbname=my_postgres_db
password=password
user=postgres_user
table=cel

The thing is I don’t have the cdr_xxxxx.so file,
Here’s the output of : cdr show status

Call Detail Record (CDR) settings

Logging: Enabled
Mode: Simple
Log unanswered calls: No
Log congestion: No

  • Registered Backends

Adaptive ODBC

How do I register psql as a backend ?

CEL and CDR are two separate things. CEL would use the cel_pgsql module and CDR would use the cdr_pgsql module.

You are right, my problem is with registering back-ends for the connectivity. How do I do that ?

Are they actually being built (have you checked menuselect)? If not were the dependencies installed to build them? If so have you checked the console at startup to see if they show an error? Did you manually try to load them using module load?

Sorry, I’m new to this.I installed FreePBX, didn’t use menuselect. How do I install the dependencies ? I have installed libpqxx-dev as per the article suggests here (https://wiki.asterisk.org/wiki/display/AST/PostgreSQL+CEL+Backend) and did everything, It still doesn’t insert records in the Postgres.

I don’t work on FreePBX or the distribution so I don’t really know how to make such modules work in that environment. It’s generally made to be a standalone solution and not to be modified in such a fashion.

Yeah, yet It seems to be missing some dependencies. What commands do you use on SSH to install them, maybe I can give those a shot ?

I don’t use the distribution or what it is based on, so I don’t know. Someone else may be able to provide information or asking on their forum may be more useful.

1 Like

Okay thanks, anyone you recommend ?

There is only one relevant FreePBX forum: https://community.freepbx.org/

2 Likes

okay Thanks ! will post there.