JDownloader Community - Appwork GmbH
 

Reply
 
Thread Tools Display Modes
  #221  
Old 23.08.2015, 20:47
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

The screenshot link is broken. What is on it? Maybe new image?

When you allow 9GB Heap, then Java will take up to 9GB before first memory gc will happen.
__________________
JD-Dev & Server-Admin
Reply With Quote
  #222  
Old 23.08.2015, 21:56
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

Quote:
Originally Posted by Jiaz View Post
The screenshot link is broken.
Not broken... work

**External links are only visible to Support Staff****External links are only visible to Support Staff**

JD2 why not release unused memory?!
How To: Automatically release unused memory in JD2 (Only restart JD2?????)
Java still uses system memory after deallocation of objects and garbage collection.

Quote:
5K*** links = 4GB RAM
100*** links = 4GB RAM
Restart JD2 = ~ 200 MB RAM
I now have more physical memory, but JD2 and so there will always be a large Heap

Note *** - List of links decreases while downloading (setting: Immediately Remove Finished), but the memory is increasing instead of decreasing it. Memory is not released

Last edited by djmakinera; 24.08.2015 at 08:58. Reason: please do not break link obstruction.
Reply With Quote
  #223  
Old 24.08.2015, 15:10
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

Heap is the memory Java is allowed to work with! If you give 4GB then Java will use max 4GB. If you want to release unused heap back to os then you need to tune for more aggressive memory management (please google for it, keywords are java heap free ratio garbage collector). Why should java release memory if you allowed 4GB. Getting/Freeing memory from/back to OS also costs cpu.
This has nothing to do with JDownloader. Java is a virtual machine you give memory to work with.

_**External links are only visible to Support Staff**
___://stackoverflow.com/questions/675589/jvm-sending-back-memory-to-os
___://stackoverflow.com/questions/4625103/does-the-jvm-give-back-free-memory-to-the-os-when-no-longer-needed
___://www.coderanch.com/t/609676/java/java/Unused-java-memory-released-OS
You need to experiment yourself and find values that suits your needs!
__________________
JD-Dev & Server-Admin

Last edited by raztoki; 24.08.2015 at 15:15.
Reply With Quote
  #224  
Old 24.08.2015, 15:41
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

-Xmx4G - Not always the best value when JD2 use will be larger than 4GB is JD2 will crash / freeze for large packages (black GUI) and High CPU

Quote:
costs cpu.
i5 4690K
A powerful processor and will not be a problem

Last edited by djmakinera; 24.08.2015 at 15:45.
Reply With Quote
  #225  
Old 24.08.2015, 16:16
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

Then use higher max heap. or setup more aggressive memory management. I provided some links, google is your friend
__________________
JD-Dev & Server-Admin
Reply With Quote
  #226  
Old 24.08.2015, 16:58
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

-XX:InitialHeapSize=XXXX
-XX:MaxHeapSize=XXXX


XXXX -> I do not know what the best value for 16GB of RAM
Reply With Quote
  #227  
Old 24.08.2015, 17:11
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

Those are not the values you need to modify -> those tell the max heap -> same as -Xmx
You need to modify the Ratio values -> to tell java how much free memory it should keep and release rest back to os
__________________
JD-Dev & Server-Admin
Reply With Quote
  #228  
Old 24.08.2015, 17:22
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

JD2 not run..
Code:
"C:\Program Files\Java\jre1.8.0_60\bin\javaw.exe" -Xmx8G -XX:MaxHeapFreeRatio=20 -XX:MinHeapFreeRatio=80 -jar I:\Jdownloader2\JDownloader.jar

Last edited by djmakinera; 24.08.2015 at 17:54.
Reply With Quote
  #229  
Old 24.08.2015, 17:27
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

You allow max 20 % Free but Request at least 80% Free
MaxHeapFreeRatio -> % that are allowed to be unused
MinHeapFreeRatio -> % that are required to be unused
__________________
JD-Dev & Server-Admin
Reply With Quote
  #230  
Old 24.08.2015, 17:59
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

Ahhh.. Now is good

"C:\Program Files\Java\jre1.8.0_60\bin\javaw.exe" -Xmx8G -XX:MinHeapFreeRatio=20 -XX:MaxHeapFreeRatio=80 -jar I:\Jdownloader2\JDownloader.jar
Reply With Quote
  #231  
