Openhabian 3.0 RC2 migration/upgrade not working

Hi all,

i need your assistance please. I would like to start from scratch instead of upgrading my current OH2 installation. So i downloaded the latest openhabian image. (Raspy 4 4GB)

After initial installation i executed openhabian-config and changed

the 01Branch to openHab3 and

selected 03 - openHab3 Testing.

Everything executed with success but i am not able to access the web gui.
If i check the service status

   Loaded: loaded (/lib/systemd/system/openhab.service; disabled; vendor preset: enabled)
  Drop-In: /etc/systemd/system/openhab.service.d
           └─override.conf
   Active: active (running) since Sun 2020-12-20 22:02:53 CET; 21s ago
     Docs: https://www.openhab.org/docs/
           https://community.openhab.org
 Main PID: 2640 (java)
    Tasks: 31 (limit: 4915)
   CGroup: /system.slice/openhab.service
           └─2640 /usr/bin/java -XX:-UsePerfData -Dopenhab.home=/usr/share/openhab -Dopenhab.conf=/etc/openhab -Dopenhab.runtime=/usr/share/openhab/runtime -Dopenhab.userdata=/var/lib/o

Dec 20 22:03:12 openhab3 karaf[2640]:         ... 14 more
Dec 20 22:03:12 openhab3 karaf[2640]: Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to resolve openhab-core-base/3.0.0.RC2: missing requirement [openhab-core-base/
Dec 20 22:03:12 openhab3 karaf[2640]:         at org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1343)
Dec 20 22:03:12 openhab3 karaf[2640]:         ... 15 more
Dec 20 22:03:12 openhab3 karaf[2640]: Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to resolve org.openhab.core.automation/3.0.0.RC2: missing requirement [org.open
Dec 20 22:03:12 openhab3 karaf[2640]:         at org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1343)
Dec 20 22:03:12 openhab3 karaf[2640]:         ... 16 more
Dec 20 22:03:12 openhab3 karaf[2640]: Caused by: org.apache.felix.resolver.reason.ReasonException: Unable to resolve org.openhab.core/3.0.0.RC2: missing requirement [org.openhab.core/3.
Dec 20 22:03:12 openhab3 karaf[2640]:         at org.apache.felix.resolver.Candidates$MissingRequirementError.toException(Candidates.java:1343)
Dec 20 22:03:12 openhab3 karaf[2640]:         ... 17 more

I also tried to manually uninstall OpenHab via apt.
After reinstall i received:

[openHAB] Please install the current version of Java 11 or check the openHAB documentation for details.
[openHAB] openHAB was not running so will not start after upgrade.
[openHAB] Please use the command:
            sudo /bin/systemctl start openhab.service

Ìf i check the JAVA Version:

java - version

openjdk version "1.8.0_275"
OpenJDK Runtime Environment (Zulu 8.50.51.263-CA-linux_aarch32hf) (build 1.8.0_275-b01)
OpenJDK Client VM (Zulu 8.50.51.263-CA-linux_aarch32hf) (build 25.275-b01, mixed mode)

I did this now 3times to exclude myself as error source :smile: please give me some hints to solve this.
Thank you!

1 Like

You have Java 8 installed and need Java 11. Try installing Java from openhabian-cpnfig now you have selected an openHAB 3 repo.

1 Like

not sure how to do this via openhabian-config?didn`t found the java package.
I have now tried to install via

apt-get install openjdk-11-jdk, was already installed.

V via java -version was still Java8.
I have now changed the active version and selected option 2 via

[22:38:52] openhabian@openhab3:~$ sudo update-alternatives --config java
There are 2 choices for the alternative java (providing /usr/bin/java).

  Selection    Path                                                             Priority   Status
------------------------------------------------------------
* 0            /opt/jdk/zulu8.50.51.263-ca-jdk8.0.275-linux_aarch32hf/bin/java   1000000   auto mode
  1            /opt/jdk/zulu8.50.51.263-ca-jdk8.0.275-linux_aarch32hf/bin/java   1000000   manual mode
  2            /usr/lib/jvm/java-11-openjdk-armhf/bin/java                       1111      manual mode

If i check the version i see Java11 and have finally access to the webgui.

Thank you Bruce

openJDK is not recommended on a Pi. that is why openHABian uses Zulu Java.

Thanks Bruce,
i have removed openJDK and installed Zulu.

 java -version
openjdk version "11.0.9.1" 2020-11-06 LTS
OpenJDK Runtime Environment Zulu11.43+100-CA (build 11.0.9.1+1-LTS)
OpenJDK Client VM Zulu11.43+100-CA (build 11.0.9.1+1-LTS, mixed mode)

Everything is working fine.

1 Like

How did you set up Zulu 11? I am having the same problem.

Follow the Asul Zulu link https://www.openhab.org/docs/installation/#prerequisites in case you have to do it manually. In case of openhabian-config go to the menu item 46 and select the related java version.

Why does openhabian-config remove the Java 11 installation and not (re)install it by itself when installing openHAB 3 stable? That didn’t happen when upgrading through the milestones and the release candidates…

1 Like

Hi haybolat,

for me it didn’t worked via openhabian-config.

I did following steps:

Remove OpenJDK:

sudo apt-get purge openJDK*

Download and install latest Zulu11 package:

check version with java -version

1 Like

Thank you friends.

1 Like

Hey.
I’ve got pretty much the same problem, but still no solution …

I tried to upgrade from 2.5 to 3.0 and followed the instruction here in the community, which said something like “u will need java 11, which will be provided by openhab installation”, so i was like ‘oh, you got java 8 installed, but well then, openhab will fix this’ …

It does not ^^

I installed openhab 3.0, which told me after installation, that java 11 is missing …
So after all i purged all java 8 installations (zulu and openjdk), but still when i type “java -version” i get java 8 shown as installed.
Nevermind, i installed zulu 11 manually (as openhab_knx tells in his post) configured it to be used, so when i type “java -version” now i get zulu 11 as active java framework.

Still the problem is there, that openhab 3.0 does not start.
When checking open oports, i see no service listening on :8080
Maybe you got another hint for this?

can you check the status with:
sudo service openhab status

Was just about to add this to original post ;D

    sudo systemctl status openhab.service
● openhab.service - openHAB - empowering the smart home
   Loaded: loaded (/usr/lib/systemd/system/openhab.service; enabled; vendor preset: enabled)
   Active: active (running) since Tue 2020-12-22 13:46:22 CET; 8min ago
     Docs: https://www.openhab.org/docs/
           https://community.openhab.org
 Main PID: 7671 (java)
    Tasks: 148 (limit: 2063)
   CGroup: /system.slice/openhab.service
           └─7671 /usr/bin/java -XX:-UsePerfData -Dopenhab.home=/usr/share/openhab -Dopenhab.conf=/etc/openhab -Dopenhab.runtime

hmm looks good, you did a reboot after zulu11 installation for sure?

Yep, did several reboots.
Also did update & dist-upgrade everything else before and after installation / migration.

I’m confused, as any other service on my RPi is running well (grafana ; pihole ; deconz / phoscon etc.)


EDIT:
oh wait … openhab just came up with initial setup.
Wow … ths took over 15 mins now.
And seems like some settings i made in 2.5 are gone.

Of course i made a backup, as it was mentioned in the upgrade tutorial.
Should i restore all settings, or will this break the new 3.0 version?

It’s now like, my rules are there, and my items also are.
But all things are gone and are now shown as “new” in the inbox.
also my location is lost and api keys for opwnweather

good to hear :muscle:
sorry, no experience with oh2-oh3 migration. I started from scratch to get rid of my unused und misconfigured stuff over the last years.

1 Like

Hi,
None of my mqtt links worked after OH3 migration. I am getting the following errors. What should I do? Can you help me please?

2020-12-22 17:18:42.580 [ERROR] [nhab.core.thing.binding.ThingFactory] - Thing factory (class org.openhab.binding.icloud.internal.ICloudHandlerFactory) returned null on create thing when it reports to support the thing type (icloud:device).

2020-12-22 17:18:42.582 [WARN ] [g.discovery.internal.PersistentInbox] - Cannot create thing. No binding found that supports creating a thing of type icloud:device.

2020-12-22 17:18:42.586 [INFO ] [g.discovery.internal.PersistentInbox] - Added new thing 'icloud:device:XXXXXXXXXXXXXXX' to inbox.

2020-12-22 17:18:43.850 [INFO ] [io.openhabcloud.internal.CloudClient] - Connected to the openHAB Cloud service (UUID = XXXXXXXXXXXXXXXXXXXXXXXXXXX, base URL = http://localhost:8080)

2020-12-22 17:19:25.879 [WARN ] [core.karaf.internal.FeatureInstaller] - The binding add-on 'mqttitude1' does not exist - ignoring it.

2020-12-22 17:19:25.883 [WARN ] [core.karaf.internal.FeatureInstaller] - The binding add-on 'mqtt1' does not exist - ignoring it.

2020-12-22 17:19:25.898 [WARN ] [core.karaf.internal.FeatureInstaller] - The misc add-on 'gcal1' does not exist - ignoring it.

2020-12-22 17:19:25.903 [WARN ] [core.karaf.internal.FeatureInstaller] - The misc add-on 'ruleengine' does not exist - ignoring it.

2020-12-22 17:19:25.910 [WARN ] [core.karaf.internal.FeatureInstaller] - The persistence add-on 'mysql' does not exist - ignoring it.

2020-12-22 17:19:25.928 [WARN ] [core.karaf.internal.FeatureInstaller] - The ui add-on 'classic' does not exist - ignoring it.

2020-12-22 17:19:25.932 [WARN ] [core.karaf.internal.FeatureInstaller] - The ui add-on 'paper' does not exist - ignoring it.

i looks like you were using mqtt version 1.x.
This is not supported in OH3 anymore. (check the forum for more details)

1 Like

Hi,
how do i upgrade mqtt. I have no idea. I would like you to be helpful.

check the new binding