Duplicate CDR’s In Mysql

Home » Asterisk Users » Duplicate CDR’s In Mysql
Asterisk Users 2 Comments

Hi all,

I have a problem I’ve not seen before. My Asterisk server stores CDR’s via mysql, and I’m getting duplicate records.

For example:

mysql> select uniqueid,count(*) from cdr group by uniqueid having count(*)>1;
+————————–+———-+
| uniqueid | count(*) |
+————————–+———-+
| server12-1515090905.2182 | 5 |
| server12-1515091190.2215 | 3 |
+————————–+———-+
2 rows in set (0.68 sec)

If I query for each uniqueid, I see that the records are identical. I have a Perl script that goes through and removes the duplicates. Otherwise, EVERY CDR would be duplicated.

Now, my Asterisk server was configured with multiple CDR backends, but I unloaded those modules. Here is what I have configured during run-time:

*CLI> cdr show status

Call Detail Record (CDR) settings
——————————–

2 thoughts on - Duplicate CDR’s In Mysql

  • Hi all,

    I have a problem I’ve not seen before. My Asterisk server stores CDR’s via mysql, and I’m getting duplicate records.

    For example:

    mysql> select uniqueid,count(*) from cdr group by uniqueid having count(*)>1;
    +————————–+———-+
    | uniqueid | count(*) |
    +————————–+———-+
    | server12-1515090905.2182 | 5 |
    | server12-1515091190.2215 | 3 |
    +————————–+———-+
    2 rows in set (0.68 sec)

    If I query for each uniqueid, I see that the records are identical. I have a Perl script that goes through and removes the duplicates. Otherwise, EVERY CDR would be duplicated.

    Now, my Asterisk server was configured with multiple CDR backends, but I unloaded those modules. Here is what I have configured during run-time:

    *CLI> cdr show status

    Call Detail Record (CDR) settings
    ——————————–