[Spce-user] cdr error

Andreas Granig agranig at sipwise.com
Mon May 29 08:42:47 EDT 2017


Hi,

You can try a "select count(*) from accounting.cdr" in MySQL to see how
many records you have there, since this is where mediator puts its
results to. Fetch some random ones and check them in detail, e.g. taking
the call_id column and grep for it in kamailio-proxy.log to see what's
going on.

Andreas

On 05/29/2017 01:06 PM, David Martínez wrote:
> Hi,
> 
> Since some days ago, cdr stops working. Seeing whats happening I noticed
> that mediator service was not running. So i started it and then i see
> this on cdr.log file:
> 
> /May 24 13:31:31 sip00 mediator[28631]: Locking process./
> /May 24 13:31:31 sip00 mediator[28631]: Daemonizing process./
> /May 24 13:31:31 sip00 mediator[28632]: Writing pid file./
> /May 24 13:31:31 sip00 mediator[28632]: ACC acc database
> host='localhost', port='3306', user='kamailio', name='kamailio'/
> /May 24 13:31:31 sip00 mediator[28632]: CDR acc database
> host='localhost', port='3306', user='mediator', name='accounting'/
> /May 24 13:31:31 sip00 mediator[28632]: PROV database host='localhost',
> port='3306', user='mediator', name='provisioning'/
> /May 24 13:31:31 sip00 mediator[28632]: STATS database host='localhost',
> port='3306', user='mediator', name='stats'/
> /May 24 13:31:31 sip00 mediator[28632]: Setting up mysql connections./
> /May 24 13:31:31 sip00 mediator[28632]: Up and running, daemonized=1,
> pid-path='/var/run/mediator.pid', interval=10/
> /May 24 13:37:12 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 24 13:37:22 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 24 13:37:32 sip00 mediator[28632]: Overall 93418 CDRs created so far./
> /May 24 13:43:06 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 24 13:43:16 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 24 13:43:26 sip00 mediator[28632]: Overall 186855 CDRs created so far./
> 
> After some days, i see that log says:
> 
> /May 29 11:06:31 sip00 mediator[28632]: Overall 118815884 CDRs created
> so far./
> /May 29 11:13:55 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:14:05 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:14:15 sip00 mediator[28632]: Overall 118916574 CDRs created
> so far./
> /May 29 11:21:10 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:21:20 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:21:30 sip00 mediator[28632]: Overall 119017291 CDRs created
> so far./
> /May 29 11:28:18 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:28:28 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:28:38 sip00 mediator[28632]: Overall 119118049 CDRs created
> so far./
> /May 29 11:34:32 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:34:42 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:34:52 sip00 mediator[28632]: Overall 119218842 CDRs created
> so far./
> /May 29 11:41:24 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:41:34 sip00 mediator[28632]: Lost connection to SQL server
> during query, retrying.../
> /May 29 11:41:44 sip00 mediator[28632]: Overall 119319664 CDRs created
> so far./
> /
> /
> /
> /
> I think that our system is too young to have that number of calls, so i
> search log file when mediator stops and i see:
> 
> /Apr  4 11:38:08 sip00 mediator[3948]: Overall 3038 CDRs created so far./
> /Apr  4 11:38:32 sip00 mediator[3948]: Overall 3039 CDRs created so far./
> /Apr  4 11:38:45 sip00 mediator[3948]: Overall 3040 CDRs created so far./
> /Apr  4 11:38:58 sip00 mediator[3948]: Error getting acc callids: Server
> shutdown in progress/
> /Apr  4 11:38:58 sip00 mediator[3948]: Shutting down./
> /Apr  4 11:38:58 sip00 mediator[3948]: Successfully shut down./
> /Apr  4 11:38:58 sip00 mediator[3948]: Unlocking mediator./
> /
> /
> / /I searched on mailing list (using google cache, because server is
> down now) and i didn’t found how to debug mediator.
> 
> Can anyone help?
> 
> Regards
> 
> 
> _______________________________________________
> Spce-user mailing list
> Spce-user at lists.sipwise.com
> https://lists.sipwise.com/listinfo/spce-user
> 



More information about the Spce-user mailing list