PDA

View Full Version : javac and java wherefore art thou?



A. Jorge Garcia
06-24-2004, 02:05 AM
I've been using KNOPPIX to teach Computer Science for years now. However, I'm still confused about one thing: what flavor of javac and java is being using in KNOPPIX 3.4?

Am I correct in assuming that when I use the command line:
javac Hello.java
I'm using GNC GCC?

Am I also correct in assuming that when I use the command line:
java Hello
I'm using BlackDown?

Is this right, do I have it backwards or am I totally off base? Please advise!!

The reason I ask is that I'm trying to use java green threads in an openmosix clustered environment (ie: QUANTIAN which is based on clusterKNOPPIX which is, in turn, based on KNOPPIX) but I've had no joy so far!

When I try the -green switch with javac it seems to be recognized. So, whatever JDK for javac is installed in KNOPPIX will work for my project. The problem occurs when I use the -green switch with java and its not recognized! So, whatever JVM for java is installed in KNOPPIX will not work for my project! ARRGGGHHHH!!!!!

I need to find out what javas are installed, how to uninstall the non-green thread enabled java and what green thread enabled java I need to install.

BTW, I'm using a knoppix-installered QUANTIAN PC with several clustered nodes based on QUANTIAN CDs.

FYI:
http://bofh.be/clusterknoppix/
http://dirk.eddelbuettel.com/quantian.html

TIA,
AJG

fingers99
06-24-2004, 05:11 AM
I know little about java (except that I vastly prefer Smalltalk!).

Anyway, I get:

john@niglo:~$ java -version
java version "1.4.2_02"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_02-b03)
Java HotSpot(TM) Client VM (build 1.4.2_02-b03, mixed mode)
john@niglo:~$ javac -version
gcj-3.3 (GCC) 3.3.2 (Debian)
Copyright (C) 2003 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

A. Jorge Garcia
06-24-2004, 01:53 PM
OK, so I was right about javac at least, its GNU GCC GCJ.

Klaus told me once that he used BlackDown java. I guess that Debian now supports the standard edition java (why not javac?). BTW, Klaus, maybe you should go back the BlackDown JVM 1.3. That way both javas (ie:javac and java, or the jdk and the jvm) are green thread enabled! This would help the clusterKNOPPIX project based on KNOPPIX and the QUANTIAN project based on clusterKNOPPIX as both are designed around the openMOSIX kernel!

So, I'll keep GNU GCC GCJ javac as it recognizes the -green switch. I'll have to remove the standard edition JVM and install BalckDown java's JVM 1.3 which I understand supports green threads. What a hassle! I'm going to have to do this to all 25 nodes and make them all knoppix-installered as QUANTIAN. I wanted to avoid this as standard KNOPPIX has always worked well for me in class and I have 3.4 clients and a 3.3 server already knoppix-installered. What I wanted to do was set up one QUANTIAN server to start and monitor and save results from a run of a threaded app on my cluster made up of QUANTIAN liveCD clients (so I don't have to mess up my classroom setup) in addition to the one knoppix-installered QUANTIAN server.

Maybe if I just reinstall java on the QUANTIAN server, my clients can see it by sshing to the server....

No! Wait! Stop the presses! What a fool I am! All I need to do is start the green threads on the server that has all green enabled javas and the threads should automagically migrate over the openMOSIX cluster! OOPs, never mind.

FYI:
This is what I get on my KNOPPIX 3.3 20031119 server:
mrg@CentauriPrime:~$ java -version
java version "1.4.1"
Java(TM) 2 Runtime Environment, Standard Edition (build Blackdown-1.4.1-01)
Java HotSpot(TM) Client VM (build Blackdown-1.4.1-01, mixed mode)
mrg@CentauriPrime:~$ javac -version
gcj-3.2 (GCC) 3.2.3
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

This is what I get on one of my KNOPPIX 3.4 clients:
apcs@tauCentauri:~$ java -version
java version "1.4.2_02"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_02-b03)
Java HotSpot(TM) Client VM (build 1.4.2_02-b03, mixed mode)
apcs@tauCentauri:~$ javac -version
gcj-3.3 (GCC) 3.3.3 (Debian 20040429)
Copyright (C) 2003 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


This is what I get on my QUANTIAN 0.4.9.5 server (based on clusterKNOPPIX 3.3 which, in tern, is based on KNOPPIX 3.3) on which I had to install java.sun.com's javac and java from scratch myself (QUANTIAN 3.3 deleted java to make space for lots of math and science apps):
apcs@upsilonCentauri:~$ java -version
java version "1.4.2_04"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05)
Java HotSpot(TM) Client VM (build 1.4.2_04-b05, mixed mode)
(javac -version doesn't work, but its the same version)

Thanx for your help,
AJG