updater issueshttps://gitlab.nic.cz/turris/updater/updater/-/issues2022-12-19T14:24:49+01:00https://gitlab.nic.cz/turris/updater/updater/-/issues/329Updating from Turris OS 4.0.1 to Turris OS 6.0.4 fails due to `ath10k-firmwar...2022-12-19T14:24:49+01:00Alois KlinkUpdating from Turris OS 4.0.1 to Turris OS 6.0.4 fails due to `ath10k-firmware-qca9888-ct-htt`Updating from Turris OS 4.0.1 to Turris OS 6 fails with the following error (a similar error shows in the WebUI):
```console
root@turris:~# pkgupdate
INFO:Target Turris OS: 6.0.4
WARN:There's no extra option condition for a install
line...Updating from Turris OS 4.0.1 to Turris OS 6 fails with the following error (a similar error shows in the WebUI):
```console
root@turris:~# pkgupdate
INFO:Target Turris OS: 6.0.4
WARN:There's no extra option condition for a install
line not found
line not found
line not found
ERROR:
inconsistent: Candidate exists for virtual package ath10k-firmware-qca9888-ct-htt
```
This has already been mentioned in the forums
(see https://forum.turris.cz/t/update-error-on-turrisos-4-ath10k-firmware-qca9888-ct-htt/18256
and https://forum.turris.cz/t/not-able-to-update-after-factory-reset/18033),
but since I couldn't find a GitLab issue, I thought I'd report it here too.
### Work-around
We can just flash a newer version of Turris OS, but considering that some Turris Omnias still come
with Turris OS 4 by default (and factory reset uses Turris OS 4), sometimes doing a manual update
is easier:
#### Updating to `version` 5.4.4, then back to Turris OS `branch` `hbs`
Manually updating to Turris OS 5.4.4 works:
Modifying `/etc/config/updater` to set `mode` to `version` and `version` to `5.4.4`.
```uci
config turris 'turris'
# option mode 'branch'
option mode 'version'
option version '5.4.4'
```
Then, running `pkgupdate` lets us do an update to v5.4.4:
```console
root@turris:~# pkgupdate
INFO:Target Turris OS: 5.4.4
WARN:There's no extra option condition for a install
INFO:Queue install of libgcc/core/7.5.0-2
INFO:Queue install of libc/core/1.1.24-2
INFO:Queue install of ca-certificates/base/20200601-1
INFO:Queue install of libopenssl/base/1.1.1q-1
INFO:Queue install of libexpat/packages/2.2.10-2
INFO:Queue install of libbz2/base/1.0.8-1
INFO:Queue install of libpthread/core/1.1.24-2
INFO:Queue install of liblzma/packages/5.2.5-1
INFO:Queue install of zlib/base/1.2.12
INFO:Queue install of libarchive/packages/3.4.2-1
INFO:Queue install of liburiparser/turrispackages/0.9.6-1
INFO:Queue install of ca-bundle/base/20200601-1
INFO:Queue install of libcurl/base/7.66.0-3
INFO:Queue install of libevent2/base/2.1.11-1
INFO:Queue install of liblua/base/5.1.5-3
INFO:Queue install of libubox/base/2020-05-25-66195aee-1
INFO:Queue install of libuci/base/2019-09-01-415f9e48-4
INFO:Queue install of libuci-lua/base/2019-09-01-415f9e48-4
INFO:Queue install of updater-ng/turrispackages/69.1.3-2
Press return to continue, CTRL+C to abort
<...>
```
Finally, we can undo our changes to `/etc/config/updater` by setting `mode` to `branch` and deleting the `version` key.
```uci
config turris 'turris'
option mode 'branch'
```
Then, running `pkgupdate` again worked to update us to `Target Turris OS: 6.0.4`.
```console
root@turris:~# pkgupdate
INFO:Target Turris OS: 6.0.4
INFO:Queue upgrade of libgcc/core/8.4.0-3[7.5.0-2]
INFO:Queue upgrade of libc/core/1.1.24-3[1.1.24-2]
<...>
```https://gitlab.nic.cz/turris/updater/updater/-/issues/326Updater throws instead logs updating errors2023-08-16T14:59:35+02:00Adam UhlířUpdater throws instead logs updating errorsUpdater started to fail with Stack Traceback instead of reporting the error ( "perlbase-ipc not available" ):
Running on HBL branch.
```
Updater execution failed:
Stack Traceback
===============
(1) Lua function '?' at line 57 of ch...Updater started to fail with Stack Traceback instead of reporting the error ( "perlbase-ipc not available" ):
Running on HBL branch.
```
Updater execution failed:
Stack Traceback
===============
(1) Lua function '?' at line 57 of chunk '"logging"]'
Local variables:
err = Requested package perlbase-ipc that is not available. {msg:Requested package perlbase-ipc that is not available., tp:error, reason:inconsistent (more...)}
err2string = Lua function '?' (defined at line 38 of chunk "logging"])
msg = string: "\
inconsistent: Requested package perlbase-ipc that is not available."
(*temporary) = table: 0x51cb080 {msg:
inconsistent: Requested package perlbase-ipc that is not available. (more...)}
(2) C function 'function: 0x238e360'
(3) upvalue C function 'error'
(4) Lua local 'pkg_plan' at line 358 of chunk '"planner"]'
Local variables:
plan_pkg = table: 0x273a430 {tp:package, name:perlbase-ipc, final:table: 0x3878550}
ignore_missing = boolean: false
ignore_missing_pkg = boolean: false
only_version = nil
parent_str = string: "Requested package"
name = string: "perlbase-ipc"
missing_pkg = number: 608
(5) Lua function '?' at line 470 of chunk '"planner"]'
Local variables:
pkgs = table: 0x235f560 {luci-i18n-cshark-he:table: 0x2dc1540, kmod-video-gspca-vc032x:table: 0x3b1ce60 (more...)}
requests = table: 0x2369890 {1:table: 0x3953240, 2:table: 0x3954950, 3:table: 0x3954d80, 4:table: 0x3955280 (more...)}
sat = userdata: 0x45ceb38
satmap = table: 0x45c86b0 {pkgs:table: 0x235f560, pkg2sat:table: 0x45c78d0, sat:userdata: 0x45ceb38 (more...)}
plan = table: 0x5095df0 {1:table: 0x517d360, 2:table: 0x517d330, 3:table: 0x517d510, 4:table: 0x517d8c0 (more...)}
planned = table: 0x5095e20 {kmod-usb-storage-uas:8, libevent2:57, libc:2, liblua:46, kmod-lib-zlib-deflate:90 (more...)}
wstack = table: 0x5095e50 {}
inwstack = table: 0x5095e80 {}
inconsistent = table: 0x5095eb0 {}
missing_dep = table: 0x5095ee0 {}
pkg_plan = Lua function '?' (defined at line 345 of chunk "planner"])
(for generator) = C function: 0xb6f226a0
(for state) = table: 0x2369890 {1:table: 0x3953240, 2:table: 0x3954950, 3:table: 0x3954d80, 4:table: 0x3955280 (more...)}
(for control) = number: 37
_ = number: 37
req = table: 0x2430f10 {package:table: 0x273a430, priority:50, tp:install}
(6) tail call
Local variables:
(*temporary) = C function: 0x238e360
(7) tail call
Local variables:
(*temporary) = C function: 0x238e360
(8) Lua function '?' at line 71 of chunk '"updater"]'
Local variables:
entrypoint = string: "file:///etc/updater/conf.lua"
```Turris OS 6.0Michal HruseckyMichal Hruseckyhttps://gitlab.nic.cz/turris/updater/updater/-/issues/325Approvals does not require manual confirmation2023-08-16T14:59:40+02:00Josef SchlehoferApprovals does not require manual confirmationOn Turris 1.1 router, I'm using Approvals.
```
root@turris:~# uci export updater
package updater
config turris 'turris'
option mode 'branch'
option branch 'hbl'
config l10n 'l10n'
list langs 'cs'
config autorun 'autorun'
option e...On Turris 1.1 router, I'm using Approvals.
```
root@turris:~# uci export updater
package updater
config turris 'turris'
option mode 'branch'
option branch 'hbl'
config l10n 'l10n'
list langs 'cs'
config autorun 'autorun'
option enable '1'
option approvals '1'
```
And it seems that Approvals are not necessary since the update is installed anyway.
I got two notifications today:
- 5.28 am:
```
Update notifications
====================
Your approval is required to apply pending updates. You can grant it in the Foris administrative interface in the 'Updater' menu.
• Install libnetfilter-log 1.0.2-1
```
- 6.21 am:
```
Update notifications
====================
Changes performed by updater at 2022-03-18T05:21:23+00:00
• Updated package libnetfilter-log from version 1.0.1-3 to version 1.0.2-1
```
If you need some logs, please let me know, I will be gladly to help.Turris OS 6.0https://gitlab.nic.cz/turris/updater/updater/-/issues/322Update from TOS 4.0.1 to 5.2.3 fails to finish2021-07-27T20:48:58+02:00Stepan RechnerUpdate from TOS 4.0.1 to 5.2.3 fails to finish# Summary
After an update from TOS 4.0.1, no UI is available. Web UI is unavailable, SSH refused. Reported on support (ticket 1361041: [turris nepřístupný přes web po akualizaci](https://rt.nic.cz/Ticket/Display.html?id=1361041), reprodu...# Summary
After an update from TOS 4.0.1, no UI is available. Web UI is unavailable, SSH refused. Reported on support (ticket 1361041: [turris nepřístupný přes web po akualizaci](https://rt.nic.cz/Ticket/Display.html?id=1361041), reproduced on Omnia.
# Steps To Reproduce
1. Re-flash Turris Omnia with Turris OS 4.0.1
2. Finish the first setting guide
3. Let the updater work
# Expected Result
Turris OS updates to the current version, and an automatic restart is set. After a restart, the current version is fully initialized.
# Actual Result
A restart of the router is triggered during an update and the update ends unfinished. After the reboot, DHCP and access to the Internet via Ethernet works, router UIs are not accessible, Wi-Fi is off. Only a pre-update snapshot is created, not a post-update. `pkgupdate` via a serial connection helps.https://gitlab.nic.cz/turris/updater/updater/-/issues/320File hashes are now stored in `files-sha256sum` control file instead of `file...2022-02-16T16:40:58+01:00Karel KociFile hashes are now stored in `files-sha256sum` control file instead of `files-sha256`https://gitlab.nic.cz/turris/updater/updater/-/issues/319Updater hangs waiting for zombie process2021-10-15T12:02:45+02:00Vojtech MyslivecUpdater hangs waiting for zombie processRunning `pkgupdate` interactively to upgrade from TOS 5.1.8 to TOS 5.2.1 and the updater hangs waiting for zombie process while running `mwan` postinstall script:
![Screenshot_from_2021-06-15_17-37-51](/uploads/c1bb5ff671ed4494a1933ae2e...Running `pkgupdate` interactively to upgrade from TOS 5.1.8 to TOS 5.2.1 and the updater hangs waiting for zombie process while running `mwan` postinstall script:
![Screenshot_from_2021-06-15_17-37-51](/uploads/c1bb5ff671ed4494a1933ae2e30b2763/Screenshot_from_2021-06-15_17-37-51.png)
It recovers itself somehow after several minutes but it takes too long in interactive mode IMO. Also, this happened to me several times already. I guess it's `mwan` package every time...
<details>
<summary>pkgupdate console log</summary>
```
root@factory02: ~ # pkgupdate
INFO:Target Turris OS: 5.2.1
INFO:Queue install of kernel/core/4.14.232-1-67f70e2f39f8e8859c56d42cced0b0b3
...
INFO:Queue install of luci-i18n-mwan3-en/luci/git-21.132.36199-d0cf6e4-1
...
INFO:Queue install of kmod-sit/core/4.14.232-1-67f70e2f39f8e8859c56d42cced0b0b3
INFO:Queue removal of dhparam
...
INFO:Queue removal of luasec
Press return to continue, CTRL+C to abort
INFO:Downloading packages
INFO:Executing preupdate hook: 05_schnapps.sh
Snapshot number 55 created
INFO:Unpacking download packages
INFO:Checking for file collisions between packages
INFO:Running pre-install and pre-rm scripts and merging packages to root file system
WARN:Config file /etc/config/openvpn modified by the user. Backing up the new one into /etc/config/openvpn-opkg
...
WARN:Config file /etc/mwan3.user modified by the user. Backing up the new one into /etc/mwan3.user-opkg
...
WARN:Config file /etc/config/foris modified by the user. Backing up the new one into /etc/config/foris-opkg
INFO:Running prerm of dhparam
...
INFO:Running prerm of luasec
INFO:Removing packages and leftover files
INFO:Running post-install and post-rm scripts
INFO:Running postinst of kernel
...
INFO:Running postinst of kmod-ipt-ipset
INFO:Running postinst of mwan3
...
<several minutes>
...
ip: invalid argument '0x3d00/0x3F00' to 'fwmark'
ip: invalid argument '0x3e00/0x3F00' to 'fwmark'
ip: invalid argument '0x3d00/0x3F00' to 'fwmark'
ip: invalid argument '0x3e00/0x3F00' to 'fwmark'
ip: invalid argument '0x100/0x3F00' to 'fwmark'
ip: invalid argument '0x3d00/0x3F00' to 'fwmark'
ip: invalid argument '0x3e00/0x3F00' to 'fwmark'
ip: invalid argument '0x3d00/0x3F00' to 'fwmark'
ip: invalid argument '0x3e00/0x3F00' to 'fwmark'
ip: invalid argument '0x200/0x3F00' to 'fwmark'
INFO:Running postinst of luci-compat
...
```
</details>https://gitlab.nic.cz/turris/updater/updater/-/issues/318Unify format of notifications2021-06-03T21:20:13+02:00Vojtech MyslivecUnify format of notificationsUnify format and appearance of Turris notifications with the changelog:
![Screenshot_from_2021-05-31_22-17-41](/uploads/43b28e784207d4701d41eec2cadc716d/Screenshot_from_2021-05-31_22-17-41.png)Unify format and appearance of Turris notifications with the changelog:
![Screenshot_from_2021-05-31_22-17-41](/uploads/43b28e784207d4701d41eec2cadc716d/Screenshot_from_2021-05-31_22-17-41.png)https://gitlab.nic.cz/turris/updater/updater/-/issues/317Updater throws errors regarding transaction - upgraded_packages2021-04-15T18:37:41+02:00Josef SchlehoferUpdater throws errors regarding transaction - upgraded_packages```
Updater failed:
[string "transaction"]:327: [string "transaction"]:238: attempt to index local 'upgraded_packages' (a nil value)
```
Reported on our forum:
https://forum.turris.cz/t/turris-os-5-2-0-is-in-hbt-testing-branch/15081/7...```
Updater failed:
[string "transaction"]:327: [string "transaction"]:238: attempt to index local 'upgraded_packages' (a nil value)
```
Reported on our forum:
https://forum.turris.cz/t/turris-os-5-2-0-is-in-hbt-testing-branch/15081/7?u=pepehttps://gitlab.nic.cz/turris/updater/updater/-/issues/316Newly installed packages configuration scripts are run as they would be an up...2021-05-27T10:22:40+02:00Karel KociNewly installed packages configuration scripts are run as they would be an upgradeDue to error in detection if package is already installed the configure step of package is always run with environment variable `PKG_UPGRADE=1`.
The effects are:
* No automatic service enable and thus not service is started
* Some other...Due to error in detection if package is already installed the configure step of package is always run with environment variable `PKG_UPGRADE=1`.
The effects are:
* No automatic service enable and thus not service is started
* Some other packages using this variable installed in running system might not be set properly.
This was introduced by turris/updater/updater!268 (f099f89de4eebdd610ffe155da1298da752ddbdf)https://gitlab.nic.cz/turris/updater/updater/-/issues/3154 days after update (v3 -> v5) WAN port was disabled.2021-03-16T13:56:50+01:00omichalek4 days after update (v3 -> v5) WAN port was disabled.OS version 5.1.10, I ran the migration tool from version 3 4 days ago.
I use DSL router in bridge mode to connect to the Internet. I never used an SFP module (never even held in my hand :).
Today after one restart while configuring Om...OS version 5.1.10, I ran the migration tool from version 3 4 days ago.
I use DSL router in bridge mode to connect to the Internet. I never used an SFP module (never even held in my hand :).
Today after one restart while configuring Omnia my network went offline. I do not have a clue why.
I noticed then that the WAN interface in Luci did not have a device/interface assigned. Also, the WAN LED was lit regardless of whether the cable was plugged in or not. After following up on the information that [WAN port name was changed to "eth2"](https://docs.turris.cz/hw/omnia/omnia/), I found a suspect:
```
root@turris:~# ls -l /boot
-rw-r--r-- 1 root root 18773 Mar 4 01:25 armada-385-turris-omnia-phy.dtb
-rw-r--r-- 1 root root 18809 Mar 4 01:25 armada-385-turris-omnia-sfp.dtb
-rw-r--r-- 1 root root 1199 Mar 4 01:25 boot.scr
lrwxrwxrwx 1 root root 31 Mar 14 17:56 dtb -> armada-385-turris-omnia-sfp.dtb
-rwxr-xr-x 1 root root 3351944 Mar 4 01:25 zImage
```
this fixed it:
```
root@turris:~# ln -sf armada-385-turris-omnia-phy.dtb /boot/dtb
root@turris:~# ls -l /boot
-rw-r--r-- 1 root root 18773 Mar 4 01:25 armada-385-turris-omnia-phy.dtb
-rw-r--r-- 1 root root 18809 Mar 4 01:25 armada-385-turris-omnia-sfp.dtb
-rw-r--r-- 1 root root 1199 Mar 4 01:25 boot.scr
lrwxrwxrwx 1 root root 31 Mar 14 19:30 dtb -> armada-385-turris-omnia-phy.dtb
-rwxr-xr-x 1 root root 3351944 Mar 4 01:25 zImage
```
I think there must have been at least few other reboots before the incident but I am not 100% sure.
Earlier today I did change wifi setting as well as used the "Reset Wi-Fi Settings" button in reForis, I aso launched few migrated LXC containers for the first time.
Please let me know if I can provide any useful information.https://gitlab.nic.cz/turris/updater/updater/-/issues/313Add FilesSignature2021-06-11T08:24:02+02:00Karel KociAdd FilesSignature`FilesSignature` should be same extension as `LinkSignature` but assembled from list of files.
Originally I thought that we do not need this but it turns out that sometimes patches do not bump version but add/remove files. This can caus...`FilesSignature` should be same extension as `LinkSignature` but assembled from list of files.
Originally I thought that we do not need this but it turns out that sometimes patches do not bump version but add/remove files. This can cause collision but only in existing installations. This can be in the end pretty hard to detect. We should cover this even when this does not happen so often because of that.https://gitlab.nic.cz/turris/updater/updater/-/issues/311Compare of dependencies triggers reinstall after opkg usage2022-02-16T16:41:01+01:00Karel KociCompare of dependencies triggers reinstall after opkg usageOpkg sanitizes dependencies and that introduces inconsistency in string comparison. We should probably not compare dependencies as strings but rather in some other way.
This is considered as mirror bug as it triggers only once after opk...Opkg sanitizes dependencies and that introduces inconsistency in string comparison. We should probably not compare dependencies as strings but rather in some other way.
This is considered as mirror bug as it triggers only once after opkg usage and not after that.https://gitlab.nic.cz/turris/updater/updater/-/issues/310Colliding binaries missing after TOS 3->5 upgrade2020-11-12T14:23:38+01:00David HopfmuellerColliding binaries missing after TOS 3->5 upgradeWhile upgrading from TOS 3.11.19.1 to 5.1.3 pkgupdate warned about several collisions:
```
WARN:Collision with existing path. Moving //usr/bin/ssh to /usr/share/updater/collided/usr/bin
WARN:Collision with existing path. Moving //usr/bin...While upgrading from TOS 3.11.19.1 to 5.1.3 pkgupdate warned about several collisions:
```
WARN:Collision with existing path. Moving //usr/bin/ssh to /usr/share/updater/collided/usr/bin
WARN:Collision with existing path. Moving //usr/bin/scp to /usr/share/updater/collided/usr/bin
WARN:Collision with existing path. Moving //usr/bin/cmp to /usr/share/updater/collided/usr/bin
WARN:Collision with existing path. Moving //usr/bin/diff to /usr/share/updater/collided/usr/bin
```
Once the upgrade concluded, these four executables are now missing in `/usr/bin`.https://gitlab.nic.cz/turris/updater/updater/-/issues/309wget missing after TOS 3->5 upgrade2021-05-26T19:58:17+02:00David Hopfmuellerwget missing after TOS 3->5 upgrade```
root@router:~# cat /etc/turris-version
3.11.19.1
root@router:~# opkg list-installed | grep wget
wget - 1.20.3-1
root@router:~#
```
After installing the tos3to4 package and initiating `pkgupdate` it does `INFO:Queue removal of wget` ...```
root@router:~# cat /etc/turris-version
3.11.19.1
root@router:~# opkg list-installed | grep wget
wget - 1.20.3-1
root@router:~#
```
After installing the tos3to4 package and initiating `pkgupdate` it does `INFO:Queue removal of wget` but never reinstalls it. As such, it leaves TOS 5.1.3 in a broken state without any chance to self-recover through updates.
Please let me know if you need any additional information, I can go back and forth between snapshots if required.https://gitlab.nic.cz/turris/updater/updater/-/issues/308Remove log files and provide info instead to hooks2021-10-06T15:11:42+02:00Karel KociRemove log files and provide info instead to hooksWe have preinstall and postinstall hooks. We can use that to replace task log files if we pass all required info to those hooks.We have preinstall and postinstall hooks. We can use that to replace task log files if we pass all required info to those hooks.https://gitlab.nic.cz/turris/updater/updater/-/issues/307Create notification is in compatible mode2023-08-16T14:59:49+02:00Josef SchlehoferCreate notification is in compatible modeThis script here: https://gitlab.nic.cz/turris/updater/updater/-/blob/master/src/pkgupdate/hook_reboot_required/50-create-notification.sh#L5 throws up warning during update:
`create_notification: Warning: Running in compatible mode! Use...This script here: https://gitlab.nic.cz/turris/updater/updater/-/blob/master/src/pkgupdate/hook_reboot_required/50-create-notification.sh#L5 throws up warning during update:
`create_notification: Warning: Running in compatible mode! Use of cs message is obsoleted.`Turris OS 5.2.0https://gitlab.nic.cz/turris/updater/updater/-/issues/305Configuration file overwritten when moved between packages2020-09-22T14:00:11+02:00Karel KociConfiguration file overwritten when moved between packagesMoving configuration file from one package to another causes it to be overwritten by new version in new package. This should not happen as moving configuration files between packages is pretty common and we should not just nuke user's co...Moving configuration file from one package to another causes it to be overwritten by new version in new package. This should not happen as moving configuration files between packages is pretty common and we should not just nuke user's configuration in such situation.https://gitlab.nic.cz/turris/updater/updater/-/issues/304Missing configure check on uthash2020-08-04T16:03:53+02:00Michal HruseckyMissing configure check on uthashuthash is required by updater, but is not checked for by updater.uthash is required by updater, but is not checked for by updater.https://gitlab.nic.cz/turris/updater/updater/-/issues/303Libupdater is not versioned (it has version 0.0.0)2020-09-22T15:11:32+02:00Karel KociLibupdater is not versioned (it has version 0.0.0)We should add library version to libupdater.so.We should add library version to libupdater.so.https://gitlab.nic.cz/turris/updater/updater/-/issues/300Detect broken Internet connection2023-08-16T14:59:54+02:00Vojtech MyslivecDetect broken Internet connectionWhen a WAN is down and Internet connection is not available, updater "spam" Foris notifications with:
```
unreachable: https://repo.turris.cz/omnia/lists/base.lua: Couldn't resolve host 'repo.turris.cz'
```
which is a bit cryptic, espec...When a WAN is down and Internet connection is not available, updater "spam" Foris notifications with:
```
unreachable: https://repo.turris.cz/omnia/lists/base.lua: Couldn't resolve host 'repo.turris.cz'
```
which is a bit cryptic, especially for new Turris users.
It would be really nice to enhance user experience and lower "false issues" [like that](https://forum.turris.cz/t/nemohu-resolvovat-repo-turris-cz/12907) (that's really not unique).Turris OS 5.1