Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4495883

Exec of 64-bit binaries fail on Solaris 9: wrong path name.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P2 P2
    • None
    • 1.4.0
    • tools
    • None
    • sparc
    • solaris_7

      On Solaris 9 systems, 64-bit java commands fail depending on the path
      used when invoking the command. Here's a transcript that shows a couple
      of successful runs and a couple of failures:

          % /usr/java/bin/java -d64 -version
          java version "1.4.0-beta2"
          Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta2-b77)
          Java HotSpot(TM) 64-Bit Server VM (build 1.4.0-beta2-b77, mixed mode)

          % /usr/j2se/bin/java -d64 -version
          java version "1.4.0-beta2"
          Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta2-b77)
          Java HotSpot(TM) 64-Bit Server VM (build 1.4.0-beta2-b77, mixed mode)

          % /usr/bin/java -d64 -version
          execv(): No such file or directory

          % java -d64 -version
          execv(): No such file or directory

      Some configuration info:

          % ls -l /usr/java /usr/bin/java
          lrwxrwxrwx 1 root other 4 Aug 23 16:20 /usr/java -> j2se
          lrwxrwxrwx 1 root other 16 Jun 21 17:53 /usr/bin/java -> ../java/bin/java

          % which java
          /usr/bin/java

      A key thing to note is that Merlin is the default Java on Solaris 9, so
      that /usr/java points to /usr/j2se which is where Merlin is installed
      by default (when using the SVr4 packages for installation). Also, the java
      command in /usr/bin is a symlink to /usr/java/bin/java aka /usr/j2se/bin/java.

      A truss run shows what's going wrong:

          % truss -texec java -d64 -version
          execve("/usr/j2se/bin/java", 0xFFBEF944, 0xFFBEF954) argc = 3
          execve("/usr/bin/sparcv9/java", 0x00028DB0, 0xFFBEF954) Err#2 ENOENT
          execv(): No such file or directory

      The path /usr/bin/sparcv9/java is being used. The correct path
      is /usr/j2se/bin/sparcv9/java.

            gafter Neal Gafter (Inactive)
            sseligmasunw Scott Seligman (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: