alnaseh
Posts: 75
Joined: Thu Jun 23, 2016 5:12 am

java is not supported any more on Pi0 with OS buster

Wed Jun 26, 2019 6:37 am

OK, this is surprising, the OS team adopted the new java 11 in buster as the default java but it is not supported anymore in the old armv6 (pi0).

this is like discontinuing java totally for Pi zero

the topic is been discussed previously in:
https://www.raspberrypi.org/forums/view ... p?t=196887
https://www.raspberrypi.org/forums/view ... 4#p1461934

there is no way out of this except going back to java 8 in buster

alnaseh
Posts: 75
Joined: Thu Jun 23, 2016 5:12 am

Re: java is not supported any more on Pi0 with OS buster

Wed Jun 26, 2019 6:40 am

also please find the installation error:

Code: Select all

update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jmod to provide /usr/bin/jmod (jmod) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jps to provide /usr/bin/jps (jps) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jrunscript to provide /usr/bin/jrunscript (jrunscript) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jshell to provide /usr/bin/jshell (jshell) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jstack to provide /usr/bin/jstack (jstack) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jstat to provide /usr/bin/jstat (jstat) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jstatd to provide /usr/bin/jstatd (jstatd) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/rmic to provide /usr/bin/rmic (rmic) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/serialver to provide /usr/bin/serialver (serialver) in auto mode
update-alternatives: using /usr/lib/jvm/java-11-openjdk-armhf/bin/jhsdb to provide /usr/bin/jhsdb (jhsdb) in auto mode
Setting up ca-certificates-java (20190405) ...
head: cannot open '/etc/ssl/certs/java/cacerts' for reading: No such file or directory
Error occurred during initialization of VM
Server VM is only supported on ARMv7+ VFP
dpkg: error processing package ca-certificates-java (--configure):
 installed ca-certificates-java package post-installation script subprocess returned error exit status 1
Processing triggers for libc-bin (2.28-10+rpi1) ...
Processing triggers for systemd (241-5+rpi1) ...
Processing triggers for man-db (2.8.5-2) ...
Processing triggers for ca-certificates (20190110) ...
Updating certificates in /etc/ssl/certs...
0 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d...

Error occurred during initialization of VM
Server VM is only supported on ARMv7+ VFP
E: /etc/ca-certificates/update.d/jks-keystore exited with code 1.
done.
Errors were encountered while processing:
 ca-certificates-java
E: Sub-process /usr/bin/dpkg returned an error code (1)
pi@raspberrypi:~ $ java
Error occurred during initialization of VM
Server VM is only supported on ARMv7+ VFP

Heater
Posts: 16869
Joined: Tue Jul 17, 2012 3:02 pm

Re: java is not supported any more on Pi0 with OS buster

Wed Jun 26, 2019 9:37 am

Got'a love Java "Compile once, run anywhere".

Really, get into bed with a company and their proprietary language and you will be s....ed eventually. I have seen it happen many times.

I imagine that the best course of action, on the Pi or any other platform, is to ensure your code works with Open Source solutions.

What is wrong with OpenJDK?

In the long run use a language with a proper standard behind it to ensure longevity of your code base.
Memory in C++ is a leaky abstraction .

knute
Posts: 612
Joined: Thu Oct 23, 2014 12:14 am
Location: Texas
Contact: Website

Re: java is not supported any more on Pi0 with OS buster

Thu Jun 27, 2019 9:05 pm

Buster, openjdk-11-jdk, openjdk-11-jre-zero and the -zero command line option is all that's needed. It is really slow in a Zero though.

bullen
Posts: 398
Joined: Sun Apr 28, 2013 2:52 pm

Re: java is not supported any more on Pi0 with OS buster

Thu Jul 04, 2019 10:27 am

Ok, but how does one fix a broken installation?

Uninstall the non -zero jre? Nope!

Ok, it's obviously time for us to learn how to compile Java from scratch!

Just had a google and what do you know: https://stackoverflow.com/questions/311 ... n-and-orac
https://github.com/tinspin/rupy - A tiny Java async HTTP application server.

