I installed Java 21 and Maven but when I run Maven this description appears The JAVA_HOME environment variable is not defined correctly, this environment variable is needed to run this program.
In my java_home it looks like this Java_Home c:\Program Files\Java\jdk1.8.0_65
I already uninstalled Java and Maven and installed them again and it didn't help. Can someone help me? windows10
I already uninstalled Java and Maven and installed them again and it didn't help. I already rewrote JAVA_Home and nothing.
Can someone help me? windows10
It seems like the JAVA_HOME environment variable is pointing to an older version of Java (jdk1.8.0_65) instead of the Java 21 version you have installed. To resolve this issue, you need to update the JAVA_HOME environment variable to point to your Java 21 installation.
Here's a guide: https://docs.oracle.com/en/database/oracle/machine-learning/oml4r/1.5.1/oread/creating-and-modifying-environment-variables-on-windows.html
The JAVA_HOME variable should point to something like C:\Program Files\Java\jdk-21 (confirm this directory's name).