FS (r16858) consumes 4-5% of CPU time with spikes to 10% when idle. No single SIP request hits it. What does it doing? I unloaded all modules which can be unloaded, no difference. Tried with both -vm and -heavy-timer start up options. I'm running gentoo linux. # uname -a Linux 2.6.28-tuxonice-r10 #1 SMP Sat Oct 17 08:58:15 EDT 2009 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz GenuineIntel GNU/Linux
ps -LlFm -p `pidof freeswitch` That shows you CPU usage per FreeSWITCH thread Then pstack `pidof freeswitch` That shows the stack trace of every FreeSWITCH thread and then you can find exactly what is doing. -- Moises Silva Senior Software Engineer Sangoma Technologies Inc. | 50 McIntosh Drive, Suite 120, Markham ON L3R 9T3 Canada t. 1 905 474 1990 x 128 | e. moy@sangoma.com On Tue, Mar 2, 2010 at 11:13 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org>wrote:
FS (r16858) consumes 4-5% of CPU time with spikes to 10% when idle. No single SIP request hits it. What does it doing? I unloaded all modules which can be unloaded, no difference. Tried with both -vm and -heavy-timer start up options. I'm running gentoo linux.
# uname -a Linux 2.6.28-tuxonice-r10 #1 SMP Sat Oct 17 08:58:15 EDT 2009 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz GenuineIntel GNU/Linux
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
FS spends half of CPU here (main thread): #0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? () The second half is spent here: #0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1 On Tuesday 02 March 2010, Moises Silva wrote:
ps -LlFm -p `pidof freeswitch`
That shows you CPU usage per FreeSWITCH thread
Then
pstack `pidof freeswitch`
That shows the stack trace of every FreeSWITCH thread and then you can find exactly what is doing.
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for the centralized core timer. It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one. FreeSWITCH is FREE so give it a good home. The good news is, you can make upwards of 1500 calls on that same 2% of cpu usage. On Tue, Mar 2, 2010 at 11:51 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org>wrote:
FS spends half of CPU here (main thread):
#0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? ()
The second half is spent here:
#0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1
On Tuesday 02 March 2010, Moises Silva wrote:
ps -LlFm -p `pidof freeswitch`
That shows you CPU usage per FreeSWITCH thread
Then
pstack `pidof freeswitch`
That shows the stack trace of every FreeSWITCH thread and then you can find exactly what is doing.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire AIM: anthm MSN:anthony_minessale@hotmail.com <MSN%3Aanthony_minessale@hotmail.com> GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<PAYPAL%3Aanthony.minessale@gmail.com> IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org <sip%3A888@conference.freeswitch.org> iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org<googletalk%3Aconf%2B888@conference.freeswitch.org> pstn:+19193869900
I see the same problem on 4 absolutely different boxes with different linux kernels. On Tuesday 02 March 2010, Anthony Minessale wrote:
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for the centralized core timer.
It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one.
FreeSWITCH is FREE so give it a good home.
The good news is, you can make upwards of 1500 calls on that same 2% of cpu usage.
On Tue, Mar 2, 2010 at 11:51 AM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org>wrote:
FS spends half of CPU here (main thread):
#0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? ()
The second half is spent here:
#0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1
On Tuesday 02 March 2010, Moises Silva wrote:
ps -LlFm -p `pidof freeswitch`
That shows you CPU usage per FreeSWITCH thread
Then
pstack `pidof freeswitch`
That shows the stack trace of every FreeSWITCH thread and then you can
find
exactly what is doing.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Sergey, that's not a problem, is how FS works. That load on the CPU when idle is actually not important. Is just the minimum, like in a carburettor. If you put it under load, you will see that there will need some serious load (many calls) to have it ramp up the cpu usage. -giovanni On Tue, Mar 2, 2010 at 7:16 PM, Sergey Okhapkin <sos@sokhapkin.dyndns.org> wrote:
I see the same problem on 4 absolutely different boxes with different linux kernels.
On Tuesday 02 March 2010, Anthony Minessale wrote:
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for the centralized core timer.
It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one.
FreeSWITCH is FREE so give it a good home.
The good news is, you can make upwards of 1500 calls on that same 2% of cpu usage.
On Tue, Mar 2, 2010 at 11:51 AM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org>wrote:
FS spends half of CPU here (main thread):
#0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? ()
The second half is spent here:
#0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1
On Tuesday 02 March 2010, Moises Silva wrote:
ps -LlFm -p `pidof freeswitch`
That shows you CPU usage per FreeSWITCH thread
Then
pstack `pidof freeswitch`
That shows the stack trace of every FreeSWITCH thread and then you can
find
exactly what is doing.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Sincerely, Giovanni Maruzzelli Cell : +39-347-2665618
I guess if you insist, you have 4 bad boxes with 4 bad kernels, and I bet none of them are Centos 5.3 if you can reproduce it on a box I can visit (Centos 5.3 would be nice), put in my ssh key and i'll come and look. Be sure to remember, as you continue to add to this thread that you are complaining about FS using 2% of your cpu...... That's somewhat amusing to me. On Tue, Mar 2, 2010 at 12:23 PM, Giovanni Maruzzelli <gmaruzz@celliax.org>wrote:
Sergey,
that's not a problem, is how FS works.
That load on the CPU when idle is actually not important. Is just the minimum, like in a carburettor.
If you put it under load, you will see that there will need some serious load (many calls) to have it ramp up the cpu usage.
-giovanni
On Tue, Mar 2, 2010 at 7:16 PM, Sergey Okhapkin <sos@sokhapkin.dyndns.org> wrote:
I see the same problem on 4 absolutely different boxes with different linux kernels.
On Tuesday 02 March 2010, Anthony Minessale wrote:
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for the centralized core timer.
It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one.
FreeSWITCH is FREE so give it a good home.
The good news is, you can make upwards of 1500 calls on that same 2% of cpu usage.
On Tue, Mar 2, 2010 at 11:51 AM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org>wrote:
FS spends half of CPU here (main thread):
#0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? ()
The second half is spent here:
#0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1
On Tuesday 02 March 2010, Moises Silva wrote:
ps -LlFm -p `pidof freeswitch`
That shows you CPU usage per FreeSWITCH thread
Then
pstack `pidof freeswitch`
That shows the stack trace of every FreeSWITCH thread and then you can
find
exactly what is doing.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE: http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Sincerely,
Giovanni Maruzzelli Cell : +39-347-2665618
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire AIM: anthm MSN:anthony_minessale@hotmail.com <MSN%3Aanthony_minessale@hotmail.com> GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<PAYPAL%3Aanthony.minessale@gmail.com> IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org <sip%3A888@conference.freeswitch.org> iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org<googletalk%3Aconf%2B888@conference.freeswitch.org> pstn:+19193869900
On Tue, Mar 02, 2010 at 12:43:13PM -0600, Anthony Minessale wrote:
I guess if you insist, you have 4 bad boxes with 4 bad kernels, and I bet none of them are Centos 5.3 if you can reproduce it on a box I can visit (Centos 5.3 would be nice), put in my ssh key and i'll come and look.
Be sure to remember, as you continue to add to this thread that you are complaining about FS using 2% of your cpu...... That's somewhat amusing to me.
I can confirm this, I just checked 2 of my machines which run identical hardware and the Ubuntu one has FS sitting about 7% cpu all the time and the CentOS box has it sitting at 0% (I can't even see it on the screen). Both machines are idle. So the moral of the story is that the OS/hardware recommendations are made for good reason. Disregard them at your own risk. Andrew
A program should not be visible in "top" when idle. That's my point. On Tuesday 02 March 2010, Anthony Minessale wrote:
I guess if you insist, you have 4 bad boxes with 4 bad kernels, and I bet none of them are Centos 5.3 if you can reproduce it on a box I can visit (Centos 5.3 would be nice), put in my ssh key and i'll come and look.
Be sure to remember, as you continue to add to this thread that you are complaining about FS using 2% of your cpu...... That's somewhat amusing to me.
On Tue, Mar 2, 2010 at 12:23 PM, Giovanni Maruzzelli <gmaruzz@celliax.org>wrote:
Sergey,
that's not a problem, is how FS works.
That load on the CPU when idle is actually not important. Is just the minimum, like in a carburettor.
If you put it under load, you will see that there will need some serious load (many calls) to have it ramp up the cpu usage.
-giovanni
On Tue, Mar 2, 2010 at 7:16 PM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org> wrote:
I see the same problem on 4 absolutely different boxes with different
linux
kernels.
On Tuesday 02 March 2010, Anthony Minessale wrote:
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for
the
centralized core timer.
It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one.
FreeSWITCH is FREE so give it a good home.
The good news is, you can make upwards of 1500 calls on that same 2% of
cpu
usage.
On Tue, Mar 2, 2010 at 11:51 AM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org>wrote:
FS spends half of CPU here (main thread):
#0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? ()
The second half is spent here:
#0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1
On Tuesday 02 March 2010, Moises Silva wrote:
ps -LlFm -p `pidof freeswitch`
That shows you CPU usage per FreeSWITCH thread
Then
pstack `pidof freeswitch`
That shows the stack trace of every FreeSWITCH thread and then you
can
find
exactly what is doing.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:
http://lists.freeswitch.org/mailman/options/freeswitch-users
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-user s http://www.freeswitch.org
-- Sincerely,
Giovanni Maruzzelli Cell : +39-347-2665618
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
FS is not really idle when idle. Calls are not the only thing that cost cpu. Its a server daemon. It has at least 25 threads up including the central timer thread which is doing an endless-loop of 1ms sleeps. You have an active sip engine that still runs in a loop and many other moving parts. On Tue, Mar 2, 2010 at 12:53 PM, Sergey Okhapkin <sos@sokhapkin.dyndns.org>wrote:
A program should not be visible in "top" when idle. That's my point.
On Tuesday 02 March 2010, Anthony Minessale wrote:
I guess if you insist, you have 4 bad boxes with 4 bad kernels, and I bet none of them are Centos 5.3 if you can reproduce it on a box I can visit (Centos 5.3 would be nice), put in my ssh key and i'll come and look.
Be sure to remember, as you continue to add to this thread that you are complaining about FS using 2% of your cpu...... That's somewhat amusing to me.
On Tue, Mar 2, 2010 at 12:23 PM, Giovanni Maruzzelli <gmaruzz@celliax.org>wrote:
Sergey,
that's not a problem, is how FS works.
That load on the CPU when idle is actually not important. Is just the minimum, like in a carburettor.
If you put it under load, you will see that there will need some serious load (many calls) to have it ramp up the cpu usage.
-giovanni
On Tue, Mar 2, 2010 at 7:16 PM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org> wrote:
I see the same problem on 4 absolutely different boxes with different
linux
kernels.
On Tuesday 02 March 2010, Anthony Minessale wrote:
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for
the
centralized core timer.
It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one.
FreeSWITCH is FREE so give it a good home.
The good news is, you can make upwards of 1500 calls on that same 2% of
cpu
usage.
On Tue, Mar 2, 2010 at 11:51 AM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org>wrote:
FS spends half of CPU here (main thread):
#0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? ()
The second half is spent here:
#0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1
On Tuesday 02 March 2010, Moises Silva wrote: > ps -LlFm -p `pidof freeswitch` > > That shows you CPU usage per FreeSWITCH thread > > Then > > pstack `pidof freeswitch` > > That shows the stack trace of every FreeSWITCH thread and then you
can
find
> exactly what is doing.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:
http://lists.freeswitch.org/mailman/options/freeswitch-users
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE: http://lists.freeswitch.org/mailman/options/freeswitch-user s http://www.freeswitch.org
-- Sincerely,
Giovanni Maruzzelli Cell : +39-347-2665618
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE: http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire AIM: anthm MSN:anthony_minessale@hotmail.com <MSN%3Aanthony_minessale@hotmail.com> GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<PAYPAL%3Aanthony.minessale@gmail.com> IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org <sip%3A888@conference.freeswitch.org> iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org<googletalk%3Aconf%2B888@conference.freeswitch.org> pstn:+19193869900
----- Original Message ----- From: "Sergey Okhapkin" <sos@sokhapkin.dyndns.org> To: <freeswitch-users@lists.freeswitch.org> Sent: Tuesday, March 02, 2010 1:53 PM Subject: Re: [Freeswitch-users] What FS is doing when idle?
A program should not be visible in "top" when idle. That's my point.
On Tuesday 02 March 2010, Anthony Minessale wrote:
I guess if you insist, you have 4 bad boxes with 4 bad kernels, and I bet none of them are Centos 5.3 if you can reproduce it on a box I can visit (Centos 5.3 would be nice), put in my ssh key and i'll come and look.
Be sure to remember, as you continue to add to this thread that you are complaining about FS using 2% of your cpu...... That's somewhat amusing to me.
On Tue, Mar 2, 2010 at 12:23 PM, Giovanni Maruzzelli <gmaruzz@celliax.org>wrote:
Sergey,
that's not a problem, is how FS works.
That load on the CPU when idle is actually not important. Is just the minimum, like in a carburettor.
If you put it under load, you will see that there will need some serious load (many calls) to have it ramp up the cpu usage.
-giovanni
On Tue, Mar 2, 2010 at 7:16 PM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org> wrote:
I see the same problem on 4 absolutely different boxes with different
linux
kernels.
On Tuesday 02 March 2010, Anthony Minessale wrote:
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for
the
centralized core timer.
It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one.
FreeSWITCH is FREE so give it a good home.
The good news is, you can make upwards of 1500 calls on that same 2% of
cpu
usage.
On Tue, Mar 2, 2010 at 11:51 AM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org>wrote:
FS spends half of CPU here (main thread):
#0 0xffffe424 in __kernel_vsyscall () #1 0xb7a82781 in select () from /lib/libc.so.6 #2 0xb7e392eb in apr_sleep () from /opt/freeswitch/lib/libfreeswitch.so.1 #3 0x00000000 in ?? ()
The second half is spent here:
#0 0xb7d50946 in clock_nanosleep () from /lib/librt.so.1 #1 0xb7e0fa7d in softtimer_runtime () at src/switch_time.c:155 #2 0xb7dc585a in switch_loadable_module_exec (thread=0xb7101fb8, obj=0xb7101da8) at src/switch_loadable_module.c:96 #3 0xb7e379a8 in dummy_worker () from /opt/freeswitch/lib/libfreeswitch.so.1
On Tuesday 02 March 2010, Moises Silva wrote: > ps -LlFm -p `pidof freeswitch` > > That shows you CPU usage per FreeSWITCH thread > > Then > > pstack `pidof freeswitch` > > That shows the stack trace of every FreeSWITCH thread and then > you
can
find
> exactly what is doing.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:
http://lists.freeswitch.org/mailman/options/freeswitch-users
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-user s http://www.freeswitch.org
-- Sincerely,
Giovanni Maruzzelli Cell : +39-347-2665618
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
I follow this thread, and did top on my Linux Fedora 10 64bits and freeswitch last svn version (without mod_vmd that not compiles anymore) in idle mode and I get 10399 root 20 0 438m 37m 8744 S 11.3 0.5 15:31.61 freeswitch if I remember the previous version took less resources Regards F
On Tue, Mar 2, 2010 at 10:53 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org>wrote:
A program should not be visible in "top" when idle. That's my point.
That's a dangerous assumption. Do really know for a certainty that a program "should not" be visible in top when it's "idle"? Like Tony said below, "idle" is misleading. FreeSWITCH is working its but off when you think it's "idle." Make 100 simultaneous calls and see what the CPU usage is. I think you'll be happy with the results. For the record, we are going to start a wiki page that explains all of this. It's kind of analogous to the whole "Linux eats all my RAM" discussion. We should have something documented in a few days. -MC
Also add "Why is my load average so high with FreeSWITCH?" to that list of things we need to explain. Because load average is just a metric of how many threads are in the run queue.. its really no way to tell how busy a box really is since most threads have narcolepsy. /b On Mar 2, 2010, at 2:44 PM, Michael Collins wrote:
For the record, we are going to start a wiki page that explains all of this. It's kind of analogous to the whole "Linux eats all my RAM" discussion. We should have something documented in a few days. -MC
Since this topic is philosophical to begin with, "What does a FS box do when idle, and if a tree fell in the woods while a FS box was in a nearby cabin would a bear shit in the woods....." Another philosophical question would be, If a mailing-list thread persisted for more than 6 hours would it take more or less time to just change the code to make people stop complaining about free software than it does to politely not concern one's self with the issue. I chose the first option, you can update to trunk now and probably see your precious 0.0% so you can get absolutely no use from your computer. As a side note, my change effectively proves that the performance of pthread's mutexing and conditional broadcast implementation has gone downhill since the version on CentOS. On Tue, Mar 2, 2010 at 2:44 PM, Michael Collins <msc@freeswitch.org> wrote:
On Tue, Mar 2, 2010 at 10:53 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org
wrote:
A program should not be visible in "top" when idle. That's my point.
That's a dangerous assumption. Do really know for a certainty that a program "should not" be visible in top when it's "idle"? Like Tony said below, "idle" is misleading. FreeSWITCH is working its but off when you think it's "idle." Make 100 simultaneous calls and see what the CPU usage is. I think you'll be happy with the results.
For the record, we are going to start a wiki page that explains all of this. It's kind of analogous to the whole "Linux eats all my RAM" discussion. We should have something documented in a few days. -MC
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire AIM: anthm MSN:anthony_minessale@hotmail.com <MSN%3Aanthony_minessale@hotmail.com> GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<PAYPAL%3Aanthony.minessale@gmail.com> IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org <sip%3A888@conference.freeswitch.org> iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org<googletalk%3Aconf%2B888@conference.freeswitch.org> pstn:+19193869900
On 03/02/2010 02:44 PM, Michael Collins wrote:
On Tue, Mar 2, 2010 at 10:53 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org <mailto:sos@sokhapkin.dyndns.org>> wrote:
A program should not be visible in "top" when idle. That's my point.
That's a dangerous assumption. Do really know for a certainty that a program "should not" be visible in top when it's "idle"? Like Tony said below, "idle" is misleading. FreeSWITCH is working its but off when you think it's "idle." Make 100 simultaneous calls and see what the CPU usage is. I think you'll be happy with the results.
<snip snip> Cue up applicable car analogy.... I ask Sergey this question: When you turn on your car and let it while in either a parking gear or in neutral, your car is considered "idling". But does the car still not use oxygen and gasoline, and produce heat and waste products all the while idling? That is how you can think of a complex system such as FreeSWITCH. It is a machine with a lot of parts, and idling means that it is in a "ready" state, but does not mean that it is "turned off". -Yossi
It's sad that my computer uses more than 2% CPU whenever I try to open this thread in my email client... -MC On Tue, Mar 2, 2010 at 1:27 PM, Yossi Neiman <freeswitch@cartissolutions.com
wrote:
On 03/02/2010 02:44 PM, Michael Collins wrote:
On Tue, Mar 2, 2010 at 10:53 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org
wrote:
A program should not be visible in "top" when idle. That's my point.
That's a dangerous assumption. Do really know for a certainty that a program "should not" be visible in top when it's "idle"? Like Tony said below, "idle" is misleading. FreeSWITCH is working its but off when you think it's "idle." Make 100 simultaneous calls and see what the CPU usage is. I think you'll be happy with the results.
<snip snip>
Cue up applicable car analogy....
I ask Sergey this question: When you turn on your car and let it while in either a parking gear or in neutral, your car is considered "idling". But does the car still not use oxygen and gasoline, and produce heat and waste products all the while idling? That is how you can think of a complex system such as FreeSWITCH. It is a machine with a lot of parts, and idling means that it is in a "ready" state, but does not mean that it is "turned off".
-Yossi
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
On 03/02/2010 12:16 PM, Sergey Okhapkin wrote:
I see the same problem on 4 absolutely different boxes with different linux kernels.
And why do you think this is a problem anyway? If you want 0% cpu utilization, you can always power off the machine. :-)
On Tuesday 02 March 2010, Anthony Minessale wrote:
Well, there you go. your box is having a hard time doing a simple 1ms sleep in a loop for the centralized core timer.
It's either your kernel or your box. My box and every box I have do not have that problem so you may want to consider a new one.
FreeSWITCH is FREE so give it a good home.
The good news is, you can make upwards of 1500 calls on that same 2% of cpu usage.
<snip snip>
If you don't like that CPU usage, use a different kernel or disable the broken "tickles" features. you can't use both -vm and -heavy-timer because -heavy-timer replaces -vm permanently. On Tue, Mar 2, 2010 at 10:13 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org>wrote:
FS (r16858) consumes 4-5% of CPU time with spikes to 10% when idle. No single SIP request hits it. What does it doing? I unloaded all modules which can be unloaded, no difference. Tried with both -vm and -heavy-timer start up options. I'm running gentoo linux.
# uname -a Linux 2.6.28-tuxonice-r10 #1 SMP Sat Oct 17 08:58:15 EDT 2009 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz GenuineIntel GNU/Linux
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire AIM: anthm MSN:anthony_minessale@hotmail.com <MSN%3Aanthony_minessale@hotmail.com> GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<PAYPAL%3Aanthony.minessale@gmail.com> IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org <sip%3A888@conference.freeswitch.org> iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org<googletalk%3Aconf%2B888@conference.freeswitch.org> pstn:+19193869900
Tickless feature is disabled in the kernel. $ zcat /proc/config.gz | grep CONFIG_NO_HZ # CONFIG_NO_HZ is not set On Tuesday 02 March 2010, Anthony Minessale wrote:
If you don't like that CPU usage, use a different kernel or disable the broken "tickles" features.
you can't use both -vm and -heavy-timer because -heavy-timer replaces -vm permanently.
On Tue, Mar 2, 2010 at 10:13 AM, Sergey Okhapkin
<sos@sokhapkin.dyndns.org>wrote:
FS (r16858) consumes 4-5% of CPU time with spikes to 10% when idle. No single SIP request hits it. What does it doing? I unloaded all modules which can be unloaded, no difference. Tried with both -vm and -heavy-timer start up options. I'm running gentoo linux.
# uname -a Linux 2.6.28-tuxonice-r10 #1 SMP Sat Oct 17 08:58:15 EDT 2009 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz GenuineIntel GNU/Linux
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
For whatever it's worth; I have FS running on a 1.6MHz processor, CentOS 5.3 (Final); when idle it consumes 0.3% of processor time. On Tue, Mar 2, 2010 at 10:13 AM, Sergey Okhapkin <sos@sokhapkin.dyndns.org> wrote:
FS (r16858) consumes 4-5% of CPU time with spikes to 10% when idle. No single SIP request hits it. What does it doing? I unloaded all modules which can be unloaded, no difference. Tried with both -vm and -heavy-timer start up options. I'm running gentoo linux.
# uname -a Linux 2.6.28-tuxonice-r10 #1 SMP Sat Oct 17 08:58:15 EDT 2009 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz GenuineIntel GNU/Linux
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
I guess he is thinking about 1.6GHZ, most likely the N270 CPU which is common to net books from ASUS and like, I have one running on EEE box N270. Chris On Tue, Mar 2, 2010 at 2:25 PM, Brian West <brian@freeswitch.org> wrote:
How many calls can that 1.6MHz CPU do? :P And how long does it take to compile?
:P
/b
On Mar 2, 2010, at 1:15 PM, Max Bridgewater wrote:
For whatever it's worth; I have FS running on a 1.6MHz processor, CentOS 5.3 (Final); when idle it consumes 0.3% of processor time.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
I tried to downgrade FS to version 16597, all compiles well (even mod_vmd) so with exactly the same config as last svn trunk I get with -vm : 21245 root 20 0 495m 29m 7428 S 2.3 0.4 0:00.71 freeswitch -> CPU = 2.3% and without -vm 25744 root 20 0 431m 29m 7432 S 4.0 0.4 0:01.46 freeswitch -> CPU 4.00% which is less as the last version that takes almost 12%. hope this helps Regards F ----- Original Message ----- From: Chris Chen To: freeswitch-users@lists.freeswitch.org Sent: Tuesday, March 02, 2010 3:08 PM Subject: Re: [Freeswitch-users] What FS is doing when idle? I guess he is thinking about 1.6GHZ, most likely the N270 CPU which is common to net books from ASUS and like, I have one running on EEE box N270. Chris On Tue, Mar 2, 2010 at 2:25 PM, Brian West <brian@freeswitch.org> wrote: How many calls can that 1.6MHz CPU do? :P And how long does it take to compile? :P /b On Mar 2, 2010, at 1:15 PM, Max Bridgewater wrote: > For whatever it's worth; I have FS running on a 1.6MHz processor, > CentOS 5.3 (Final); when idle it consumes 0.3% of processor time. _______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org ------------------------------------------------------------------------------ _______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
and make calls with both and measure the jitter with wireshark. On Tue, Mar 2, 2010 at 2:19 PM, Madovsky <infos@madovsky.org> wrote:
I tried to downgrade FS to version 16597, all compiles well (even mod_vmd) so with exactly the same config as last svn trunk I get with -vm :
21245 root 20 0 495m 29m 7428 S 2.3 0.4 0:00.71 freeswitch -> CPU = 2.3%
and without -vm 25744 root 20 0 431m 29m 7432 S 4.0 0.4 0:01.46 freeswitch -> CPU 4.00%
which is less as the last version that takes almost 12%.
hope this helps
Regards
F
----- Original Message ----- *From:* Chris Chen <chris.chen2004@gmail.com> *To:* freeswitch-users@lists.freeswitch.org *Sent:* Tuesday, March 02, 2010 3:08 PM *Subject:* Re: [Freeswitch-users] What FS is doing when idle?
I guess he is thinking about 1.6GHZ, most likely the N270 CPU which is common to net books from ASUS and like, I have one running on EEE box N270.
Chris
On Tue, Mar 2, 2010 at 2:25 PM, Brian West <brian@freeswitch.org> wrote:
How many calls can that 1.6MHz CPU do? :P And how long does it take to compile?
:P
/b
On Mar 2, 2010, at 1:15 PM, Max Bridgewater wrote:
For whatever it's worth; I have FS running on a 1.6MHz processor, CentOS 5.3 (Final); when idle it consumes 0.3% of processor time.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
------------------------------
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
-- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire AIM: anthm MSN:anthony_minessale@hotmail.com <MSN%3Aanthony_minessale@hotmail.com> GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com<PAYPAL%3Aanthony.minessale@gmail.com> IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org <sip%3A888@conference.freeswitch.org> iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org<googletalk%3Aconf%2B888@conference.freeswitch.org> pstn:+19193869900
Ok I will do it, but I can make only one call since I work alone on FS :D ----- Original Message ----- From: Anthony Minessale To: freeswitch-users@lists.freeswitch.org Sent: Tuesday, March 02, 2010 3:37 PM Subject: Re: [Freeswitch-users] What FS is doing when idle? and make calls with both and measure the jitter with wireshark. On Tue, Mar 2, 2010 at 2:19 PM, Madovsky <infos@madovsky.org> wrote: I tried to downgrade FS to version 16597, all compiles well (even mod_vmd) so with exactly the same config as last svn trunk I get with -vm : 21245 root 20 0 495m 29m 7428 S 2.3 0.4 0:00.71 freeswitch -> CPU = 2.3% and without -vm 25744 root 20 0 431m 29m 7432 S 4.0 0.4 0:01.46 freeswitch -> CPU 4.00% which is less as the last version that takes almost 12%. hope this helps Regards F ----- Original Message ----- From: Chris Chen To: freeswitch-users@lists.freeswitch.org Sent: Tuesday, March 02, 2010 3:08 PM Subject: Re: [Freeswitch-users] What FS is doing when idle? I guess he is thinking about 1.6GHZ, most likely the N270 CPU which is common to net books from ASUS and like, I have one running on EEE box N270. Chris On Tue, Mar 2, 2010 at 2:25 PM, Brian West <brian@freeswitch.org> wrote: How many calls can that 1.6MHz CPU do? :P And how long does it take to compile? :P /b On Mar 2, 2010, at 1:15 PM, Max Bridgewater wrote: > For whatever it's worth; I have FS running on a 1.6MHz processor, > CentOS 5.3 (Final); when idle it consumes 0.3% of processor time. _______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org -------------------------------------------------------------------------- _______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org _______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org -- Anthony Minessale II FreeSWITCH http://www.freeswitch.org/ ClueCon http://www.cluecon.com/ Twitter: http://twitter.com/FreeSWITCH_wire AIM: anthm MSN:anthony_minessale@hotmail.com GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com IRC: irc.freenode.net #freeswitch FreeSWITCH Developer Conference sip:888@conference.freeswitch.org iax:guest@conference.freeswitch.org/888 googletalk:conf+888@conference.freeswitch.org pstn:+19193869900 ------------------------------------------------------------------------------ _______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
Next time i compile I will let you know. But if I remember correctly, it takes some few hours. And as far as calls are concerned I don't intend to have more than 8 calls at a time. So the question is really irrelevant for my settings ;) Max. On Tue, Mar 2, 2010 at 1:25 PM, Brian West <brian@freeswitch.org> wrote:
How many calls can that 1.6MHz CPU do? :P And how long does it take to compile?
:P
/b
On Mar 2, 2010, at 1:15 PM, Max Bridgewater wrote:
For whatever it's worth; I have FS running on a 1.6MHz processor, CentOS 5.3 (Final); when idle it consumes 0.3% of processor time.
_______________________________________________ FreeSWITCH-users mailing list FreeSWITCH-users@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-users UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users http://www.freeswitch.org
participants (11)
-
Andrew Thompson
-
Anthony Minessale
-
Brian West
-
Chris Chen
-
Giovanni Maruzzelli
-
Madovsky
-
Max Bridgewater
-
Michael Collins
-
Moises Silva
-
Sergey Okhapkin
-
Yossi Neiman