HI,

We are facing a hang issue with Kamailio for the get_profile_size method. Randomly, the Kamailio got hangs, and the CPU went 100%.
During the hanging time, we generated the TRAP and we could see that the hang happened on the get_profile_size method. We are getting this hang randomly in dlg_profile.c of the following lines:

The hang occurs, causing the CPU to spike to 100% at one of the following lines randomly:

1. if(value->len == ph->value.len && memcmp(value->s, ph->value.s, value->len) == 0) {
2. ph = ph->next;
3. while(ph != profile->entries[i].first);

During our analysis, we found that PROCESS ID 7608 gets a spike of 100% utilization.

We suspect there may be an issue with the processing of the 'ph' variable, but we couldn't identify the root cause. I've attached the Kamailio TRAP for further details. Could you please suggest what might be causing this problem and how we can resolve it?

Thank you.