Jump to content

Adding JDK to Ubuntu server


Funfight

Recommended Posts

1 hour ago, Funfight said:

Hey there, I currently have JRE installed on my machine but I need to get JDK instead.  I've figured out how to remove JRE entirely from my machine, but have had troubles installing JDK alone without it coming with JRE.  Any help would be spectacular.

Thanks,

Funfight

Your server doesnt need the JDK, it only needs the JRE. The JDK only comes with the JRE. You only need the JDK if you're writing code in Java, if you're only running bots then JRE is all thats needed. 

  • Like 2
Link to comment
Share on other sites

1 hour ago, Funfight said:

I've found that the memory spikes with JRE and not JDK

That doesn't make any sense. "Spikes" can happen for many, many reasons such as GC cycles which can be affected by setting max heap space "aka -mem". It could also be affected by the way a script is written. The JDK comes with the JRE. Java doesn't run on a JDK, it runs on a JRE. 

If you are running Linux, you especially need to know how this works because you need to set up environment variables correctly (Google "linux java home"). In Windows this is very easy:

fa713d12f2d9ec346702a59192fbc263.png

 

Just to make this 100% clear, Java does NOT run on the JDK. It runs on the JRE which comes with the JDK or as a standalone. 

Link to comment
Share on other sites

2 hours ago, Alek said:

That doesn't make any sense. "Spikes" can happen for many, many reasons such as GC cycles which can be affected by setting max heap space "aka -mem". It could also be affected by the way a script is written. The JDK comes with the JRE. Java doesn't run on a JDK, it runs on a JRE. 

If you are running Linux, you especially need to know how this works because you need to set up environment variables correctly (Google "linux java home"). In Windows this is very easy:

fa713d12f2d9ec346702a59192fbc263.png

 

Just to make this 100% clear, Java does NOT run on the JDK. It runs on the JRE which comes with the JDK or as a standalone. 

Thank you for the detailed explanation, much appreciated :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...