PDA

View Full Version : 6.0 high cpu for remote streams



Triode
2005-02-11, 16:11
Hi,

Remote streaming of non mp3 streams seems to result in high cpu on recent 6.0 versions - has something changed to the select
processing in this area?
Any quick tips for tracking this down?

(I am getting >90% instead of the normal 4% for slimserver when streaming as pcm)

Adrian

Dan Sully
2005-02-11, 16:18
* Triode shaped the electrons to say...

>Remote streaming of non mp3 streams seems to result in high cpu on recent
>6.0 versions - has something changed to the select processing in this area?
>Any quick tips for tracking this down?
>
>(I am getting >90% instead of the normal 4% for slimserver when streaming as pcm)

What svn revision are you using? I'm streaming groove salad right now, at about 7% cpu.

I just checked in some non-blocking code, which may take the cpu up just a bit, but not that much.

-D
--
<dmercer> Because that is what our industry does.
Churns out useless shit. Followed by inferior re-implementations of useless shit.

Triode
2005-02-11, 16:37
Dan,

I've just updated to get your non-blocking code but saw this before. High load occurs for wma and rtsp streams for which the helper
opens the remote stream, but it doesn't occur with local files.

I'll look at in more detail - its only a 500 MHz Pentium III, but is definately running hotter than before.

Adrian

----- Original Message -----
From: "Dan Sully" <dan (AT) slimdevices (DOT) com>
To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
Sent: Friday, February 11, 2005 11:18 PM
Subject: [Developers] Re: 6.0 high cpu for remote streams


>* Triode shaped the electrons to say...
>
>>Remote streaming of non mp3 streams seems to result in high cpu on recent 6.0 versions - has something changed to the select
>>processing in this area?
>>Any quick tips for tracking this down?
>>
>>(I am getting >90% instead of the normal 4% for slimserver when streaming as pcm)
>
> What svn revision are you using? I'm streaming groove salad right now, at about 7% cpu.
>
> I just checked in some non-blocking code, which may take the cpu up just a bit, but not that much.
>
> -D
> --
> <dmercer> Because that is what our industry does.
> Churns out useless shit. Followed by inferior re-implementations of useless shit.
>

Dan Sully
2005-02-11, 16:40
* Triode shaped the electrons to say...

>I've just updated to get your non-blocking code but saw this before. High
>load occurs for wma and rtsp streams for which the helper opens the remote
>stream, but it doesn't occur with local files.
>
>I'll look at in more detail - its only a 500 MHz Pentium III, but is
>definately running hotter than before.

Ok - thanks. a strace -p (or equiv) on the processes might help to find where they're spinning.

-D
--
<dr.pox> what're the units of the coefficient of agnosticity? I don't knows per hour?

Triode
2005-02-11, 17:03
Dan,

Not sure if it is related, but I get constant (one per second) of the following:
2005-02-11 23:49:38.9588 Request for MOODLOGIC_SONG_MIXABLE on file mms://pubint.wm.llnwd.net/pubint_wcbe

Is there any easy way to stop the above - its as if something extra needs caching?

As my machine is slow it does show high cpu during database activity (peaks close to 100% during track changes).

Don't see any clear spinning with strace -p, but need to look at in more detail.

Adrian
----- Original Message -----
From: "Dan Sully" <dan (AT) slimdevices (DOT) com>
To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
Sent: Friday, February 11, 2005 11:40 PM
Subject: [Developers] Re: Re: 6.0 high cpu for remote streams


>* Triode shaped the electrons to say...
>
>>I've just updated to get your non-blocking code but saw this before. High
>>load occurs for wma and rtsp streams for which the helper opens the remote
>>stream, but it doesn't occur with local files.
>>
>>I'll look at in more detail - its only a 500 MHz Pentium III, but is
>>definately running hotter than before.
>
> Ok - thanks. a strace -p (or equiv) on the processes might help to find where they're spinning.
>
> -D
> --
> <dr.pox> what're the units of the coefficient of agnosticity? I don't knows per hour?
>

Triode
2005-02-11, 17:43
Dan,

