Skip to main content

Installation on Raspberry Pi - Java not found

4 replies [Last post]
Joined: 2013-01-20

I followed the directions for JavaFx Early Access:

When I try to execute:
sudo /opt/jdk1.8.0/bin/java -version

I get:
sudo: java: command not found
(I assure you it is there with the correct permissions - same message when I run the command in the /opt/jdk1.8.0/bin directory where the java file is located).

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2013-01-26

I've just hit this too - the problem is that you're probably running this on the straight debian image instead of raspbian

I suggest you download an try raspbian instead - worked for me.

Note that this is different to jdk 1.7 - 1.7 wont work with raspbian, only with debian

Hope that this helps.

Joined: 2013-01-20

I've been round and round with this for the past few days. I'm running Raspbian Wheezy (12/16/2012) and I have installed OpenJDK 1.6 and 1.7 as well as Oracle JDK 6, 7, and 8. I've run into roadblocks on all combinations.
JDK 7 and 8 don't work at all. OpenJDK 1.6 works up to the point when I get to the login screen where it is missing the field to enter the password so I can't log in (I note that others seem to have had this problem also). OpenJDK 1.7 won't start the service.
I would be interested in what versions of everything your are running. Right now I'm developing my channels using a Mac but eventually I want to move this to the Raspberry Pi since I have an application with very low transaction volume which would be ideal for this platform.

Joined: 2013-03-14

The JDK 8 for ARM preview at is for the hard float ABI and will run on the hard float Raspbian distribution. It won't run on soft float Debian Wheezy.
The JDK 7 for ARM preview at is for the soft float ABI and will run on soft float Debian Wheezy but not on hard float Raspbian.

Any Linux executable for ARM - not just Java - is built either for soft or hard float ABI.
Soft float Debian for the Pi can only run soft float executables. Raspbian can only run hard float executables. IIRC recent versions of Ubuntu for ARM hard float can also run soft float binaries - but Ubuntu doesn't support the ARMv6 CPU in the Pi.

Hope this helps.

Joined: 2004-05-05

If you believe that you've found a bug, please report it along with example code to reproduce it at

Dalibor Topic
Principal Product Manager
Java Platform Group @ Oracle