knute
Posts: 612
Joined: Thu Oct 23, 2014 12:14 am
Location: Texas
Contact: Website

Re: java is not supported any more on Pi0 with OS buster

Wed Jul 17, 2019 2:13 pm

So there is an interesting fault when openjdk-11 is installed on a Pi0 or Pi1. The script that sets the ca-certificates doesn't run because it call java without the -zero option and fails. This causes it to fail doing some things that require use of the certificate (eg. java.mail).

Today I'm going to try installing the openjdk to the OS when it is running on a Pi3 and then taking the chip to a Pi1 and see if it works then.

Will report back.

knute
Posts: 612
Joined: Thu Oct 23, 2014 12:14 am
Location: Texas
Contact: Website

Re: java is not supported any more on Pi0 with OS buster

Wed Jul 17, 2019 3:53 pm

knute wrote:
Wed Jul 17, 2019 2:13 pm
So there is an interesting fault when openjdk-11 is installed on a Pi0 or Pi1. The script that sets the ca-certificates doesn't run because it call java without the -zero option and fails. This causes it to fail doing some things that require use of the certificate (eg. java.mail).

Today I'm going to try installing the openjdk to the OS when it is running on a Pi3 and then taking the chip to a Pi1 and see if it works then.

Will report back.
openjdk-11 does install without error when run on a Pi3. That error however doesn't seem to be the reason that java mail doesn't work on a Pi1 with openjdk-11. I'm going to start a new thread on that.

alnaseh
Posts: 75
Joined: Thu Jun 23, 2016 5:12 am

Re: java is not supported any more on Pi0 with OS buster

Sun Aug 04, 2019 4:23 pm

problem is solved. OpenJDK 11 is available for Pi0 armv6 from zulu:
https://www.azul.com/downloads/zulu-embedded/

it works out of the box. i need to test its performance against oracle jdk8, but initially it works.

i tried as well adoptopenjdk without success.

in addition, bell-sw.com has also a release for pi0 armv6 but it is available only for commercial use (not free)

builds.shipilev.net seems to have one as well but i didn't test it yet.

good, i can still derive more from the old chip
Last edited by alnaseh on Tue Oct 08, 2019 5:53 pm, edited 1 time in total.

mutant
Posts: 1
Joined: Sun Mar 24, 2013 6:08 pm

Re: java is not supported any more on Pi0 with OS buster

Sat Oct 24, 2020 9:39 am

Heater wrote:
Wed Jun 26, 2019 9:37 am
In the long run use a language with a proper standard behind it to ensure longevity of your code base.
Gotta love anybody who knocks Java for being "non-standard" and "proprietary" they seem to have missed the point that standards have moved on from the world of ISO and IEEE standards (which have their place) to community driven processes like RFC. In short we have moved on from standards as engines purely of stability to standards as being engines of stability with change. Whether JCP deserves the Community label is another debate - but like it or not, Java is a highly ubiquitous language and both has a reasonable variety of implementations with both open and closed source code and supports more platforms without tedious conditional recompilation or dead slow interpretation than any other language.
The big issue is of course who "owns" Java. Sun were at least very protective of the language and fought hard to keep M$ from introducing dodgy extensions whilst skipping new versions in a way that threatened to fragment the language"s support. They began the whole JCP process. Oracle was in the short term the worst thing that happened to Java (they only really wanted to neutralize MySQL, Java ownership was just frosting), but in the long run it may motivate the community to tear the ownership of Java out of Oracle's cold dead hands.
The clue to the weakness in the comment above is that this discussion is possible or has alternatives at all - if we were talking about a truly closed proprietary language, the answer here would be 'tough sh*t, suck it up and upgrade to the new M$ blueberry tart running Windoze 10 phone". Instead, there are options. You can compile versions from source. There are compiled Open Source alternatives.

Heater
Posts: 16869
Joined: Tue Jul 17, 2012 3:02 pm

Re: java is not supported any more on Pi0 with OS buster

Sun Oct 25, 2020 8:59 am

mutant wrote:
Sat Oct 24, 2020 9:39 am
Gotta love anybody who knocks Java for being "non-standard" and "proprietary" ...
... The big issue is of course who "owns" Java.
The meaning of "proprietary" is "relating to an owner or ownership."

