Go Back   Winamp Forums > SHOUTcast > SHOUTcast Technical Support

Reply
Thread Tools Search this Thread Display Modes
Old 5th November 2010, 12:57   #1
itibet
Junior Member
 
Join Date: Sep 2010
Posts: 4
Can SHOUTcast server cause memory leaks?

Hi,
I'm experiencing a big memory leak problem and I wonder if a bad SHOUTcast server configuration might be the cause.

I'm running several SHOUTcast server 1.9.8 instances on a Linux CentOS machine,
TOP command reports 6 GB of used RAM (since yesterday when I rebooted the machine) and it's increasing continously.
Something misterious to me (that I'm just a Linux newbie) is that TOP reports a total of 6GB used ram but very small percentage for single process (0-1%).

Can anybody suggest me a linux command/tool to help understand which processes are really consuming too much memory?

Thanks


TOP
----

Mem: 8153084k total, 6032020k used, 2121064k free, 183824k buffers
Swap: 1052464k total, 0k used, 1052464k free, 5458504k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
6122 root 40 0 1440m 80m 7792 S 3.3 1.0 28:50.52 java
5381 centovac 40 0 36060 2468 728 S 1.0 0.0 6:35.19 sc_serv
5413 centovac 40 0 36060 2332 732 S 0.7 0.0 5:59.46 sc_serv
5642 centovac 40 0 36060 3000 732 S 0.7 0.0 6:31.55 sc_serv
5894 centovac 40 0 34264 2176 728 S 0.7 0.0 5:50.66 sc_serv
10295 root 40 0 2332 1104 796 R 0.7 0.0 0:00.03 top
5439 centovac 40 0 36060 2336 732 S 0.3 0.0 5:56.06 sc_serv
5597 centovac 40 0 36060 2300 732 S 0.3 0.0 6:43.50 sc_serv
5850 centovac 40 0 35912 1852 560 S 0.3 0.0 5:35.55 sc_serv
5855 centovac 40 0 36060 2160 732 S 0.3 0.0 5:51.98 sc_serv
5864 centovac 40 0 36060 2160 728 S 0.3 0.0 5:50.68 sc_serv
5873 centovac 40 0 36060 2200 732 S 0.3 0.0 5:50.09 sc_serv
5885 centovac 40 0 36060 2160 732 S 0.3 0.0 5:54.70 sc_serv
20930 apache 40 0 42380 17m 5272 S 0.3 0.2 0:02.68 httpd
....
itibet is offline   Reply With Quote
Old 8th November 2010, 10:11   #2
bored_womble
Winamp's Womble
 
bored_womble's Avatar
 
Join Date: May 2004
Location: Wimbledon Common
Posts: 1,088
if you do top, when it is running do Shift+M, should sort the processes by memory usage.

You should be looking at the resident memory, rather than the virtual one, example

6122 root 40 0 1440m 80m 7792 S 3.3 1.0 28:50.52 java

this is the first process in your list, 80Meg is the number to be checking, NOT the 1440m, as it has requested this amount, but is not yet using it.

Looking at the process list you showed below it looks like multiple shoutcast servers running with 36meg each. Do make sure you configure Shoutcast correctly, ie. do not give them all 1000 slots unless you need them as it will burn memory when not needed.

Alternatively on the command line do

ps -eo pmem,pid,command

which should show the % of memory for each process and the command it is running.

BW

Without open minds the world will die. Open yours and correct the mistakes you are making right now.
bored_womble is offline   Reply With Quote
Old 8th November 2010, 13:09   #3
itibet
Junior Member
 
Join Date: Sep 2010
Posts: 4
Thanks, very useful.
I gave each SHOUTcast server instance 200 slots, do you think they shouldn't be using 36MB of virtual memory?
Anyway, as you said, they are actually consuming just 2/3MB of physical RAM, am i right?
itibet is offline   Reply With Quote
Reply
Go Back   Winamp Forums > SHOUTcast > SHOUTcast Technical Support

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump