Hello,
it might be due to dialog timeout checking. Do you get many calls
terminated via dialog BYEs? You have some log messages that are printed
for each BYE, that could be slowing the processing -- are these messages
printed by that pid?
Cheers,
Daniel
On 9/26/12 3:12 PM, Ricardo Martinez wrote:
Hi Daniel.
This is the output for TOP
top - 09:08:50 up 16:19, 3 users, load average: 0.23, 0.12, 0.06
Tasks: 160 total, 1 running, 159 sleeping, 0 stopped, 0 zombie
Cpu0 : 45.1%us, 1.0%sy, 0.0%ni, 53.9%id, 0.0%wa, 0.0%hi, 0.0%si,
0.0%st
Cpu1 : 8.9%us, 4.6%sy, 0.0%ni, 83.8%id, 0.0%wa, 0.7%hi, 2.0%si,
0.0%st
Cpu2 : 1.9%us, 1.9%sy, 0.0%ni, 96.1%id, 0.0%wa, 0.0%hi, 0.0%si,
0.0%st
Cpu3 : 1.3%us, 1.3%sy, 0.0%ni, 97.4%id, 0.0%wa, 0.0%hi, 0.0%si,
0.0%st
Mem: 3924912k total, 706492k used, 3218420k free, 59448k buffers
Swap: 6291448k total, 0k used, 6291448k free, 348716k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
*3804 root 20 0 1163m 25m 20m S 44.2 0.7 0:40.66 kamailio *
1103 root 20 0 249m 1704 968 S 5.9 0.0 5:27.39 rsyslogd
3789 root 20 0 1163m 26m 21m S 2.3 0.7 0:04.59 kamailio
3796 root 20 0 1163m 26m 21m S 2.3 0.7 0:04.38 kamailio
3802 root 20 0 1163m 26m 21m S 2.3 0.7 0:04.31 kamailio
3794 root 20 0 1163m 26m 21m S 2.0 0.7 0:04.45 kamailio
3803 root 20 0 1163m 26m 21m S 2.0 0.7 0:04.60 kamailio
3790 root 20 0 1163m 26m 21m S 1.6 0.7 0:04.48 kamailio
3792 root 20 0 1163m 26m 21m S 1.6 0.7 0:04.50 kamailio
3799 root 20 0 1163m 26m 21m S 1.6 0.7 0:04.68 kamailio
3649 root 20 0 15088 1232 900 R 1.3 0.0 0:07.83 top
3805 root 20 0 1163m 24m 20m S 0.3 0.6 0:00.61 kamailio
And this is the output for “kamctl ps”
[root@vLCR kamailio]# kamctl ps
Process:: ID=0 PID=3781 Type=attendant
Process:: ID=1 PID=3789 Type=udp receiver child=0
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
Process:: ID=2 PID=3790 Type=udp receiver child=1
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
Process:: ID=3 PID=3792 Type=udp receiver child=2
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
Process:: ID=4 PID=3794 Type=udp receiver child=3
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
Process:: ID=5 PID=3796 Type=udp receiver child=4
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
Process:: ID=6 PID=3799 Type=udp receiver child=5
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
Process:: ID=7 PID=3802 Type=udp receiver child=6
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
Process:: ID=8 PID=3803 Type=udp receiver child=7
sock=64.76.154.210:5060 <http://64.76.154.210:5060>
*Process:: ID=9 PID=3804 Type=slow timer*
Process:: ID=10 PID=3805 Type=timer
Process:: ID=11 PID=3807 Type=MI FIFO
Process:: ID=12 PID=3810 Type=TIMER RT
Process:: ID=13 PID=3811 Type=MI DATAGRAM
Process:: ID=14 PID=3812 Type=ctl handler
Seems that the “Slow timer” is taking too much CPU. Is this normal?.
I’m managing all the calls coming through the server with the dialog
module (dlg_manage ), as I mention I have a rate of 30cps and
sometimes I have 4500 active calls….
Could be some way to release some of the CPU use by this process?
Thanks again.
Regards,
Ricardo.-
*De:*Daniel-Constantin Mierla [mailto:miconda@gmail.com
<mailto:miconda@gmail.com>]
*Enviado el:* martes, 25 de septiembre de 2012 19:21
*Para:* SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
Users Mailing List
*CC:* Ricardo Martinez
*Asunto:* Re: [SR-Users] Question about CPU
Hello,
what is the type of the process? Run 'kamctl ps' and see the
description for that pid.
Cheers,
Daniel
On 9/25/12 11:49 PM, Ricardo Martinez wrote:
Hello.
Is normal this output from the “top” command?!
I have a kamailio with 16 children receiving calls at rate of
30cps and using the dialog module to timeout the calls :
This is the top command :
Tasks: 168 total, 2 running, 166 sleeping, 0 stopped, 0 zombie
Cpu0 : 56.0%us, 0.7%sy, 0.0%ni, 43.4%id, 0.0%wa, 0.0%hi,
0.0%si, 0.0%st
Cpu1 : 6.3%us, 3.0%sy, 0.0%ni, 87.8%id, 0.0%wa, 0.7%hi,
2.3%si, 0.0%st
Cpu2 : 0.3%us, 0.3%sy, 0.0%ni, 99.3%id, 0.0%wa, 0.0%hi,
0.0%si, 0.0%st
Cpu3 : 0.7%us, 0.3%sy, 0.0%ni, 99.0%id, 0.0%wa, 0.0%hi,
0.0%si, 0.0%st
Mem: 3924912k total, 535700k used, 3389212k free, 20236k
buffers
Swap: 6291448k total, 0k used, 6291448k free, 226120k
cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
*2566 root 20 0 1163m 27m 23m R 56.2 0.7 2:08.32 kamailio *
1103 root 20 0 249m 1656 924 S 2.7 0.0 1:32.89 rsyslogd
2525 root 20 0 1163m 27m 23m S 0.7 0.7 0:02.93 kamailio
2527 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.11 kamailio
2528 root 20 0 1163m 27m 23m S 0.7 0.7 0:02.89 kamailio
2529 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.13 kamailio
2535 root 20 0 1163m 27m 23m S 0.7 0.7 0:02.86 kamailio
2537 root 20 0 1163m 27m 23m S 0.7 0.7 0:02.85 kamailio
2538 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.17 kamailio
2541 root 20 0 1163m 27m 23m S 0.7 0.7 0:02.91 kamailio
2542 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.07 kamailio
2543 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.12 kamailio
2544 root 20 0 1163m 27m 23m S 0.7 0.7 0:02.64 kamailio
2549 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.10 kamailio
2551 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.14 kamailio
2552 root 20 0 1163m 27m 23m S 0.7 0.7 0:03.00 kamailio
2495 root 20 0 15088 1240 900 R 0.3 0.0 0:04.10 top
2526 root 20 0 1163m 27m 23m S 0.3 0.7 0:02.83 kamailio
2532 root 20 0 1163m 27m 23m S 0.3 0.7 0:02.87 kamailio
1 root 20 0 19396 1500 1192 S 0.0 0.0 0:02.86 init
2 root 20 0 0 0 0 S 0.0 0.0 0:00.01 kthreadd
3 root RT 0 0 0 0 S 0.0 0.0 0:00.00
migration/0
4 root 20 0 0 0 0 S 0.0 0.0 0:00.00
ksoftirqd/0
5 root RT 0 0 0 0 S 0.0 0.0 0:00.00
migration/0
6 root RT 0 0 0 0 S 0.0 0.0 0:00.00
watchdog/0
The question is : I always see the process PID : 2566 using more
CPU than the rest of the childrens.
Is this normal?
Regards,
Ricardo Martinez-.
_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users(a)lists.sip-router.org <mailto:sr-users@lists.sip-router.org>
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
--
Daniel-Constantin Mierla -http://www.asipto.com
http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda>
-http://www.linkedin.com/in/miconda
Kamailio Advanced Training, Berlin, Nov 5-8, 2012 -http://asipto.com/u/kat
Kamailio Advanced Training, Miami, USA, Nov 12-14, 2012 -http://asipto.com/u/katu