erik@MinipcLG2:~$ sudo apt held
openhab
openhab-addons
But without my explicit intervention, openHAB did upgrade to 5.1.1…
Does anyone have an idea how that’s possible?
erik@MinipcLG2:~$ sudo apt held
openhab
openhab-addons
But without my explicit intervention, openHAB did upgrade to 5.1.1…
Does anyone have an idea how that’s possible?
Is that the right command? I thought it was sudo apt-mark hold , unhold and showhold. But I’m not an expert
Yes yours are the right cmds.
And it depends on the way you have setup your Linux (@ErikDB didn’t tell).
Strictly speaking this is not even an OH question.
I agree, but I hope it’s still allowed ![]()
erik@MinipcLG2:~$ sudo apt-mark showhold
openhab
openhab-addons
Which part of the setup do you mean?
All of it, you did not say anything about it.
You’re basically saying that apt does not work on your system because although you have locked the openhab packages, it upgrades.
No idea what would cause that, would require an in-depth investigation.
Are you using openHABian and its menu to upgrade?
Then you must not use apt at the same time. openHABian also uses hold/unhold to upgrade so possibly invalidates your locking. Enable debugging and interactively see for yourself.
Sure, but I’m not sure what qualifies. Does this:
erik@MinipcLG2:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Linuxmint
Description: Linux Mint 22.2
Release: 22.2
Codename: zara
?
I’m not sure how, since the upgrade already happened…?
So are you using openHABian?
No. I expected the Linux Mint data to point that out?
No, openHABian you can install on top of any Debian.
So it’s effectively this. You need a Linux expert with access to your box. Guess there’s only yourself available to accomplish that, sorry.
In my opinion, a better way to tell APT whether and, above all, to which version it is allowed to update is via the preferences. In the following example, I allow all versions within version 5, but no update to version 6 (“Pin: version 5.1.*” will only allow updates within version 5.1).
oh@openhab:~# cat /etc/apt/preferences.d/openhab
Package: openhab
Pin: version 5.*
Pin-Priority: 1001
oh@openhab:~# cat /etc/apt/preferences.d/openhab-addons
Package: openhab-addons
Pin: version 5.*
Pin-Priority: 1001
This way, you can ensure that you receive security updates, for example, but prevent automatic updates (e.g., via unattended upgrades) to the next major version.
More information: apt_preferences - Preference control file for APT
Huaba
An interesting possibility, but I don’t want those upgrades to happen automatically either…