1

I installed IntelliJ 2019.1 on Linux Mint, but it doesn't recognize the JDK. I'm used to it automatically detecting it.

I have tried:

  • Manually adding the JDK.  I go to Project Structure and try to select an SDK; it says "NO SDK".  I try to add one and it opens a dialog window where I should select the JDK's location.  I want to select /usr/bin/java or /usr/lib/jvm/, but when I browse into /usr and expand bin, it shows bin as empty.  Likewise, it doesn't see the jvm/ directory within /usr/lib.
  • Removing IntelliJ, purging all traces of java from my system, reinstalling OpenJDK 8 using apt, restarting, then reinstalling IntelliJ.
  • Tried following the steps at the "IntelliJ can't find JDK" FAQ (at Linux Mint Forums), but the repo was taken down on the 16th of April.

I need to specifically use version 8, preferably OpenJDK not Oracle (existing project with other team members who would like us all using the JDK).

java -version returns

openjdk version "1.8.0_191"
OpenJDK Runtime Environment (build 1.8.0_191-8u191-b12-2ubuntu0.18.04.1-b12)
OpenJDK 64-Bit Server VM (build 25.191-b12, mixed mode)

whereis java returns

java: /usr/bin/java /usr/share/java /usr/share/man/man1/java.1.gz

echo $JAVA_HOME returns nothing.

2
  • What do you mean by “selecting /xxx/xxx/xxxx”? Apr 24, 2019 at 2:44
  • I go to Project Structure, try to select an SDK, it says NO SDK, I try to add one, it opens a window where I should select the JDK's location, I expand usr then expand bin and bin shows as empty. Please let me know if there's any specific information I'm missing
    – Hadya
    Apr 24, 2019 at 13:14

1 Answer 1

0

i think the issue is your intellij might be a flatpak install which cant access certain directories like lib, bin, usr

this might help: https://intellij-support.jetbrains.com/hc/en-us/community/posts/360003479520-Intellij-doesn-t-see-JDK-in-Linux-Mint#community_comment_360001644240

1
  • 1
    While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference. Link-only answers can become invalid if the linked page changes. - From Review Jan 9, 2023 at 20:50

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .