Hello,
Is anyone able to confirm whether the cluster definition I provided should indeed do what I think it should? If so, I will take a look further myself to find the reason why not.
Thanks in advance,
Charles
Hi All,I'm having difficulties with the above module and can't see what I'm doing wrong.Config as follows:modparam("db_cluster", "connection", "db01=>mysql://readwrite:password@db01.domain.com/kamailio")
modparam("db_cluster", "connection", "db02=>mysql://readonly:password@db02.domain.com/kamailio")
modparam("db_cluster", "cluster", "cls1=>db01=0s9s;db02=9s0s")As you can see, there are two database servers - a master and a slave. I am trying to force all read operations to the slave (db02) and all write operations to the master (db01).Unless I am missing the point, the above priorities should achieve the desired effect. However, it seems to be going wrong somewhere as write operations are being sent to the slave:ERROR: db_mysql [km_dbase.c:122]: driver error on query: DELETE command denied to user 'readonly'@'x.x.x.x' for table 'location'
ERROR: db_mysql [km_dbase.c:122]: driver error on query: UPDATE command denied to user 'readonly'@'x.x.x.x' for table 'location'
ERROR: db_mysql [km_dbase.c:122]: driver error on query: INSERT command denied to user 'readonly'@'x.x.x.x' for table 'location'It is the same for all modules, by the way, not just usrloc. For each module, I have db_url set to "cluster://cls1".If I change the cluster definition to "cls1=>db01=9s9s;db02=0s0s", all operations (read and write) are sent to db01 as expected.Am I missing something here? Can anyone see what I may be doing wrong?Many thanks,Charles