strace shows frequent activity re-reading the html directories (even if there is no web page open). This does't show up when
playing local files.

With --d_http enabled I get the following all the time during a remote stream:

2005-02-12 00:43:11.7162 No segment to send to 10.0.0.1, waiting for next request..
2005-02-12 00:43:11.7181 sendstreaming response begun...
2005-02-12 00:43:11.7202 Nothing to stream, let's wait for 0.05 seconds...
2005-02-12 00:43:11.7222 Got nothing for streaming data to 10.0.0.1
2005-02-12 00:43:11.8275 No more messages to send to 10.0.0.1
2005-02-12 00:43:11.8310 No segment to send to 10.0.0.1, waiting for next request..
2005-02-12 00:43:11.8329 sendstreaming response begun...
2005-02-12 00:43:11.8352 Nothing to stream, let's wait for 0.05 seconds...
2005-02-12 00:43:11.8371 Got nothing for streaming data to 10.0.0.1
2005-02-12 00:43:11.8419 reading request...
2005-02-12 00:43:11.8435 HTTP request: from 10.0.0.1 (HTTP::Daemon::ClientConn=GLOB(0x86e1bcc)) for GET HTTP/1.1
/xml/status.xml?player=22:a6:d2:7f:c8:21
2005-02-12 00:43:11.8463 HTTP parameter player = 22:a6:d2:7f:c8:21
2005-02-12 00:43:11.8479 Alternate skin xml requested
2005-02-12 00:43:11.8525 skin entry: Bagpuss
2005-02-12 00:43:11.8541 skin entry: Dark
2005-02-12 00:43:11.8557 skin entry: Default
2005-02-12 00:43:11.8573 skin entry: EN
2005-02-12 00:43:11.8589 skin entry: ExBrowse
2005-02-12 00:43:11.8605 skin entry: ExBrowse2
2005-02-12 00:43:11.8619 skin entry: Fishbone
2005-02-12 00:43:11.8634 skin entry: Gordon
2005-02-12 00:43:11.8650 skin entry: Handheld
2005-02-12 00:43:11.8666 skin entry: Moser
2005-02-12 00:43:11.8680 skin entry: NBMU
2005-02-12 00:43:11.8695 skin entry: Purple
2005-02-12 00:43:11.8711 skin entry: Ruttenberg
2005-02-12 00:43:11.8727 skin entry: SenseMaker
2005-02-12 00:43:11.8742 skin entry: Touch
2005-02-12 00:43:11.8759 skin entry: WebPad
2005-02-12 00:43:11.8774 skin entry: xml
2005-02-12 00:43:11.9810 skin entry: xmlTelCanto
2005-02-12 00:43:11.9855 processURL Clients: 10.0.0.1:2921
2005-02-12 00:43:11.9878 Generating response for (xml, text/xml) status.xml
2005-02-12 00:43:11.9892 generating from include.html
2005-02-12 00:43:12.0458 Request for MOODLOGIC_SONG_MIXABLE on file mms://pubint.wm.llnwd.net/pubint_wcbe
2005-02-12 00:43:12.0548 generating from pagebarheader.html
2005-02-12 00:43:12.2281 generating from status_list.html
2005-02-12 00:43:12.4467 generating from status_list.html
2005-02-12 00:43:12.6110 generating from playlist.html
2005-02-12 00:43:12.6164 generating from status.html
2005-02-12 00:43:12.6867 End request: keepAlive: [5] - waiting for next request on connection = keep-alive

Is this normal?

Adrian


----- Original Message -----
From: "Triode" <triode1 (AT) btinternet (DOT) com>
To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
Sent: Saturday, February 12, 2005 12:03 AM
Subject: Re: [Developers] Re: Re: 6.0 high cpu for remote streams


> Dan,
>
> Not sure if it is related, but I get constant (one per second) of the following:
> 2005-02-11 23:49:38.9588 Request for MOODLOGIC_SONG_MIXABLE on file mms://pubint.wm.llnwd.net/pubint_wcbe
>
> Is there any easy way to stop the above - its as if something extra needs caching?
>
> As my machine is slow it does show high cpu during database activity (peaks close to 100% during track changes).
> Don't see any clear spinning with strace -p, but need to look at in more detail.
>
> Adrian
> ----- Original Message -----
> From: "Dan Sully" <dan (AT) slimdevices (DOT) com>
> To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
> Sent: Friday, February 11, 2005 11:40 PM
> Subject: [Developers] Re: Re: 6.0 high cpu for remote streams
>
>
>>* Triode shaped the electrons to say...
>>
>>>I've just updated to get your non-blocking code but saw this before. High load occurs for wma and rtsp streams for which the
>>>helper opens the remote stream, but it doesn't occur with local files.
>>>
>>>I'll look at in more detail - its only a 500 MHz Pentium III, but is definately running hotter than before.
>>
>> Ok - thanks. a strace -p (or equiv) on the processes might help to find where they're spinning.
>>
>> -D
>> --
>> <dr.pox> what're the units of the coefficient of agnosticity? I don't knows per hour?
>>

Triode
2005-02-11, 17:53
I've reproduced this with ogg streams, just incase you have difficulty doing it with other formats assuming you are using linux.

Try the following stream: http://audio.ibiblio.org:8010/wcpe.ogg

Adrian
----- Original Message -----
From: "Triode" <triode1 (AT) btinternet (DOT) com>
To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
Sent: Saturday, February 12, 2005 12:43 AM
Subject: Re: [Developers] Re: Re: 6.0 high cpu for remote streams


