Unfortunately I can't reproduce your memory leak reports. For example, here is the line about my production darkice instance from top: PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND 27516 root 20 0 3564 3564 1340 S 95.6 1.3 47:06 darkice <p>this as after approx 50 minutes from start, but the memory load doesn't change for the whole 4 hours it runs. What's even more strange, is that darkice does not allocate memory itself after initialization. I can only guess that the only place memory can leak is in the libraries darkice uses. Kristjan or Nicu, can you send me the exact libraries that you'r using? <p>Akos <p>--- >8 ---- List archives: http://www.xiph.org/archives/ icecast project homepage: http://www.icecast.org/ To unsubscribe from this list, send a message to 'icecast-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
Kristjan Gu?ni Bjarnason wrote:> I was looking more closely on the source for Darkice. I found the code for > calulating the buffersize somewhat strange. Your is snapshot taken from the > init function in CastSink.cpp : > > int bufferSize = bitRate ? (bitRate * 1024 / 8) * bufferDuration > : (128 * 1024 / 8) * bufferDuration; > bufferedSink = socket ? new BufferedSink( socket, > (bufferSize * 1024 / 8) * > bufferDuration) > : 0; > > In my case the bufferDuration is 10 and bitrate 128. Why is the do we > multiply by 'bufferSize*1024/8*bufferDuration twice? > The constructor for BufferedSink allocates the buffer with the 2nd param as > the buffersize. In my case the 'chunkSize' is 1 which gives bufferSize > 209.715.200 bytes. I am wrong? Is this healty?Not, not healthy :) This was a last minute change before I released 0.9. Appearantly you pinpointed the problem. I'll issue a 0.9.1 release shortly... Thanks for looking into the problem and pinpointing it. <p>Akos <p><p>--- >8 ---- List archives: http://www.xiph.org/archives/ icecast project homepage: http://www.icecast.org/ To unsubscribe from this list, send a message to 'icecast-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
I was looking more closely on the source for Darkice. I found the code for calulating the buffersize somewhat strange. Your is snapshot taken from the init function in CastSink.cpp : int bufferSize = bitRate ? (bitRate * 1024 / 8) * bufferDuration : (128 * 1024 / 8) * bufferDuration; bufferedSink = socket ? new BufferedSink( socket, (bufferSize * 1024 / 8) * bufferDuration) : 0; In my case the bufferDuration is 10 and bitrate 128. Why is the do we multiply by 'bufferSize*1024/8*bufferDuration twice? The constructor for BufferedSink allocates the buffer with the 2nd param as the buffersize. In my case the 'chunkSize' is 1 which gives bufferSize 209.715.200 bytes. I am wrong? Is this healty? Kristjan <p><p>-----Original Message----- From: owner-icecast@xiph.org [mailto:owner-icecast@xiph.org]On Behalf Of Akos Maroy Sent: 9. april 2002 06:54 To: icecast@xiph.org Subject: Re: [icecast] Darkice memory leak <p>Unfortunately I can't reproduce your memory leak reports. For example, here is the line about my production darkice instance from top: PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND 27516 root 20 0 3564 3564 1340 S 95.6 1.3 47:06 darkice <p>this as after approx 50 minutes from start, but the memory load doesn't change for the whole 4 hours it runs. What's even more strange, is that darkice does not allocate memory itself after initialization. I can only guess that the only place memory can leak is in the libraries darkice uses. Kristjan or Nicu, can you send me the exact libraries that you'r using? <p>Akos <p>--- >8 ---- List archives: http://www.xiph.org/archives/ icecast project homepage: http://www.icecast.org/ To unsubscribe from this list, send a message to 'icecast-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered. <p>--- >8 ---- List archives: http://www.xiph.org/archives/ icecast project homepage: http://www.icecast.org/ To unsubscribe from this list, send a message to 'icecast-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.