And with that I hope you see the contradiction in what you have written.

I presume then you "gotta love" me for speaking factually.
mutant wrote:
Sat Oct 24, 2020 9:39 am
The clue to the weakness in the comment above is that this discussion is possible or has alternatives at all - if we were talking about a truly closed proprietary language, the answer here would be 'tough sh*t, suck it up and upgrade to the new M$ blueberry tart running Windoze 10 phone". Instead, there are options. You can compile versions from source. There are compiled Open Source alternatives.
There is no weakness in my comment. Just ask Google : "Google LLC v. Oracle America, Inc." : https://en.wikipedia.org/wiki/Google_LL ... erica,_Inc.

In short I don't want to use a proprietary programming language and have the worry of such legal threats from such a vicious predatory company hanging over my head. I don't think it's wise for anyone to do so.
mutant wrote:
Sat Oct 24, 2020 9:39 am
...they seem to have missed the point that standards have moved on from the world of ISO and IEEE standards (which have their place) to community driven processes like RFC.
Strangely enough in the year and a half since I wrote that post I have softened my stance on demanding ISO/IEEE and such standards.

You see during that time I have been programming almost exclusively in Rust. Rust has no ISO/IEEE standard but it is truly open source and has exactly the community governance and RFC process you describe. https://www.rust-lang.org/governance. Without the sword of Damocles (Oracle) hanging over anyone's head.

I also started to think about the fact that there are many such ISO/IEEE standards that nobody gives a shit about and are essentially useless. For example the are ANSI/ISO standards for BASIC. One would be hard pressed to find a standards conforming BASIC or anyone that supports or uses it.

In short, an ISO/ANSI/IEEE standard by itself is not enough and even does not matter if their is no community around it.
Memory in C++ is a leaky abstraction .

User avatar
jahboater
Posts: 6301
Joined: Wed Feb 04, 2015 6:38 pm
Location: Wonderful West Dorset

Re: java is not supported any more on Pi0 with OS buster

Sun Oct 25, 2020 9:33 am

Heater wrote:
Sun Oct 25, 2020 8:59 am
In short I don't want to use a proprietary programming language and have the worry of such legal threats from such a vicious predatory company hanging over my head. I don't think it's wise for anyone to do so.
+1, or even just the threat of the language being abandoned because its no longer profitable for that one single company. A proper standard provides independence.
Heater wrote:
Sun Oct 25, 2020 8:59 am
You see during that time I have been programming almost exclusively in Rust. Rust has no ISO/IEEE standard but it is truly open source and has exactly the community governance and RFC process you describe.
Python has its 2/3 problems, and my last experience of Rust was that the repository version did not work and the nightly build had to be used. Once a strong standard appears (that everyone adheres to), stability improves and progress slows (except for C++ perhaps).
Heater wrote:
Sun Oct 25, 2020 8:59 am
For example the are ANSI/ISO standards for BASIC. One would be hard pressed to find a standards conforming BASIC or anyone that supports or uses it.
And look where that's got BASIC. More than 300 different and incompatible versions.
Heater wrote:
Sun Oct 25, 2020 8:59 am
In short, an ISO/ANSI/IEEE standard by itself is not enough and even does not matter if there is no community around it.
Of course. The popular standardized languages have that.

Imagine what floating-point would be like on computers if the IEEE had not produced a standard .......
Pi4 8GB running PIOS64 Lite

Heater
Posts: 16869
Joined: Tue Jul 17, 2012 3:02 pm

Re: java is not supported any more on Pi0 with OS buster

Sun Oct 25, 2020 12:13 pm

jahboater wrote:
Sun Oct 25, 2020 9:33 am
Python has its 2/3 problems, and my last experience of Rust was that the repository version did not work and the nightly build had to be used. Once a strong standard appears (that everyone adheres to), stability improves and progress slows (except for C++ perhaps).
I'm curious to know what that was about.

Rust reached version 1.0 five years ago. The promise was, and still is, that all subsequent releases would always be backward compatible and run code written to version 1.0. This being the same promise one gets with C, C++, Javascript.

