On my server, I have JAVA_HOME set to jdk1.8.0_161.0.  When I execute echo 
$JAVA_HOME, it shows the right path to my jdk1.8.0_161.0.  When I run java 
-version, it shows the right version 8 as well.

When I run maven -version, it shows this:

Apache Maven 3.5.3 (3383c37e1f9e9b3bc3df5050c29c8aff9f295297; 
2018-02-24T13:49:05-06:00)
Maven home: /opt/maven/latest
Java version: 1.8.0_161, vendor: Oracle Corporation
Java home: /usr/lib/jvm/jdk1.7.0_79/jre

Note the Java home path to the wrong version but Java version shows the right 
version.

Any tips on where Maven is getting that jdk1.7.0_79/jre path?

Reply via email to