Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Daniel-Constantin Mierla
On 8/30/12 4:05 PM, Øyvind Kolbu wrote: On 2012-08-30 at 13:32, Daniel-Constantin Mierla wrote: Then, have in mind that there are several operations, one after the other: - update - which do update to all write db servers - test affected rows (which is always working on last write (update) conn

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Øyvind Kolbu
On 2012-08-30 at 13:32, Daniel-Constantin Mierla wrote: > Then, have in mind that there are several operations, one after the other: > - update - which do update to all write db servers > - test affected rows (which is always working on last write (update) > connection) > - insert if affected rows

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Juha Heinanen
Øyvind Kolbu writes: > Yes, I actually want both, HA + replication, by using db_cluster as the > replicator. And as I've demonstrated the location-table on non-primary > servers will lack entries after downtime, which is bad. that should not be the case if you use master-master replication in you

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Daniel-Constantin Mierla
On 8/30/12 12:50 PM, Øyvind Kolbu wrote: On 2012-08-30 at 11:32, Daniel-Constantin Mierla wrote: On 8/30/12 10:29 AM, Øyvind Kolbu wrote: Yes, I actually want both, HA + replication, by using db_cluster as the replicator. And as I've demonstrated the location-table on non-primary servers will

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Øyvind Kolbu
On 2012-08-30 at 11:32, Daniel-Constantin Mierla wrote: > On 8/30/12 10:29 AM, Øyvind Kolbu wrote: > > Yes, I actually want both, HA + replication, by using db_cluster as the > > replicator. And as I've demonstrated the location-table on non-primary > > servers will lack entries after downtime, whi

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Daniel-Constantin Mierla
On 8/30/12 10:29 AM, Øyvind Kolbu wrote: On 2012-08-30 at 10:09, Daniel-Constantin Mierla wrote: On 8/29/12 9:15 PM, Øyvind Kolbu wrote: On 2012-08-29 at 20:16, Daniel-Constantin Mierla wrote: is usrloc module configured in db only mode? Yes, db_mode is 3. this might not be very suitable fo

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Øyvind Kolbu
On 2012-08-30 at 10:09, Daniel-Constantin Mierla wrote: > On 8/29/12 9:15 PM, Øyvind Kolbu wrote: > > On 2012-08-29 at 20:16, Daniel-Constantin Mierla wrote: > >> is usrloc module configured in db only mode? > > Yes, db_mode is 3. > > this might not be very suitable for db_cluster usage if one db

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-30 Thread Daniel-Constantin Mierla
Hello, On 8/29/12 9:15 PM, Øyvind Kolbu wrote: On 2012-08-29 at 20:16, Daniel-Constantin Mierla wrote: is usrloc module configured in db only mode? Yes, db_mode is 3. this might not be very suitable for db_cluster usage if one db server is done, because right now the reading is done to the

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-29 Thread Øyvind Kolbu
On 2012-08-29 at 20:16, Daniel-Constantin Mierla wrote: > is usrloc module configured in db only mode? Yes, db_mode is 3. > Read operation cannot be done in 'parallel' fashion of the cluster, it > is only serial or round robin, stopping at first successful query (even > when there is no data re

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-29 Thread Daniel-Constantin Mierla
Hello, On 8/29/12 1:23 PM, Øyvind Kolbu wrote: On 2012-08-29 at 07:38, Daniel-Constantin Mierla wrote: seeing the sql commands would help, also the log messages with debug=3 Now with "db_check_update" enabled. I've deleted the row for username 2549619 in the voip_location table from the second

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-29 Thread Øyvind Kolbu
On 2012-08-29 at 07:38, Daniel-Constantin Mierla wrote: > seeing the sql commands would help, also the log messages with debug=3 Now with "db_check_update" enabled. I've deleted the row for username 2549619 in the voip_location table from the secondary server between then re-registration. I thi

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-28 Thread Daniel-Constantin Mierla
On 8/28/12 10:23 PM, Øyvind Kolbu wrote: On 2012-08-28 at 21:56, Daniel-Constantin Mierla wrote: On 8/28/12 6:34 PM, Øyvind Kolbu wrote: Tried setting modparam("usrloc", "db_check_update", 1) but to no avail. what do you mean by the last line? This should be the solution to for the is

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-28 Thread Øyvind Kolbu
On 2012-08-28 at 21:56, Daniel-Constantin Mierla wrote: > On 8/28/12 6:34 PM, Øyvind Kolbu wrote: > > > > Tried setting > > > > modparam("usrloc", "db_check_update", 1) > > > > but to no avail. > > what do you mean by the last line? This should be the solution to for > the issue. That I tri

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-28 Thread Daniel-Constantin Mierla
Hello, On 8/28/12 6:34 PM, Øyvind Kolbu wrote: On 2012-08-24 at 10:48, Øyvind Kolbu wrote: First impression is that everything is working now, thanks! At least registrations are getting populated in both databases from both servers. As I'm out traveling I havn't yet tested calling and whether o

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-28 Thread Øyvind Kolbu
On 2012-08-24 at 10:48, Øyvind Kolbu wrote: > First impression is that everything is working now, thanks! At least > registrations are getting populated in both databases from both servers. As > I'm out traveling I havn't yet tested calling and whether or not the > failover works as expected. I ass

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-24 Thread Øyvind Kolbu
On 2012-08-24 at 09:22, Daniel-Constantin Mierla wrote: > Hello, > > can you print the content of cls in frame 0 inside gdb? > > p *cls (gdb) p *cls $1 = {name = {s = 0xb7b5a958 "data2=>voip2_data2=8r9p", len = 5}, clsid = 1761460487, ref = 1, rlist = {{clist = {0x0, 0x0, 0x0, 0x0, 0x0}, clen =

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-24 Thread Daniel-Constantin Mierla
Hello, can you print the content of cls in frame 0 inside gdb? p *cls I found and fixed a potential issue, by now in master: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=4d15ba97bab58108cfedc45158d90583f67cdadf You can cherry pick it in branch 3.3 and try it, with: git

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-23 Thread Daniel-Constantin Mierla
Hello, On 8/22/12 6:34 PM, Øyvind Kolbu wrote: On 2012-08-22 at 16:01, Daniel-Constantin Mierla wrote: Hello, can you send the output of 'bt full' from gdb? #0 0x002fd7da in db_cluster_insert (_h=0xb7d2dc88, _k=0xbf9ac954, _v=0xbf9ac7ec, _n=18) at dbcl_api.c:334 I will look over it when I

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-22 Thread Daniel-Constantin Mierla
Hello, can you send the output of 'bt full' from gdb? Simple bt shows only the line where a define is executed, hopefully bt full will get the values from the inside defines to spot the problem. Also, can you give it a quick try with 9p instead of 7p for both connections? Cheers, Daniel

Re: [SR-Users] db_cluster together with the registrar module = signal 11

2012-08-22 Thread Øyvind Kolbu
On 2012-08-22 at 15:32, Øyvind Kolbu wrote: [...] Some more details: # kamailio -V version: kamailio 3.3.1 (i386/linux) aae4e4 flags: STATS: Off, USE_IPV6, USE_TCP, USE_TLS, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC, F_MALLOC, USE_FUTEX, FAST

[SR-Users] db_cluster together with the registrar module = signal 11

2012-08-22 Thread Øyvind Kolbu
Hi, I upgraded our system to Kamailio 3.3 to take advantage of the new db_cluster module. Currently we have two registration/location servers each with their own sql-server. Authenticated REGISTER messages are forwarded to the other server, which uses the 0x02 flag to save() in order to store it w