[SR-Users] event on table location Duplicate entry for key 'ruid_idx'

Daniel-Constantin Mierla miconda at gmail.com
Wed Jan 14 10:11:01 CET 2015


Would be interesting to discover the issue that got here. server_id can
help in the future, but the chance of getting overlapping unique ids is
very low even with it. That's why I asked for 'kamctl ps' to see if
there are PIDs overlapping on the two systems. Then it is also the start
time that matters, so should be started in the same second.

On the other hand, the error can be from same system or maybe it happens
after a restart when both load the records from db or something else ...
so figuring out the cause will rule out there is no issue, I would still
want the details I asked for.

Cheers,
Daniel

On 13/01/15 13:48, Sergey Okhapkin wrote:
> Add server_id=N to kamailio.cfg on both servers, where N is an integer with 
> unique value. userloc module will use server_id value to create unique between 
> servers ruid.
>
> On Tuesday 13 January 2015 10:53:28 Daniel-Constantin Mierla wrote:
>> Hello,
>>
>> On 12/01/15 22:54, Yuriy Gorlichenko wrote:
>>> Hello. We use 2 kamailio servers  cluster  and we have porblems with
>>> db. Database failed pecause of error:
>>>
>>> Could not execute Write_rows_v1 event on table production.location;
>>> Duplicate entry 'uloc-54aae947-86d-a67' for key 'ruid_idx',
>>> Error_code: 1062; handler error HA_ERR_FOUND_DUPP_KEY; the event's
>>> master log FIRST, end_log_pos 380, Internal MariaDB error code: 1062
>>>
>>> But a location table no row 'ruid_idx' and no entry uloc-54aae947-86d-a67.
>> ruid_idx is a unique key constraint on column uid. Can you check if you
>> have that value in ruid column?
>>
>> Also, can you share the output of 'kamctl ps' for each of the servers?
>> Assuming you haven't restarted the kamailios.
>>
>> Provide the output of 'kamailio -V' to figure out the version and the
>> parameters for usrloc module.
>>
>> Cheers,
>> Daniel
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda




More information about the sr-users mailing list