As far as I can tell this has held true. Apart from obscure cases of code that depended on a compiler bug that was subsequently fixed. Rather like code that depends on UB in C and then finding that what the compiler does with that UB changes one day.

Presumably you were trying to build some code written to a nightly build, basically a beta of a future release, which used features not yet available in the stable release.

In short, unlike Python and more like C/C++, Rust will not suddenly stop compiling your old code.

What I wonder about the idea of an ISO standard or whatever for Rust is: If Rust has open governance and an RFC process in place and so on, then why would it need to get ISO to rubber stamp it? What benefit would it have apart from getting a prestigious standards body name attached to it and the privilege of then having to pay to get a copy of the standard :(

No, what Rust needs is a formal specification, so that anyone could build a conformant compiler from it. Which folks are working on. Rust needs a "Rust Foundation" preferably based outside of the USA.
Memory in C++ is a leaky abstraction .

User avatar
jahboater
Posts: 6301
Joined: Wed Feb 04, 2015 6:38 pm
Location: Wonderful West Dorset

Re: java is not supported any more on Pi0 with OS buster

Sun Oct 25, 2020 2:54 pm

Heater wrote:
Sun Oct 25, 2020 12:13 pm
Presumably you were trying to build some code written to a nightly build, basically a beta of a future release, which used features not yet available in the stable release.
Yes, I guessed it was something like that. It was your code. People tried the Rustc from apt-get and it failed for some reason or other. You provided a script to download the nightly build each time.
Heater wrote:
Sun Oct 25, 2020 12:13 pm
No, what Rust needs is a formal specification, so that anyone could build a conformant compiler from it.
Any serious language needs something where users can say that a certain behavior is expected according to the specification, or not - in which case everyone will accept that the compiler is at fault.

Formal specification or an ISO standard?
ISO standards change less frequently and are scrutinized and debated over years by all sorts of separate and independent interested parties. They lend a certain credence.

Just because ANSI BASIC was a mistake all those years ago, doesn't mean the whole standards process now is pointless.
Pi4 8GB running PIOS64 Lite

Heater
Posts: 16869
Joined: Tue Jul 17, 2012 3:02 pm

Re: java is not supported any more on Pi0 with OS buster

Sun Oct 25, 2020 5:50 pm

jahboater wrote:
Sun Oct 25, 2020 2:54 pm
People tried the Rustc from apt-get and it failed for some reason or other.
Does not surprise me. I had the same problem with node.js. Always many versions behind. I presume it is there because there are already other packages that depend on Rust, so an old, known to work in the system Rust is the Debian way. With good reason. Not only that you end up with a pile of Debian packages for old Rust crates and node.js modules that are required.

None of that is much fun. Luckily it is dead easy to install the latest stable or unstable releases of Rust, and node.js, without upsetting the operating systems dependencies. I hear a lot of people do that with GCC as well so as to get the latest standards.
jahboater wrote:
Sun Oct 25, 2020 2:54 pm
Any serious language needs something where users can say that a certain behavior is expected according to the specification, or not - in which case everyone will accept that the compiler is at fault.
I agree. Luckily there are people working on a formal specification of Rust. It will come to pass
jahboater wrote:
Sun Oct 25, 2020 2:54 pm
Formal specification or an ISO standard?
ISO standards change less frequently and are scrutinized and debated over years by all sorts of separate and independent interested parties. They lend a certain credence.
Credence is about all one gets from an ISO standard. The actual credibility of the standard comes from all those people from MS, Intel, Google, ARM and elsewhere the constitute the standards committee. They have a vested interest in a common standard to work to. I imagine that would all go along just fine if they just had some "C++ Foundation" and skipped the ISO part altogether.
jahboater wrote:
Sun Oct 25, 2020 2:54 pm
Just because ANSI BASIC was a mistake all those years ago, doesn't mean the whole standards process now is pointless.
I agree of course. Such standards have been essential to industry ever since British Standard Whitworth screw threads and the like.
Memory in C++ is a leaky abstraction .

Return to “Java”