On Fri, Jul 1, 2011 at 11:52 AM, Kenneth Hoste <[email protected]> wrote: > Hello, > > I was looking into installing a Java JDK 1.6.0 on our Scientific Linux 6 > systems, and found it to fail. > We need to install Java under a non-default path, e.g. /path/to/java, > and therefore extract the RPM found on the Oracle website from the RPM > binary installer using: > > ./jdk-6u26-linux-x64-rpm.bin -x > > We then install the RPM obtained this way as follows: > > rpm --initdb --dbpath /rpm --root /path/to/java > rpm -i --dbpath /rpm --root /path/to/java --relocate /=/path/to/java > --nopre --nopost --nodeps jdk-6u26-linux-amd64.rpm > > The last command is failing with: > > error: Unable to change root directory: Operation not permitted > > This way of installing the Java JDK has worked fine in our previous SL5 > setup. > > I should add that RHEL6 or SL6 is not listed as supported on the Oracle > website, see > http://www.oracle.com/technetwork/java/javase/system-configurations-135212.html
This is partly because they're re-wrapping RHEL 6 as "Oracle Enterprise Linux 6", and breaking free software best practices by merging in their proprietary code. This is in distinct contrast to what Scientific Linux does. It means that the compatibility with Oacle Enterprise releases is a good indicator that it should work, but not in any way a guarantee. Mind you, Oracle, and Red Hat and a lot of others are collaborating on openjdk. This is helping a number of long-term licensing, compatibility, and installation issues for JDK's, and has cleaned up that "rpm.bin" extraction and nastiness. If possible, please use openjdk, I think we can expect to see the old "sun" based Java packages cease development as efforts migrate to openjdk. That said, the "--relocate" command has always been tricky, and requires specific RPM bundling practices to work. See http://www.rpm.org/max-rpm/ch-rpm-reloc.html. And I do sympathize: I used ot have to install parallel 32-bit and 64-bit JDK's on the same host, and it turned out to be pretty tricky and order sensitive and required disabling of '%pre' and '%post' for one package, not the other. > Has anyone been able to install an Oracle Java JDK 6 RPM on SL6 (or RHEL6)? I did some JPackage integration attempts (I used to publish updates to their various java nosrc.rpm packages.) Gave it up as pointless when SL 6 came out and openjdk was obviously mature enough, and the JPackage 6 repository reflects this successful switchover. I'm frankly quite surprised if you really need the "Oracle JDK". Because Sun, now Oracle could not publish their SRPM's (for licensing reasons), they were quite difficult to debug, especially for this sort of installation issue. OpenJDK does not have this issue. > greetings, > > Kenneth > [email protected] >
