OK, I have it working and can do a PR on github after some feedback as some changes are probably still needed… Work done so far is forked here
Issue raised on openhabian github here.
If I try on a clean system to run unattended mode it complains I am missing a conf file, yet no message telling me what to do to create one. Recommend a nicer message to guide users.
So i launched the tool and ran manual/fresh setup (option 60) which did not trigger the archive method of installing zulu. Possible ways forward are to offer the manual archive method as a 3rd Java option, or to do a simple re-direct if it detects is_odroidc2. Thoughts? I probably prefer offering it as a 3rd option that way if other devices like odroid C1+, XU4 or other arm64 devices are used, the coding is already done.
After exiting I tried to run unattended and this time it worked all the way through with all steps giving OK output. The java_zulu_embedded_archive() ran instead.
Well it’s usually not meant to be run like that. Just a wild guess is it looking for /etc/openhabian.conf ? If so, try copying your existing one. Well or read the script source what file it is looking for. You can also insert “set -x” after its first line.
Nah, I’d rather replace the zulu option because that wouldn’t work on the C2. See what routine that’s calling and insert if (is_odroidc2()) then <your install routine>. Maybe the person to review your PR (probably @ThomDietrich) will request you to change that but that’s how I would proceed.
And of course replace the zulu line of /opt/openhabian/openhabian-setup with another if (is_odroidc2()) then <your install_routine> if you haven’t done so yet.
Yes that is the one. Bottom line is as you say, it is not setup to install this way and hence it is far harder then simply using my script which now has the ability to install openhabian as part of the process.
Openhabian is in the middle of changing things to make it easier (great news), so any further changes until the framework is re-written is a waste of time.
@matt1 I am almost beaten trying to get Zulu onto my Android box.
I have a Beelink mxiii v2. Uses the S905X chipset and is fairly close to the Odroid C2 in spec. It has been running Debian Stretch with Home Assistant beautifully for a few months but I want to make the jump to Openhab.
I tried to load Zulu onto Debian and failed in every way. After seeing your troubles with ARM64 I tried Ubuntu 18.04 and had a bit more success but still cannot get it to work.
I tried your script with a couple of tweaks and it appears to get to the end but still Java gives “illegal instruction” when I check the version (java -version).
If I try running openhab the service keeps failing with illegal instruction errors. I have tried various versions of Zulu and all give the same result.
Do you have any ideas for how I can get a working Zulu installation on the thing please?
A. Pay Zulu for support and they probably know why and how to get it going.
B. Just buy an Odroid C2 as they have a big community to ask and also fix bugs in the base images they supply.
C. Try another java like Oracle or openjava, but since they are not the recommended ones to use you do raise the odds you will hit a unique bug in Openhab that no one else has seen.
Sorry I do not have any troubles, it took me a day to work out how to do a manual install of Zulu as there were no guides anywhere on how to do it step by step. My setup is working great for almost 6 months now and used daily…
I posted this guide here as it takes you through the steps with more info on getting the java sorted. If java is not running right, then dont bother trying openhab.
Uploaded an updated version of the script today. It now uses a newer version of zulu java and fixed some issues with frontail loading. Steps are in the first post of this thread on how to find and use the script.
The script will work omly on a new empty image, however the commands are easy to grab in any text editor as it is a bash script. Very easy to grab the steps you need out of it to use manually or you could create a java updating script from it.
I always setup from scratch to renew the entire sd cards contents with new reliable data.
This reports 2 errors : N: Skipping acquire of configured file ‘main/binary-arm64/Packages’ as repository ‘http://repos.azulsystems.com/ubuntu stable InRelease’ doesn’t support architecture ‘arm64’ N: Skipping acquire of configured file ‘main/binary-armhf/Packages’ as repository ‘http://deb.odroid.in/c4 bionic InRelease’ doesn’t support architecture ‘armhf’
The rest of the installation seems to go well, except that all files are owned by kernoops and if I try to do /usr/lib/jvm/zulu184.108.40.206-ca-jdk8.0.252-linux_aarch32hf/bin/java
it will return : -bash: java: command not found
even though java clearly exists …
I suppose this somewhat curious bash error message is the result of the arm32hf architecture not being recognized - and as a result it won´t run the java arm32hf binary …
Any ideas of how to get around this - or is this just a matter of wait & pray that Hardkernel will add support for the arm32hf architecture to the C4 repositories ?
Flash the minimal image I linked above and try the script again but without changing the java version and adding the openhabian-config option. Then after OH installs use openhabian-config tool to update java.
Kinda odd I just flashed Ubuntu Mate desktop on eMMC to give it a try.
I´d like to stick to the std Ubuntu image, because I may want to run other stuff next to Openhab as well …
(also I am new to this sort of board, only did some stuff on arduino in the past. I therefor wouldn´t like to make major platform changes - haven´t got eMMC lying around (yet) either - am still discovering the Odroid world. Ubuntu Mate seems ok, although I am used to Linux Mint)
I understand, I just recently got my Odriod and installed Debian to test with the script. It worked well so I thought I would give Ubuntu Desktop a try but will most likely change to minimal version as it will run headless.
I haven’t powered up the image yet but I will let you know if I get it working. Meantime try to install openhabian-config tool and see if that will resolve the Zulu issue.
The sudo apt-get update resulted in the same 2 errors : N: Skipping acquire of configured file ‘main/binary-arm64/Packages’ as repository ‘http://repos.azulsystems.com/ubuntu stable InRelease’ doesn’t support architecture ‘arm64’ N: Skipping acquire of configured file ‘main/binary-armhf/Packages’ as repository ‘http://deb.odroid.in/c4 bionic InRelease’ doesn’t support architecture ‘armhf’
but thereafter installation of the configtool went well and the openhabian-config tool starts up o.k.
You may chime in … , on the Hardkernel forum it was suggested I move to Armbian (stable version yet to be released for C4 …). But as mentioned to H102 for now I had like to stick with the standard installed Ubuntu Mate and first get to know this little beauty. Also, isn´t Ubuntu based on Debian ? So how would that change things ? The issue here seems to be ARM32hf support on the ARM64 based Odroid C4 …