kamailio icon indicating copy to clipboard operation
kamailio copied to clipboard

dialog and dmq in db_mode 2 - dialog_vars entries created and not deleted

Open henningw opened this issue 5 years ago • 2 comments

Dialog and DMQ in db_mode 2 - dialog_vars entries created and not deleted.

Szenario: two proxies in DMQ synchronization with additional database. Configuration identical on both machines:

root@proxy-1:/etc/kamailio# grep dialog kamailio.cfg
loadmodule "dialog.so"
modparam("dialog", "db_mode", 2)
modparam("dialog", "db_update_period", 10)
modparam("dialog", "enable_dmq", 1)
modparam("dialog", "default_timeout", 60);
modparam("dialog", "send_bye", 1)

Call is placed on proxy1. Proxy1 handles the call, and synchronize the dialog data to proxy2. Proxy2 is able to list the dialog with kamcmd dlg.list etc.. Proxy2 will not write the dialog into dialog table, but will write the dialog variables to the dialog_var table:

root@proxy-2:/etc/kamailio# mysql kamailio
MariaDB [kamailio]> select * from dialog; select * from dialog_vars;
Empty set (0.00 sec)
+----+------------+---------+-------------+---------------------------------+
| id | hash_entry | hash_id | dialog_key  | dialog_value                    |
+----+------------+---------+-------------+---------------------------------+
|  9 |       3479 |    1648 | _uac_fu     | sip:[email protected] |
| 10 |       3479 |    1648 | _uac_funew  | sip:[email protected]           |
| 11 |       3479 |    1648 | _uac_fdp    |                                 |
| 12 |       3479 |    1648 | _uac_fdpnew |                                 |
| 13 |       3479 |    1648 | _uac_to     | sip:[email protected] |
| 14 |       3479 |    1648 | _uac_tonew  | sip:[email protected]            |
| 15 |       3479 |    1648 | _uac_tdp    |                                 |
| 16 |       3479 |    1648 | _uac_tdpnew |                                 |
+----+------------+---------+-------------+---------------------------------+
8 rows in set (0.00 sec)

Because of this the dialog_vars will grow for every call.

In db_mode 1 this dialog_vars entries (and also dialog entries) are not written. I suggest to adapt db_mode 2 with DMQ to the same behaviour.

henningw avatar Oct 04 '19 13:10 henningw

@charlesrchance do you had a chance have a quick look to this (as discussed on the devel meeting)?

henningw avatar Nov 29 '19 18:11 henningw

Is there any plan to fix this issue ? We are facing it on production

sagarmalam avatar Jul 21 '22 12:07 sagarmalam

This issue is stale because it has been open 6 weeks with no activity. Remove stale label or comment or this will be closed in 2 weeks.

github-actions[bot] avatar Nov 08 '23 08:11 github-actions[bot]