[Red5] Minimize CPU usage
walter at waltertak.com
Tue Aug 25 06:27:16 PDT 2009
Have a look at
The quick version (no SSL, but password protected so it's safe)
0. open the firewall on your server(s) so you can connect from your desktop
to port 9999 on your server
1. edit [conf/red5.properties] and make sure JMX is bound to a public
interface/nic/IP instead of 127.0.0.1 (e.g. jmx.rmi.host=0.0.0.0 or
2. change password in [conf/password.properties]
3. install java on your desktop
4. start jconsole (start -> run -> jconsole or from commandline)
5. pick 'new connections'
6. select 'remote process'
7. enter this as the connect string "
service:jmx:rmi://doesnotmatter:12345/jndi/rmi://your.ip:9999/red5 " (yes it
looks weird, change "your.ip" into your IP or hostname, change 9999 if you
changed the port JMX listens on) , leave "doesnotmatter" and "12345" there
since it isn't used
8. enter username 'red5user' and the new password
9. jconsole will show a lot of nice graphs after a few seconds.
Have fun profiling.
----- Original Message -----
From: "Dan Daemon" <dan.daemon at gmail.com>
To: <red5 at osflash.org>
Sent: Tuesday, 25 August 2009 14:42
Subject: Re: [Red5] Minimize CPU usage
> Java settings are:
> -Xrs -Xms2048M -Xmx2048M -Xmn1024M -Xss1024K -XX:PermSize=256M -
> XX:MaxPermSize=512M -XX:NewSize=768M -XX:SurvivorRatio=32 -
> XX:MinHeapFreeRatio=20 -XX:+AggressiveHeap -XX:-UseGCOverheadLimit -
> Dsun.rmi.dgc.client.gcInterval=990000 -
> Dsun.rmi.dgc.server.gcInterval=990000 -Djava.net.preferIPv4Stack=true -
> Xverify:none -
> I turned off GC utilization, -XX:-UseGCOverheadLimit
> The origin server Xenon with 4 cores, 6Gig RAM...
> Thank you for help.
> JConsole does not work for me by unknown reason. Still trying to
> On Aug 25, 2009, at 2:34 PM, Walter Tak wrote:
>> I'd connect with jconsole to your boxes and see if Java isn't busy with
>> the GC all the time. If so you might want to tune the memorysettings a
>> ----- Original Message ----- From: "Dan Daemon" <dan.daemon at gmail.com>
>> To: <red5 at osflash.org>
>> Sent: Tuesday, 25 August 2009 04:16
>> Subject: [Red5] Minimize CPU usage
>>> Hello guys,
>>> I have 1 origin server and 5 nodes and about 1100 concurrent
>>> RTMP connections with live audio/video streams in different
>>> Origin server CPU usage is about 50%.
>>> Is it possible to minimize CPU usage with Java or
>>> RED5 tweaks?
>>> Red5 mailing list
>>> Red5 at osflash.org
>> Red5 mailing list
>> Red5 at osflash.org
> Red5 mailing list
> Red5 at osflash.org
More information about the Red5