> Dan,
>
> strace shows frequent activity re-reading the html directories (even if there is no web page open). This does't show up when
> playing local files.
>
> With --d_http enabled I get the following all the time during a remote stream:
>
> 2005-02-12 00:43:11.7162 No segment to send to 10.0.0.1, waiting for next request..
> 2005-02-12 00:43:11.7181 sendstreaming response begun...
> 2005-02-12 00:43:11.7202 Nothing to stream, let's wait for 0.05 seconds...
> 2005-02-12 00:43:11.7222 Got nothing for streaming data to 10.0.0.1
> 2005-02-12 00:43:11.8275 No more messages to send to 10.0.0.1
> 2005-02-12 00:43:11.8310 No segment to send to 10.0.0.1, waiting for next request..
> 2005-02-12 00:43:11.8329 sendstreaming response begun...
> 2005-02-12 00:43:11.8352 Nothing to stream, let's wait for 0.05 seconds...
> 2005-02-12 00:43:11.8371 Got nothing for streaming data to 10.0.0.1
> 2005-02-12 00:43:11.8419 reading request...
> 2005-02-12 00:43:11.8435 HTTP request: from 10.0.0.1 (HTTP::Daemon::ClientConn=GLOB(0x86e1bcc)) for GET HTTP/1.1
> /xml/status.xml?player=22:a6:d2:7f:c8:21
> 2005-02-12 00:43:11.8463 HTTP parameter player = 22:a6:d2:7f:c8:21
> 2005-02-12 00:43:11.8479 Alternate skin xml requested
> 2005-02-12 00:43:11.8525 skin entry: Bagpuss
> 2005-02-12 00:43:11.8541 skin entry: Dark
> 2005-02-12 00:43:11.8557 skin entry: Default
> 2005-02-12 00:43:11.8573 skin entry: EN
> 2005-02-12 00:43:11.8589 skin entry: ExBrowse
> 2005-02-12 00:43:11.8605 skin entry: ExBrowse2
> 2005-02-12 00:43:11.8619 skin entry: Fishbone
> 2005-02-12 00:43:11.8634 skin entry: Gordon
> 2005-02-12 00:43:11.8650 skin entry: Handheld
> 2005-02-12 00:43:11.8666 skin entry: Moser
> 2005-02-12 00:43:11.8680 skin entry: NBMU
> 2005-02-12 00:43:11.8695 skin entry: Purple
> 2005-02-12 00:43:11.8711 skin entry: Ruttenberg
> 2005-02-12 00:43:11.8727 skin entry: SenseMaker
> 2005-02-12 00:43:11.8742 skin entry: Touch
> 2005-02-12 00:43:11.8759 skin entry: WebPad
> 2005-02-12 00:43:11.8774 skin entry: xml
> 2005-02-12 00:43:11.9810 skin entry: xmlTelCanto
> 2005-02-12 00:43:11.9855 processURL Clients: 10.0.0.1:2921
> 2005-02-12 00:43:11.9878 Generating response for (xml, text/xml) status.xml
> 2005-02-12 00:43:11.9892 generating from include.html
> 2005-02-12 00:43:12.0458 Request for MOODLOGIC_SONG_MIXABLE on file mms://pubint.wm.llnwd.net/pubint_wcbe
> 2005-02-12 00:43:12.0548 generating from pagebarheader.html
> 2005-02-12 00:43:12.2281 generating from status_list.html
> 2005-02-12 00:43:12.4467 generating from status_list.html
> 2005-02-12 00:43:12.6110 generating from playlist.html
> 2005-02-12 00:43:12.6164 generating from status.html
> 2005-02-12 00:43:12.6867 End request: keepAlive: [5] - waiting for next request on connection = keep-alive
>
> Is this normal?
>
> Adrian
>
>
> ----- Original Message -----
> From: "Triode" <triode1 (AT) btinternet (DOT) com>
> To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
> Sent: Saturday, February 12, 2005 12:03 AM
> Subject: Re: [Developers] Re: Re: 6.0 high cpu for remote streams
>
>
>> Dan,
>>
>> Not sure if it is related, but I get constant (one per second) of the following:
>> 2005-02-11 23:49:38.9588 Request for MOODLOGIC_SONG_MIXABLE on file mms://pubint.wm.llnwd.net/pubint_wcbe
>>
>> Is there any easy way to stop the above - its as if something extra needs caching?
>>
>> As my machine is slow it does show high cpu during database activity (peaks close to 100% during track changes).
>> Don't see any clear spinning with strace -p, but need to look at in more detail.
>>
>> Adrian
>> ----- Original Message -----
>> From: "Dan Sully" <dan (AT) slimdevices (DOT) com>
>> To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
>> Sent: Friday, February 11, 2005 11:40 PM
>> Subject: [Developers] Re: Re: 6.0 high cpu for remote streams
>>
>>
>>>* Triode shaped the electrons to say...
>>>
>>>>I've just updated to get your non-blocking code but saw this before. High load occurs for wma and rtsp streams for which the
>>>>helper opens the remote stream, but it doesn't occur with local files.
>>>>
>>>>I'll look at in more detail - its only a 500 MHz Pentium III, but is definately running hotter than before.
>>>
>>> Ok - thanks. a strace -p (or equiv) on the processes might help to find where they're spinning.
>>>
>>> -D
>>> --
>>> <dr.pox> what're the units of the coefficient of agnosticity? I don't knows per hour?
>>>

Triode
2005-02-12, 17:52
OK - I've narrowed this down to using Softsqueeze only.

With a squeezebox client, all is fine. With Softsqueeze (1.16), repeated requests are made for:

