Results 1 to 7 of 7

Thread: 8.04 Java Sun JDK 1.4.2 install doesn't work

  1. #1
    Join Date
    Sep 2007
    Beans
    8

    8.04 Java Sun JDK 1.4.2 install doesn't work

    Hi everyone,

    I downloaded the bin file for the JDK 1.4.2. I need it because i need to program for Canon and the network printers only support that java version.

    I installed the bin like this :

    Code:
    chmod a+x jdk_file_name.bin
    sudo ./jdk_file_name.bin
    it ended up in a map with all the files in it. I moved the file to my /usr/lib/jvm

    Next step is that i set the JAVA_HOME in the following manner :
    Code:
    sudo gedit /etc/environment
    and I added JAVA_HOME="path_to_javafolder" at the top of the file.

    now when i do
    Code:
    sudo update-alternatives --config java
    my java doesn't show up in the list.
    How come?

    Thanks in advance.

  2. #2
    Join Date
    Feb 2007
    Location
    Maryland, USA
    Beans
    3,396
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: 8.04 Java Sun JDK 1.4.2 install doesn't work

    You are supposed to substitute the real path name for "path_to_javafolder"

  3. #3
    Join Date
    Sep 2007
    Beans
    8

    Re: 8.04 Java Sun JDK 1.4.2 install doesn't work

    Well I did that I'm not quite that stupid

  4. #4
    Join Date
    Feb 2007
    Location
    Maryland, USA
    Beans
    3,396
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: 8.04 Java Sun JDK 1.4.2 install doesn't work

    I did not mean to insult your intelligence, but you never know around here

    Did you check to see if the symlink java is present in the /etc/alternatives directory?

  5. #5
    Join Date
    Sep 2007
    Beans
    8

    Re: 8.04 Java Sun JDK 1.4.2 install doesn't work

    Well there is a link called "java" that links to /usr/lib/jvm/java-6-sun/jre/bin/java.
    The same with javac (linked to /usr/lib/jvm/java-6-sun/bin/javac) and so on..

    I thought that installing the bin file would handle everything for me, but I guess I was wrong. So if I understand you correctly, I need to add a link to the java.jar, java.jar, etc in /usr/lib/jvm/jsdk2.4.1/? But how do i have to call it?

    By the way, I want my java 6 to stay the default java, so I think that replacing the original java-link wouldn't be the solutions I'm looking for.

  6. #6
    Join Date
    Feb 2007
    Location
    Maryland, USA
    Beans
    3,396
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: 8.04 Java Sun JDK 1.4.2 install doesn't work

    My guess is that the .bin file has to be run from the proper place with the proper permissions. On the Sun web site, they recommend running as an ordinary user, and not as root. Maybe that is part of your problem since you ran the .bin file as root. I want to try to install this too, but I am not at my Linux computer at present, I will try later.

    The update-alternatives command has to do with a Debian system that gives you choices when you enter a command, I think. It keeps track of the various java programs, and keeps the links to them in some kind of order. I have not been using it, but my impression is that if you enter a command like java the shell should then give you a list of choices. Maybe look at the man page for update-alternatives to get some clues as to how to get it to work properly. It also might have to do with running the .bin as root or as a user.

  7. #7
    Join Date
    Sep 2007
    Beans
    8

    Re: 8.04 Java Sun JDK 1.4.2 install doesn't work

    The update-alternatives command let you set the default java version. When you run the command you get a list and you can select the default java to use. I ran it and selected java 6. But after installing 1.4.2 the list didn't expand. The 1.4.2 version wasn't available in the list, so I concluded that it isn't (properly) installed.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •