TeamSQL / desktop-app

This repository is currently being used for hosting the official issue & bug tracker of TeamSQL Desktop App.
102 stars 6 forks source link

TeamSQL doesn't recognize my java jdk official from Oracle, nor OpenJDK #408

Open darthcabs opened 5 years ago

darthcabs commented 5 years ago

How does TeamSQL lool from Java's JDK in my OS?

OS: Linux x64 4.15.0-29deepin-generic VERSION: 4.0.376

Database Type: mysql How can this issue be reproduced?

Install .deb from Oracle's website Set $JAVA_HOME Add $JAVA_HOME to $PATH Run 'sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/lib/jvm/jdk-11/bin/javac" 1' to create symlink to /usr/bin

selcukayhan commented 5 years ago

Hi @darthcabs ,

I tried to reproduce your issue but I did not see any error. (I have 3 versions of OpenJDK's and 2 versions of Oracle's)

Can you please run below script on terminal, it will return you a list of available javas, then select the java version which you want to use. (Your lastly installed java should be in that list)

sudo update-alternatives --config java

Thank you.

darthcabs commented 5 years ago

Hi, @selcukayhan,

It didn't work. by issueing java -version in terminal I get Java normally, so it is in my $PATH. Can you tell me how exactly TeamSQL looks for Java on a system?

The error I keep receiving is

Java Development Kit is required to connect MySQL databases. TeamSQL uses JDBC drivers for MySQL connections. You can download latest JDK version from here.

This indicates me it expects to find Java JDK. But the title for this error message says 'JRE not found'.

Just out of curiosity I ran TeamSQL with sudo, and to my surprise it worked, so I'm glad I can now connect to MySQL, but it made me even more intrigued.

selcukayhan commented 5 years ago

Hi @darthcabs ,

I think, you installed JAVA to custom directory and TeamSQL is not able to reach that directory but when you use sudo it works fine because sudo user able to reach there.

Thank you.

hotrush commented 5 years ago

I have the same issue with debian. Installed java 11 jdk with apt.

java --version
Picked up _JAVA_OPTIONS:   -Dawt.useSystemAAFontSettings=gasp
openjdk 11 2018-09-25
OpenJDK Runtime Environment (build 11+13-Debian-2)
OpenJDK 64-Bit Server VM (build 11+13-Debian-2, mixed mode, sharing)

But when testing mysql connection - https://i.imgur.com/fncK8ot.png