2005-02-13 00:46:40.8240 Request Headers: [
GET /xml/html/slimserver_xml.dtd HTTP/1.1
Connection: keep-alive
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
Host: vig:9000
User-Agent: Java/1.5.0
Content-Type: application/x-www-form-urlencoded

This appears to result in the server doing lots of work, keeping the cpu load high.

If a local file is played via softsqueeze it makes one or two requests like the above and is then quiet for the duration of the
track. For streaming audio it makes repeated requests.
Is softsqueeze doing something wrong or is slimserver sending it the wrong info?

Adrian

----- Original Message -----
From: "Triode" <triode1 (AT) btinternet (DOT) com>
To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
Sent: Saturday, February 12, 2005 12:53 AM
Subject: Re: [Developers] Re: Re: 6.0 high cpu for remote streams


> I've reproduced this with ogg streams, just incase you have difficulty doing it with other formats assuming you are using linux.
>
> Try the following stream: http://audio.ibiblio.org:8010/wcpe.ogg
> Adrian
> ----- Original Message -----
> From: "Triode" <triode1 (AT) btinternet (DOT) com>
> To: "Slim Devices Developers" <developers (AT) lists (DOT) slimdevices.com>
> Sent: Saturday, February 12, 2005 12:43 AM
> Subject: Re: [Developers] Re: Re: 6.0 high cpu for remote streams
>
>
>> Dan,
>>
>> strace shows frequent activity re-reading the html directories (even if there is no web page open). This does't show up when
>> playing local files.
>>
>> With --d_http enabled I get the following all the time during a remote stream:
>>
>> 2005-02-12 00:43:11.7162 No segment to send to 10.0.0.1, waiting for next request..
>> 2005-02-12 00:43:11.7181 sendstreaming response begun...
>> 2005-02-12 00:43:11.7202 Nothing to stream, let's wait for 0.05 seconds...
>> 2005-02-12 00:43:11.7222 Got nothing for streaming data to 10.0.0.1
>> 2005-02-12 00:43:11.8275 No more messages to send to 10.0.0.1
>> 2005-02-12 00:43:11.8310 No segment to send to 10.0.0.1, waiting for next request..
>> 2005-02-12 00:43:11.8329 sendstreaming response begun...
>> 2005-02-12 00:43:11.8352 Nothing to stream, let's wait for 0.05 seconds...
>> 2005-02-12 00:43:11.8371 Got nothing for streaming data to 10.0.0.1
>> 2005-02-12 00:43:11.8419 reading request...
>> 2005-02-12 00:43:11.8435 HTTP request: from 10.0.0.1 (HTTP::Daemon::ClientConn=GLOB(0x86e1bcc)) for GET HTTP/1.1
>> /xml/status.xml?player=22:a6:d2:7f:c8:21
>> 2005-02-12 00:43:11.8463 HTTP parameter player = 22:a6:d2:7f:c8:21
>> 2005-02-12 00:43:11.8479 Alternate skin xml requested
>> 2005-02-12 00:43:11.8525 skin entry: Bagpuss
>> 2005-02-12 00:43:11.8541 skin entry: Dark
>> 2005-02-12 00:43:11.8557 skin entry: Default
>> 2005-02-12 00:43:11.8573 skin entry: EN
>> 2005-02-12 00:43:11.8589 skin entry: ExBrowse
>> 2005-02-12 00:43:11.8605 skin entry: ExBrowse2
>> 2005-02-12 00:43:11.8619 skin entry: Fishbone
>> 2005-02-12 00:43:11.8634 skin entry: Gordon
>> 2005-02-12 00:43:11.8650 skin entry: Handheld
>> 2005-02-12 00:43:11.8666 skin entry: Moser
>> 2005-02-12 00:43:11.8680 skin entry: NBMU
>> 2005-02-12 00:43:11.8695 skin entry: Purple
>> 2005-02-12 00:43:11.8711 skin entry: Ruttenberg
>> 2005-02-12 00:43:11.8727 skin entry: SenseMaker
>> 2005-02-12 00:43:11.8742 skin entry: Touch
>> 2005-02-12 00:43:11.8759 skin entry: WebPad
>> 2005-02-12 00:43:11.8774 skin entry: xml
>> 2005-02-12 00:43:11.9810 skin entry: xmlTelCanto
>> 2005-02-12 00:43:11.9855 processURL Clients: 10.0.0.1:2921
>> 2005-02-12 00:43:11.9878 Generating response for (xml, text/xml) status.xml
>> 2005-02-12 00:43:11.9892 generating from include.html
>> 2005-02-12 00:43:12.0458 Request for MOODLOGIC_SONG_MIXABLE on file mms://pubint.wm.llnwd.net/pubint_wcbe
>> 2005-02-12 00:43:12.0548 generating from pagebarheader.html
>> 2005-02-12 00:43:12.2281 generating from status_list.html
>> 2005-02-12 00:43:12.4467 generating from status_list.html
>> 2005-02-12 00:43:12.6110 generating from playlist.html
>> 2005-02-12 00:43:12.6164 generating from status.html
>> 2005-02-12 00:43:12.6867 End request: keepAlive: [5] - waiting for next request on connection = keep-alive
>>
>> Is this normal?
>>
>> Adrian