[OpenSIPS-Users] Presence issue
Dan Pascu
dan at ag-projects.com
Fri Sep 28 07:36:50 EDT 2018
On 24 Sep 2018, at 23:14, Bogdan-Andrei Iancu wrote:
> Hi Dan,
>
> I'm trying to hunt this issue for a while , see:
>
> https://github.com/OpenSIPS/opensips/issues/1422
> https://github.com/OpenSIPS/opensips/issues/1378
>
> But I never was able to reproduce it local, in order to debug it. Can you reproduce it ?
It happens to me for every PUBLISH received.
>
>
> Best regards,
>
> Bogdan-Andrei Iancu
>
> OpenSIPS Founder and Developer
> http://www.opensips-solutions.com
> OpenSIPS Bootcamp 2018
> http://opensips.org/training/OpenSIPS_Bootcamp_2018/
>
> On 09/21/2018 02:16 PM, Dan Pascu wrote:
>> After I started to test the lastest git code from master I noticed errors like this in my logs:
>>
>>
>> Sep 21 13:01:41 node03 /usr/sbin/opensips[22838]: CRITICAL:db_mysql:wrapper_single_mysql_real_query: driver error (1062): Duplicate entry 'dan-test.sip2sip.info-presence-a.1537527127.22838.2.1' for key 'presentity_idx'
>> Sep 21 13:01:41 node03 /usr/sbin/opensips[22838]: ERROR:core:db_do_update: error while submitting query
>> Sep 21 13:01:41 node03 /usr/sbin/opensips[22838]: ERROR:presence:update_presentity: updating published info in database
>> Sep 21 13:01:41 node03 /usr/sbin/opensips[22838]: ERROR:presence:handle_publish: when updating presentity
>>
>>
>> I checked the presentity table and there is NO record with etag = a.1537527127.22838.2.1 in the database. I found however multiple records in the database for that particular account some of which are long expired yet not deleted from the database. The records seem to increase every time I publish presence:
>>
>> MariaDB [opensips]> select username, domain, event, etag from presentity where username = 'dan';
>> +----------+-------------------+----------+------------------------+
>> | username | domain | event | etag |
>> +----------+-------------------+----------+------------------------+
>> | dan | test.sip2sip.info | presence | a.1537455410.31931.2.2 |
>> | dan | test.sip2sip.info | presence | a.1537456928.2432.2.0 |
>> | dan | test.sip2sip.info | presence | a.1537526062.20412.1.0 |
>> | dan | test.sip2sip.info | presence | a.1537526092.20529.2.0 |
>> | dan | test.sip2sip.info | presence | a.1537526122.20854.1.0 |
>> | dan | test.sip2sip.info | presence | a.1537526997.22186.2.0 |
>> | dan | test.sip2sip.info | presence | a.1537527037.22557.1.0 |
>> | dan | test.sip2sip.info | presence | a.1537527072.22698.1.0 |
>> | dan | test.sip2sip.info | presence | a.1537527127.22835.2.0 |
>> +----------+-------------------+----------+------------------------+
>> 9 rows in set (0.00 sec)
>>
>>
>> I also checked an older opensips-1.11 server and there I only have 1 record per AOR and I never see such errors in syslog:
>>
>> mysql> select username, domain, event, etag from presentity where username = 'dan';
>> +----------+-----------------+----------+--------------------------------+
>> | username | domain | event | etag |
>> +----------+-----------------+----------+--------------------------------+
>> | dan | ag-projects.com | presence | a.1530701145.32175.100449.152 |
>> | dan | sip2sip.info | presence | a.1530701145.32185.100643.3251 |
>> +----------+-----------------+----------+--------------------------------+
>> 2 rows in set (0.00 sec)
>>
>>
>> I use the same SIP client in both cases, but I only see the errors on the latest opensips from master. These errors happen every time I publish presence for that account.
>>
>> In addition I noticed other presence related errors in syslog, which might or might not be related to this:
>>
>> Sep 21 13:02:08 node03 /usr/sbin/opensips[22889]: ERROR:presence:delete_phtable_query: Record not found [a.1537526997.22186.2.0]
>> Sep 21 13:02:08 node03 /usr/sbin/opensips[22889]: ERROR:presence:msg_presentity_clean: deleting from pres hash table
>> Sep 21 13:02:08 node03 /usr/sbin/opensips[22889]: ERROR:presence:delete_phtable_query: Record not found [a.1537527037.22557.1.0]
>> Sep 21 13:02:08 node03 /usr/sbin/opensips[22889]: ERROR:presence:msg_presentity_clean: deleting from pres hash table
>> Sep 21 13:02:08 node03 /usr/sbin/opensips[22889]: ERROR:presence:delete_phtable_query: Record not found [a.1537527072.22698.1.0]
>> Sep 21 13:02:08 node03 /usr/sbin/opensips[22889]: ERROR:presence:msg_presentity_clean: deleting from pres hash table
>>
>>
>> --
>> Dan
>>
>>
>>
>>
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
--
Dan
More information about the Users
mailing list