aspose file tools*
The moose likes Linux / UNIX and the fly likes javac only returns 'Killed' Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "javac only returns Watch "javac only returns New topic
Author

javac only returns 'Killed'

Jim Kavanagh
Greenhorn

Joined: May 17, 2004
Posts: 7
Hi,
I just installed the java sdk 1.4.2 04 the other day on my linux machine and everything was fine.

But I came back to it the next day all it will say is "killed".

Example:
# ./java -version
Killed

I've tried google but "java" and "killed" come back with some interesting results.

Thanks for any help
Stefan Wagner
Ranch Hand

Joined: Jun 02, 2003
Posts: 1923

did you execute the command in the JAVA/bin dir?


http://home.arcor.de/hirnstrom/bewerbung
Jim Kavanagh
Greenhorn

Joined: May 17, 2004
Posts: 7
Yes,

The directory Im using is:
/usr/java/j2sdk1.4.2_04/bin

I set up $JAVA_HOME to point there as well (less the /bin) if that makes a difference.
Jason Fox
Ranch Hand

Joined: Jan 22, 2004
Posts: 114
I believe the /bin directory does make a difference, but I could be wrong. At least, my $JAVA_HOME includes it (per etc/profile on mdk 10) and java works fine for me. To clarify, I checked and I am running 1.4.2_04 as well. What distro/ kernel are you using?
[ May 17, 2004: Message edited by: Jason Fox ]
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
The bin directory is not meant to be part of the JAVA_HOME environment variable. JAVA_HOME/bin is often included in the PATH environment variable.

I'm moving this to the Linux/UNIX forum, where folks might have an idea of what's going on...


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
Jim Kavanagh
Greenhorn

Joined: May 17, 2004
Posts: 7
I'm using mandrake 9.2, kernel 2.4.22.

Would upgrading to a newer version make any difference?
Stefan Wagner
Ranch Hand

Joined: Jun 02, 2003
Posts: 1923

I don't think so.

JAVA_HOME seems to be set properly, putting $JAVA_HOME/bin into the path is very useful.

I didn't ever encounter such an error with java on linux.

Have you tried
java
javac
jar
without argument?
Leslie Chaim
Ranch Hand

Joined: May 22, 2002
Posts: 336
try these commands

which java
type java
whereis java

What do you get?


Normal is in the eye of the beholder
Jim Kavanagh
Greenhorn

Joined: May 17, 2004
Posts: 7
Yes, I have tried java, javac, javadocs, and javah all with and with out commands.

This is what is returned when I enter those commands:
which java
/usr/java/java/bin/java
type java
java is /usr/java/java/bin/java
whereis java
java:
Jason Fox
Ranch Hand

Joined: Jan 22, 2004
Posts: 114
If I'm recalling your earlier post correctly where you mention where you had java installed, I believe the output of 'whereis java' should be:

/usr/java/j2sdk1.4.2_04/bin

What is the output of $PATH?
[ May 18, 2004: Message edited by: Jason Fox ]
Leslie Chaim
Ranch Hand

Joined: May 22, 2002
Posts: 336
echo $PATH | tr ':' '\n'
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16065
    
  21

If you literally typed:

./java -version

the shell is going to be looking in your current working directory for an executable named "java".

Leave off the "./" and just type

java -version


Customer surveys are for companies who didn't pay proper attention to begin with.
Jim Kavanagh
Greenhorn

Joined: May 17, 2004
Posts: 7
Thanks for all the help. I really appreciate it.

I gave up and upgraded to mandrake 10, because I read alot of posts of people complaining about security settings in mandrake 9.2.

Again, thanks alot!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: javac only returns 'Killed'