Increased java heap size not used?

For help and support with Universal Media Server
Forum rules
Please make sure you follow the Problem Reporting Guidelines before posting if you want a reply
Post Reply
Impee
Posts: 11
Joined: Fri Jan 18, 2013 7:23 am

Increased java heap size not used?

Post by Impee »

Hi,

First of all: thanks a lot for UMS. It works like a charm and i love it! Keep up the good work. :!:

For the sake of making UMS even better than it already is, i would like to report some (minor) bugs.

At installation time, i increased the java heap size to 2048. I also changed the transcode buffer size to 1280.

When i start UMS with UMS.exe, the typical out of memory errors appear soon when transcoding a movie. The same is true when i start UMS with the original UMS.bat.

However, when i change the -Xmx parameter in the original UMS.bat from -Xmx768M to -Xmx2048M, then everything works fine.

Hence, it seems that the override at installation time is not reflected in the exe or bat. Maybe this is a bug?

UMS reports 1452M as the maximum size for the transcoding buffer when using 2048M for the java heap. Using this value also results in memory issues (out of memory, buffer is flushed every 3 seconds). Lowering the value to 1280 solves the problem. The reported max value seems to be overestimated. Maybe this is a bug too?

Kind regards,
Impee
Regards,
Impee.
User avatar
SubJunk
Lead Developer
Posts: 3707
Joined: Sun May 27, 2012 4:12 pm

Re: Increased java heap size not used?

Post by SubJunk »

Hmm hopefully SharkHunter can chime in on this :)
User avatar
kuroukage
Posts: 283
Joined: Wed Dec 12, 2012 3:56 pm

Re: Increased java heap size not used?

Post by kuroukage »

I use 1536 as my setting and the buffer only reports a max of 1116. Is this a bug?
黒影
_______________________________________________|_._._._._._._._._._
\______________________________________________|_#_#_#_#_#_#_|
------------------------------------------------------------------|---------------------
User avatar
SubJunk
Lead Developer
Posts: 3707
Joined: Sun May 27, 2012 4:12 pm

Re: Increased java heap size not used?

Post by SubJunk »

What UMS reports is after some overhead is removed so it is normal for it to report less than the setting itself
User avatar
kuroukage
Posts: 283
Joined: Wed Dec 12, 2012 3:56 pm

Re: Increased java heap size not used?

Post by kuroukage »

Is that due to how many plugins you have loaded up? Or is it just determined by what UMS regularly loads at start (without any plugins)?
黒影
_______________________________________________|_._._._._._._._._._
\______________________________________________|_#_#_#_#_#_#_|
------------------------------------------------------------------|---------------------
User avatar
SubJunk
Lead Developer
Posts: 3707
Joined: Sun May 27, 2012 4:12 pm

Re: Increased java heap size not used?

Post by SubJunk »

I don't think it is affected significantly by plugins, they may add a few megabytes but nothing substantial I don't think.
User avatar
kuroukage
Posts: 283
Joined: Wed Dec 12, 2012 3:56 pm

Re: Increased java heap size not used?

Post by kuroukage »

Well if I take my setting for example: 1536MB and I subtract 400MB (max buffer value according to defaults) then that's 1136MB. If I subtract an additional 20MB for plugins it then equals 1116MB (which is what it says my max buffer currently is in UMS). So it looks to me like it's reserving theoretical max buffer + a little for plugins. Does that seem right? Is that the reason it ends up equaling that?
黒影
_______________________________________________|_._._._._._._._._._
\______________________________________________|_#_#_#_#_#_#_|
------------------------------------------------------------------|---------------------
ExSport
Posts: 595
Joined: Wed Oct 10, 2012 1:57 am

Re: Increased java heap size not used?

Post by ExSport »

If you are using web.conf, then also this allocate memory.
I remember from past, there was a script which imported 20'000 radios to WEB.conf and it took quite much from memory so I deleted them. 8-)
User avatar
kuroukage
Posts: 283
Joined: Wed Dec 12, 2012 3:56 pm

Re: Increased java heap size not used?

Post by kuroukage »

Yeah, my web.conf has quite a bit of entries, so I can see that using memory as well. I was just figuring it was mainly coming from the space it needs for buffering videos.
黒影
_______________________________________________|_._._._._._._._._._
\______________________________________________|_#_#_#_#_#_#_|
------------------------------------------------------------------|---------------------
Impee
Posts: 11
Joined: Fri Jan 18, 2013 7:23 am

Re: Increased java heap size not used?

Post by Impee »

Hi,

I want to come back on the original problem (memory override during install not taken into account - see top message).
This problem seems to be solved as from UMS 2.4.1 and above. No need anymore to use (change and) use the ums.bat file.

Thanks.
Impee
Regards,
Impee.
Post Reply