Uploaded image for project: 'Accumulo'
  1. Accumulo
  2. ACCUMULO-4193

Server/Native build fails with "JAVA_HOME does not point to a JDK" - possible regression from 1.7.1

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Not A Problem
    • None
    • None
    • native
    • None
    • CentOS 6.7, Java-8
      git commit 8ac30b8d16316e3e03054cfb3786e6b857b528c0

    Description

      Building from the git repo fails, while building from the 1.7.1 src download works fine (on the same system). I can easily work around the problem by redefining JAVA_HOME to point to a JDK. The fact that everything works find with 1.7.1 makes me wonder if the JDK is really required.

      [INFO] — exec-maven-plugin:1.4.0:exec (test-native-libs) @ accumulo-native —
      Makefile:45: *** "JAVA_HOME does not point to a JDK. Exiting...". Stop.

      Hmmm, I'm thinking I'll reboot the build VM and retry each build just in case there is some "operator error" involved.

      Attachments

        Activity

          Rebooted build VM and ran "mvn clean" on each source tree. Still get same result. I'll just change my JAVA_HOME to point to a JDK.

          cb20777 Charles Butterfield added a comment - Rebooted build VM and ran "mvn clean" on each source tree. Still get same result. I'll just change my JAVA_HOME to point to a JDK.

          Did you only try on the master branch, or can you confirm that this fails on the current 1.7 branch?

          ctubbsii Christopher Tubbs added a comment - Did you only try on the master branch, or can you confirm that this fails on the current 1.7 branch?

          Also, what command are you using to build? The only change made in the master branch was that the native libraries are now built at the package phase of the Maven build lifecycle, rather than later, at the integration-test phase. JAVA_HOME being set to a JDK has always been a requirement, but you may not have run into it if you were doing something like mvn package instead of mvn verify.

          ctubbsii Christopher Tubbs added a comment - Also, what command are you using to build? The only change made in the master branch was that the native libraries are now built at the package phase of the Maven build lifecycle, rather than later, at the integration-test phase. JAVA_HOME being set to a JDK has always been a requirement, but you may not have run into it if you were doing something like mvn package instead of mvn verify .

          I just tested on the current 1.7 branch and all seems "GOOD" (i.e. don't need JAVA_HOME to point to JDK). Here is some detail in case I'm doing something improperly:

          $ git status

          1. On branch 1.7
            nothing to commit, working directory clean

          $ echo $JAVA_HOME
          /usr/lib/jvm/jre-openjdk

          $ mvn clean
          ... output deleted ...
          $ mvn package -Passemble -DskipTests
          ... output deleted...
          [INFO] ------------------------------------------------------------------------
          [INFO] Reactor Summary:
          [INFO]
          [INFO] Apache Accumulo Project ............................ SUCCESS [ 4.437 s]
          [INFO] Apache Accumulo Fate ............................... SUCCESS [ 5.251 s]
          [INFO] Apache Accumulo Start .............................. SUCCESS [ 3.902 s]
          [INFO] Apache Accumulo Core ............................... SUCCESS [ 23.690 s]
          [INFO] Apache Accumulo Trace .............................. SUCCESS [ 0.936 s]
          [INFO] Apache Accumulo Server Base ........................ SUCCESS [ 4.533 s]
          [INFO] Apache Accumulo Tracer Server ...................... SUCCESS [ 2.147 s]
          [INFO] Apache Accumulo Shell .............................. SUCCESS [ 2.370 s]
          [INFO] Apache Accumulo Simple Examples .................... SUCCESS [ 1.725 s]
          [INFO] Apache Accumulo GC Server .......................... SUCCESS [ 1.404 s]
          [INFO] Apache Accumulo Master Server ...................... SUCCESS [ 2.236 s]
          [INFO] Apache Accumulo Monitor Server ..................... SUCCESS [ 1.846 s]
          [INFO] Apache Accumulo Tablet Server ...................... SUCCESS [ 2.862 s]
          [INFO] Apache Accumulo MiniCluster ........................ SUCCESS [ 2.426 s]
          [INFO] Apache Accumulo Native Libraries ................... SUCCESS [ 3.429 s]
          [INFO] Apache Accumulo Proxy .............................. SUCCESS [ 6.878 s]
          [INFO] Apache Accumulo Testing ............................ SUCCESS [ 6.743 s]
          [INFO] Apache Accumulo .................................... SUCCESS [ 15.011 s]
          [INFO] Apache Accumulo Documentation ...................... SUCCESS [ 0.234 s]
          [INFO] Apache Accumulo Maven Plugin ....................... SUCCESS [ 10.329 s]
          [INFO] ------------------------------------------------------------------------
          [INFO] BUILD SUCCESS
          [INFO] ------------------------------------------------------------------------
          [INFO] Total time: 01:43 min
          [INFO] Finished at: 2016-04-17T22:06:46+00:00
          [INFO] Final Memory: 119M/528M
          [INFO] ------------------------------------------------------------------------

          cb20777 Charles Butterfield added a comment - I just tested on the current 1.7 branch and all seems "GOOD" (i.e. don't need JAVA_HOME to point to JDK). Here is some detail in case I'm doing something improperly: $ git status On branch 1.7 nothing to commit, working directory clean $ echo $JAVA_HOME /usr/lib/jvm/jre-openjdk $ mvn clean ... output deleted ... $ mvn package -Passemble -DskipTests ... output deleted... [INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] Apache Accumulo Project ............................ SUCCESS [ 4.437 s] [INFO] Apache Accumulo Fate ............................... SUCCESS [ 5.251 s] [INFO] Apache Accumulo Start .............................. SUCCESS [ 3.902 s] [INFO] Apache Accumulo Core ............................... SUCCESS [ 23.690 s] [INFO] Apache Accumulo Trace .............................. SUCCESS [ 0.936 s] [INFO] Apache Accumulo Server Base ........................ SUCCESS [ 4.533 s] [INFO] Apache Accumulo Tracer Server ...................... SUCCESS [ 2.147 s] [INFO] Apache Accumulo Shell .............................. SUCCESS [ 2.370 s] [INFO] Apache Accumulo Simple Examples .................... SUCCESS [ 1.725 s] [INFO] Apache Accumulo GC Server .......................... SUCCESS [ 1.404 s] [INFO] Apache Accumulo Master Server ...................... SUCCESS [ 2.236 s] [INFO] Apache Accumulo Monitor Server ..................... SUCCESS [ 1.846 s] [INFO] Apache Accumulo Tablet Server ...................... SUCCESS [ 2.862 s] [INFO] Apache Accumulo MiniCluster ........................ SUCCESS [ 2.426 s] [INFO] Apache Accumulo Native Libraries ................... SUCCESS [ 3.429 s] [INFO] Apache Accumulo Proxy .............................. SUCCESS [ 6.878 s] [INFO] Apache Accumulo Testing ............................ SUCCESS [ 6.743 s] [INFO] Apache Accumulo .................................... SUCCESS [ 15.011 s] [INFO] Apache Accumulo Documentation ...................... SUCCESS [ 0.234 s] [INFO] Apache Accumulo Maven Plugin ....................... SUCCESS [ 10.329 s] [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 01:43 min [INFO] Finished at: 2016-04-17T22:06:46+00:00 [INFO] Final Memory: 119M/528M [INFO] ------------------------------------------------------------------------

          Yup I was using "mvn package". I'll retry with "mvn verify"

          cb20777 Charles Butterfield added a comment - Yup I was using "mvn package". I'll retry with "mvn verify"

          Interesting - when I use "mvn verifiy" on branch 1.7 without a JDK, the build fails at the test-native-libs step. Setting the JAVA_HOME to point to a JDK gets past that point. Sounds like I was just building improperly and "got lucky" with using a JRE. I'll just change my build environment to point to a JDK. Sorry for the confusion, sounds like this ticket should be closed.

          cb20777 Charles Butterfield added a comment - Interesting - when I use "mvn verifiy" on branch 1.7 without a JDK, the build fails at the test-native-libs step. Setting the JAVA_HOME to point to a JDK gets past that point. Sounds like I was just building improperly and "got lucky" with using a JRE. I'll just change my build environment to point to a JDK. Sorry for the confusion, sounds like this ticket should be closed.

          I'm a bit surprised Maven itself didn't complain about pointing to a JRE... either way, you should definitely build with a JDK. Thanks for the report, though. It was definitely worth checking into.

          ctubbsii Christopher Tubbs added a comment - I'm a bit surprised Maven itself didn't complain about pointing to a JRE... either way, you should definitely build with a JDK. Thanks for the report, though. It was definitely worth checking into.

          People

            ctubbsii Christopher Tubbs
            cb20777 Charles Butterfield
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: