Uploaded image for project: 'Cassandra'
  1. Cassandra
  2. CASSANDRA-11716

cassandra 2.2 fails to start on jdk7u101

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Normal
    • Resolution: Duplicate
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:

      ubuntu 12.04 fully updated

    • Severity:
      Normal

      Description

      Today I updated one of my clusters to 2.2.6, and was greeted with the message complaining about the jdk version:

      $ nodetool status
      Cassandra 2.0 and later require Java 7u25 or later.
      

      After digging into it, on cassandra-env.sh, i found that you are comparing the patch levels as strings, meaning that "101" is before "25":

      if [ "$JVM_VERSION" \< "1.8" ] && [ "$JVM_PATCH_VERSION" \< "25" ] ; then
          echo "Cassandra 2.0 and later require Java 7u25 or later."
          exit 1;
      fi
      

      I patched this on my system to

      if [ "$JVM_VERSION" \< "1.8" ] && [ "$JVM_PATCH_VERSION" -lt "25" ] ; then
          echo "Cassandra 2.0 and later require Java 7u25 or later."
          exit 1;
      fi
      

      this seems to work on bash. I can now start cassandra successfully on that cluster.

        Attachments

        1. cassandra-env.patch
          0.4 kB
          Tiago Batista

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                tsbatista Tiago Batista
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: