openHAB 2.5.x Patch Releases

I have tried to update from 2.5.0 to 2.5.1-2 on RPi4 on Fedora31 and I’m observing the following error during update:

error: unpacking of archive failed on file /var/lib/openhab2/tmp/README: cpio: chown
    error: openhab2-0:2.5.1-2.noarch: install failed

A full log (please ignore the everything related to mosquitto - it has no impact on openhab2 installation):
$ sudo dnf update
[sudo] password for dw:
Last metadata expiration check: 1:13:29 ago on Mon 13 Jan 2020 09:46:01 CET.
Dependencies resolved.

 Problem: package mosquitto-1.6.8-1.fc30.armv7hl requires libwebsockets.so.14, but none of the providers can be installed
  - cannot install both libwebsockets-3.2.1-1.fc30.armv7hl and libwebsockets-3.1.0-2.fc30.armv7hl
  - cannot install both libwebsockets-3.1.0-2.fc30.armv7hl and libwebsockets-3.2.1-1.fc30.armv7hl
  - cannot install the best update candidate for package mosquitto-1.6.8-1.fc30.armv7hl
  - cannot install the best update candidate for package libwebsockets-3.1.0-2.fc30.armv7hl
==============================================================================================================================================================================================================================================
 Package                                                     Architecture                                        Version                                                     Repository                                                  Size
==============================================================================================================================================================================================================================================
Upgrading:
 openhab2                                                    noarch                                              2.5.1-2                                                     openHAB-Stable                                              79 M
 openhab2-addons                                             noarch                                              2.5.1-2                                                     openHAB-Stable                                             181 M
Skipping packages with conflicts:
(add '--best --allowerasing' to command line to force their upgrade):
 libwebsockets                                               armv7hl                                             3.2.1-1.fc30                                                updates                                                    197 k

Transaction Summary
==============================================================================================================================================================================================================================================
Upgrade  2 Packages
Skip     1 Package

Total download size: 261 M
Is this ok [y/N]: y
Downloading Packages:
(1/2): openhab2-2.5.1-2.noarch.rpm                                                                                                                                                                            3.8 MB/s |  79 MB     00:21    
(2/2): openhab2-addons-2.5.1-2.noarch.rpm                                                                                                                                                                     5.8 MB/s | 181 MB     00:31    
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                                                                                         8.3 MB/s | 261 MB     00:31     
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Running scriptlet: openhab2-2.5.1-2.noarch                                                                                                                                                                                              1/1 
  Running scriptlet: openhab2-addons-2.5.1-2.noarch                                                                                                                                                                                       1/1 
  Preparing        :                                                                                                                                                                                                                      1/1 
  Running scriptlet: openhab2-2.5.1-2.noarch                                                                                                                                                                                              1/1 
  Running scriptlet: openhab2-2.5.1-2.noarch                                                                                                                                                                                              1/4 
  Upgrading        : openhab2-2.5.1-2.noarch                                                                                                                                                                                              1/4 
Error unpacking rpm package openhab2-2.5.1-2.noarch
  Running scriptlet: openhab2-addons-2.5.1-2.noarch                                                                                                                                                                                       2/4 
error: unpacking of archive failed on file /var/lib/openhab2/tmp/README: cpio: chown
error: openhab2-0:2.5.1-2.noarch: install failed

  Upgrading        : openhab2-addons-2.5.1-2.noarch                                                                                                                                                                                       2/4 
  Running scriptlet: openhab2-addons-2.5.1-2.noarch                                                                                                                                                                                       2/4 
  Running scriptlet: openhab2-addons-2.5.0-1.noarch                                                                                                                                                                                       3/4 
  Cleanup          : openhab2-addons-2.5.0-1.noarch                                                                                                                                                                                       3/4 
warning: file /usr/share/openhab2/addons/openhab-addons-2.5.0.kar: remove failed: No such file or directory

  Running scriptlet: openhab2-addons-2.5.0-1.noarch                                                                                                                                                                                       3/4 
  Running scriptlet: openhab2-2.5.0-1.noarch                                                                                                                                                                                              4/4 
  Cleanup          : openhab2-2.5.0-1.noarch                                                                                                                                                                                              4/4 
  Running scriptlet: openhab2-2.5.0-1.noarch                                                                                                                                                                                              4/4 
  Running scriptlet: openhab2-addons-2.5.1-2.noarch                                                                                                                                                                                       4/4 
  Running scriptlet: openhab2-2.5.0-1.noarch                                                                                                                                                                                              4/4 
  Verifying        : openhab2-2.5.1-2.noarch                                                                                                                                                                                              1/4 
  Verifying        : openhab2-2.5.0-1.noarch                                                                                                                                                                                              2/4 
  Verifying        : openhab2-addons-2.5.1-2.noarch                                                                                                                                                                                       3/4 
  Verifying        : openhab2-addons-2.5.0-1.noarch                                                                                                                                                                                       4/4 

Upgraded:
  openhab2-addons-2.5.1-2.noarch                                                                                                                                                                                                              

Skipped:
  libwebsockets-3.2.1-1.fc30.armv7hl                                                                                                                                                                                                          

Failed:
  openhab2-2.5.1-2.noarch                                                                                                                                                                                                                     

Error: Transaction failed

Interestingly, the same error happened earlier, when I tried to update from 2.4.0 to 2.5.0 using dnf, (I had to update it manually using rpm).

Same for me.

Then, I reported it directly to github as https://github.com/openhab/openhab-linuxpkg/issues/154

It seems the linux repo metadata was somehow screwed up - I have rebuilt it and now it seems to be there:

➜  curl -L "https://dl.bintray.com/openhab/apt-repo2/dists/stable/main/binary-amd64/Packages" | grep " 2.5"
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 11876  100 11876    0     0  81342      0 --:--:-- --:--:-- --:--:-- 81342
Version: 2.5.0-1
Version: 2.5.1-1
Version: 2.5.0-1
Version: 2.5.1-1
Version: 2.5.0-1
Version: 2.5.1-1
1 Like

@Kai

hi, yes now 2.5.1-1 is there, but shouldn’t it be 2.5.1-2?

apt-cache madison openhab2
openhab2 | 2.5.1-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.5.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.4.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.3.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.2.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.1.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.0.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages

I had the exact same problem and it worked fine on a second attempt. I’ve had it happen to me many times in the past for upgrades between 2.4 and 2.5 milestones, but not consistently. I can’t find the consistency in this issue, so it’s challenging to report the bug. I’ve done a lot of RPM work for other projects over the past 20 years, and I’ve never seen it with anything else (other than when I had an RPM that didn’t pass checksum tests).

Which version did you install 2.5.1-1 or 2.5.1-2 ?
(I only get offered 2.5.1-1 )

Hi all, it doesn’t look like APT’s 2.5.1-2 made it to Bintray.

I’m looking into it now and I’ll sort it out as soon as I can.

I was offered 2.5.1-2, and I have it successfully installed and
working as expected (although it took two attempts due to the cpio
error that was logged in github. That cpio problem has been happening
for a long time, but I can’t determine the consistency to it (it
doesn’t happen every time, just many times).

As a note, stable releases get pushed to every repo, so those using the unstable and testing repositories will be able to see 2.5.1-2 but those using only the stable (ironic, I know) repositories cannot.

I think I’ve found the cause of the issue but will let you know when this is available on the stable repo again.

@Benjy I had removed 2.5.1 from Bintray and republished it - therefore only 2.5.1-1 exists. Imho everything should just be fine (and yes, on testing there is still a 2.5.1-2, which is identical, very sorry for the mess…).

After sudo apt-get update now both versions are shown:
apt-cache madison openhab2
openhab2 | 2.5.1-2 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.5.1-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.5.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.4.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.3.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.2.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.1.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages
openhab2 | 2.0.0-1 | https://dl.bintray.com/openhab/apt-repo2 stable/main armhf Packages

Could i upgrade now?

No worries @kai.

Yes, I’ve distributed 2.5.1-2 to Bintray and this is available for everyone to upgrade to. I thought it best to publish 2.5.1-2 so that we can guarantee everyone has a working version. If we come into space issues on Bintray again, then we can remove 2.5.1-1.

It seems the linux repo metadata was somehow screwed up

This was an issue with the release job using a different username to the one bintray expects for metadata calculation. This has also been fixed for the next releases (of openhab2-addons).

1 Like

@Kai @J-N-K I have found a problem.

Previously working rules (doesn’t matter if it’s DSL or JSR) behave strangely on the MQTT binding (I have only found it in Dimmer type).
Sending a command to the Dimmer item (for example 70 (%)) will only send 7. Controlling the value from sitemap is correct.
The outgoing value transform is active in this case, I have this (int) value sent as “%s”. However it works as before from sitemap, so I don’t know what changed and what is causing this…

This looks weird… (I have sent a 70 command):

2020-01-13 18:12:31.303 [ome.event.ItemCommandEvent] - Item 'Living_Room_Floor_Lamp_Brightness' received command 70

2020-01-13 18:12:31.305 [.event.RuleStatusInfoEvent] - a0923642-287f-4a3d-be1d-0e26c7e9eedf updated: IDLE

2020-01-13 18:12:31.470 [nt.ItemStatePredictedEvent] - Living_Room_Floor_Lamp_Brightness predicted to become 70

2020-01-13 18:12:31.518 [vent.ItemStateChangedEvent] - Living_Room_Floor_Lamp_Brightness changed from 85 to 70

2020-01-13 18:12:31.520 [vent.ItemStateChangedEvent] - Living_Room_Floor_Lamp_Brightness changed from 70 to 7

So it sends the 70 value but somehow it changes to 7…

Sending the same command from console, the same result…

Sniffing the output from MQTT, this is sent at 70 value:

"brightness": 7E+1

So openHAB recognizes the value in this normalized format but the device not (that’s why its bouncing the state at 70 and then 7).

The problem was caused by this:

And I could solve it by using “%.0f” instead of “%s”.

Update to 2.5.1-2 worked with openhabian-config function.
Had done a sudo apt-get update before to refresh repos.
After Upgrade I had to clean cache and I rebooted twice.
Now everything should work as expected

$OPENHAB_RUNTIME/bin/client -p habopen
Logging in as openhab
2.5.1
Release Build

versio.properties:
openHAB Distribution Version Information
----------------------------------------
build-no : Release Build
online-repo : JFrog

Repository        Version
----------------------------------------
openhab-distro  : 2.5.1
openhab-core    : 2.5.0
openhab1-addons : 1.14.0
openhab2-addons : 2.5.1
karaf           : 4.2.7
Information at openhabian Login Screen:
openHAB 2.5.1-2 (Release Build)
1 Like

Excellent, what a relief :sweat_smile: .

:smiley:

Please open an issue on github. This is a bug.

Here it is:

2 Likes

The onyl message I get frequently is, but don’t know what it means…:

2020-01-13 19:18:28.227 [WARN ] [me.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.eclipse.smarthome.core.thing.i
nternal.CommunicationManager@1ea10ed' takes more than 5000ms.