Hi,
We're trying to build a db replication based kamailio server redundancy solution. In recent tests, it seems to make more sense to change the db_mode to 2 (write-back) instead of using db only mode, as in db only mode, a lot of commands and stats don't work anymore.
At this point, we're very close to make this work. However, there is a potential issue I just discovered. When db replicates users/clients registered with other servers in the cluster, although the lookup("location") function can correctly identify the remote users (registered with other servers in the cluster), the db write-back seems to still include those users when loading users/contacts to AoRs in memory. It is just that the remote contacts don't have "socket" information in AoR. Just wonder why the remote users need to be loaded back to memory AoR at all. Should the db write-back be consistent with the lookup function in that the non-local users be filtered out from the AoR?
So far, even with remote contacts in AoR we can still make this work, but it seems a waste of memory to load remote contacts without sockets on each server. Hope I didn't miss any design decision/principle that calls for AoR for both local and non-local users.
Thanks,
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/issues/325
A patch was pushed recently to allow skipping records that don't have the local socket - see e737942fbabc1f5d6d50a51c667cc0533cfe5777
Note that if you don't want to share the location records across multiple kamailio instances, then you can just use different database or table names. For a different table name, structure has to be same as location table and in addition the newname_attrs has to be like location_attrs. Besides these, add to version table records similar to location and location_attrs for the new tables.
If there is anything else to discuss, use sr-users mailing list, on the bug tracker we try to keep only the stuff related to bugs and feature requests, not community discussions.
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/issues/325#issuecomment-140699529
Closed #325.
--- Reply to this email directly or view it on GitHub: https://github.com/kamailio/kamailio/issues/325#event-410805418