[Icecast] high CPU load for large # sources?

Klaas Jan Wierenga k.j.wierenga at home.nl
Mon Mar 7 22:01:40 UTC 2005


Hi all,

I have an icecast setup with 20+ sources. During peak times some 20 sources
will be connected with a total of some 250 listeners more-or-less equally
divided over the 20 sources. All streams are running at a measly 16 kbps.
There is enough bandwidth to/from the server. During these peak times I see
very high CPU usage for icecast 98-99%. The system I'm running is an Intel
Celeron 2.4GHz running Fedora Linux 1. It does appear that the server is
happily serverving all clients, but what could cause the high CPU load?

Is every source (/mount) serviced by a different thread? How many threads
would I have then? My threadpool is set at 20. Could it be that the timeout
on poll/select of 250 in each thread causes Icecast to effectively busywait
since with 20 threads the actual time between the poll/select system calls
is reduced to ~10ms, the timeslice of Linux!

Here's the relevant part of my configuration file.

 <limits>
        <clients>2000</clients>
        <sources>100</sources>
        <threadpool>20</threadpool>
        <queue-size>512000</queue-size>
        <client-timeout>30</client-timeout>
        <header-timeout>30</header-timeout>
        <source-timeout>30</source-timeout>
        <burst-on-connect>1</burst-on-connect>
        <burst-size>20480</burst-size>
    </limits>


Has anyone else experienced high CPU load with Icecast?

Cheers,
KJ




More information about the Icecast mailing list