Old 24.08.2015, 18:24
raztoki's Avatar
raztoki raztoki is offline
English Supporter
 
Join Date: Apr 2010
Location: Australia
Posts: 16,156
Default

We will see if you make comments about loads of cpu/garbage collection now. Think that's what happened last time you played with these settings o_O

It would be nice if it was possible to find that sweet spot (memory settings) for your high intensive use of JDownloader.
__________________
raztoki @ jDownloader reporter/developer
http://svn.jdownloader.org/users/170

Don't fight the system, use it to your advantage. :]
Reply With Quote
  #232  
Old 24.08.2015, 18:43
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

You do not believe me that, for example. 1K links uses a lot of RAM?
I run jd2 only the basic settings -Xmx and show on the video?
but first I have to download the files after the download is complete will show
Reply With Quote
  #233  
Old 24.08.2015, 18:55
raztoki's Avatar
raztoki raztoki is offline
English Supporter
 
Join Date: Apr 2010
Location: Australia
Posts: 16,156
Default

I never said I don't believe you. I was just recalling/indicating my memories from the last time you tried playing with memory ratios, it didn't end well.

I earlier wrote a reply though I never posted it. It was along the lines of... its just the way Java memory allocation/management has been designed. To me its more designed/orientated around server applications, where (small|medium|large) memory allocations/reserves ensure that the application isn't ground to a halt from another.

This has attributed in my opinion to one of Java biggest negative sentiments within end users.
"Java uses lots of memory". Even though it's not actually using it, its more so reserved.
"Java is slow", its used for nano second trading on stock markets, can't be slow in that situation. Think the slowness really roots from applications that have heavy or poorly designed GUI.
__________________
raztoki @ jDownloader reporter/developer
http://svn.jdownloader.org/users/170

Don't fight the system, use it to your advantage. :]

Last edited by raztoki; 25.08.2015 at 11:26.
Reply With Quote
  #234  
Old 24.08.2015, 21:08
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

Reply With Quote
  #235  
Old 25.08.2015, 09:01
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

Please use JVisualVM that shows the heap and its usage. The VirtualMemory Usage tells us NOTHING important. I can see JD using 278MB Memory from that Screenshot
__________________
JD-Dev & Server-Admin
Reply With Quote
  #236  
Old 31.08.2015, 12:29
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

This should help increase the Read Time-Out
Example 30 second to 60 second or 90 or 120
For example. When you have a heavily loaded Internet connection or slow.
Reply With Quote
  #237  
Old 31.08.2015, 12:32
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

Even heavy loaded connections should never timeout
__________________
JD-Dev & Server-Admin
Reply With Quote
  #238  
Old 31.08.2015, 13:09
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

Jiaz - Interrupt the Internet connection to the site during the 30000 millisecond if there is not enough time to connect to a Web site (eg. Server is slow).
I have had such cases that the increase limit - can help if many decrypt links.
Reply With Quote
  #239  
Old 31.08.2015, 13:44
Jiaz's Avatar
Jiaz Jiaz is offline
JD Manager
 
Join Date: Mar 2009
Location: Germany
Posts: 64,732
Default

Quote:
Originally Posted by djmakinera View Post
Jiaz - Interrupt the Internet connection to the site during the 30000 millisecond if there is not enough time to connect to a Web site (eg. Server is slow).
I have had such cases that the increase limit - can help if many decrypt links.
typical behaviour of bad routers (small nat tables)
__________________
JD-Dev & Server-Admin
Reply With Quote
  #240  
Old 31.08.2015, 13:51
djmakinera djmakinera is offline
JD Legend
 
Join Date: May 2010
Location: Poland
Posts: 8,223
Default

Not necessarily. Eg. Some distant servers, for example. Chinese has a long way to go, so increasing the time can help
Reply With Quote
Reply

Thread Tools
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

All times are GMT +2. The time now is 15:18.
Provided By AppWork GmbH | Privacy | Imprint
Parts of the Design are used from Kirsch designed by Andrew & Austin
Powered by vBulletin® Version 3.8.10 Beta 1
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.