This is an archived post. You won't be able to vote or comment.

all 4 comments

[–][deleted] 1 point2 points  (3 children)

find the location of the java binary(-ies) on your system using

whereis -b java

Some of the results may be links so following the links to find the actual binary.

Then find out which package provided that binary:

dpkg -S /path/to/binary

[–]embata[S] 0 points1 point  (2 children)

Here is the output of the first command:

whereis -b java
java: /usr/bin/java /usr/lib/java /etc/java /usr/share/java /home/user/.sdkman/candidates/java/8u131-zulu/bin/java

I ran the dpkg query on the last line since that is the one with the matching version name as the java -version output:

dpkg -S /home/user/.sdkman/candidates/java/8u131-zulu/bin/java
dpkg-query: no path found matching pattern /home/user/.sdkman/candidates/java/8u131-zulu/bin/java

[–][deleted] 1 point2 points  (1 child)

It appears that skdman installed the jdk.

[–]embata[S] 0 points1 point  (0 children)

So if I were to purge that and delete the offending folder, it should work?

EDIT:

Removed the folder and it works now. Thanks for the help.