Optional migration from Turris OS 3.x for advanced users

I ran into the same problem as @jklass with the updater not being able to read /usr/share/updater/localrepo/auto/Packages. I did:

# touch /usr/share/updater/localrepo/auto/Packages

and that seemed to unstuck the process and I ended up with Turris 5.0 after a few minutes. I also started from Turris 3.11.17. And I do not remember messing with that location.

Seems like a simpler fix that factory reset, etc.

After some mis-adventures this morning since it decided to try updating again (because the 2 LED restore decided I should use the post-update snapshot) I got a schnapps restore I feel I can trust not to try updating on me, which is the post install after updating to 3.11.17.

# find /usr/share/updater/localrepo/
/usr/share/updater/localrepo/
/usr/share/updater/localrepo/auto
/usr/share/updater/localrepo/auto/luci-app-access-control_0.4.1.ipk
/usr/share/updater/localrepo/auto/Packages.gz
/usr/share/updater/localrepo/auto/luci-app-radius_0.1-1.ipk
/usr/share/updater/localrepo/auto/adblock_3.5.4-2.ipk
/usr/share/updater/localrepo/localrepo.lua

This was entirely there from before the attempted upgrade (in my current snapshot). Should I remove /usr/share/updater/localrepo? The upgrade doc just mentions that this will be blown away, which I’m fine with (I have backups and/or can recreate as needed).

Ah, OK. I can give that a shot.

[edit] I tried that and it’s just sitting there. Did you touch the file before the upgrade?
[edit2] I schnapps restored again and touched the file before I started the upgrade and it completed. - Yay, Turris 5.0

@jklaas I see where is the problem. Hmm all right. I am going to fix that. Anyway removing /usr/share/updater/localrepo is all right as fix for now.

1 Like

Please add knot-dig

1 Like

yeah, common and explained, so you have to dig for it.
Just FYI: Provides with Conflicts are incorrectly reported as in cyclic dependency

1 Like

Thanks to migration to be pointed in Turris OS 3.x still to HBK the Turris 1.x migration should be possible now.

Fix for LXC migration should be up once Turris OS 5.0.1 is released to HBS (script just wasn’t included, my fault). It is already available If you migrate from nightly as it is in HBK already.

@cynerd:

If reading from STDIN is not your plan, this patch should be applied
--- lxc.orig	2020-06-09 04:58:22.000000000 +0200
+++ lxc	2020-06-09 12:43:57.000000000 +0200
@@ -7,7 +7,7 @@
 		echo "Config is detected as migrated: $conf" >&2
 		return
 	fi
-	if [ "$(grep -c '^lxc\.network\.type')" -gt 1 ]; then
+	if [ $(grep -c '^lxc\.network\.type' "$conf") -gt 1 ]; then
 		create_notification -s error \
 			"Automatic migration of LXC failed: Unable to migrate configuration with multiple network sections: $conf"
 		echo "Unable to migrate configuration with multiple network sections: $conf" >&2
1 Like

Thank you for noticing that. It should not cause any problems during update with exception that it won’t stop LXC config migration of multiple networks are found in config. Updater runs these script with closed stdin if I remember correctly. In manual execution that causes problem that is true.
It should be fixed now in master and should be part of future fixup release (5.0.1 or 5.0.2).

Hi there, I did try to update my Turris Omnia from 3 to 5, which in general worked ok with the known caveats (LXC-Container with multiple Interfaces, and freeradius 2 to 3 Config Changes etc…) but at the moment there is one thing blocking the usability for me:

I have several VLANs running, and most importantly a trunk port for the vlans on LAN1. The Migration seemingly did migrate this more or less as expected, (meaning, it puts lan1.vlanid interfaces into the respective bridges) but it does not work. I can’t reach anything on the other side of the trunk. Is this supposed to be a supported migration, or are there any additional steps / manual changes necessary to get this working?

As the Omnia is my main Router and my Network doesn’t work without the trunk port I did rollback to Version 3 for the time being (fortunately this works as expected).

Can you please pm me old network configuration and migrated one? You can get 3.x one directly and migrated one can be received by mounting rollback snapshot. That is /etc/config/network file.

I followed the migration steps logged in as root via ssh shell:
opkg-cl update
opkg-cl install tos3to4
updater-supervisor -d
After reboot I had to reassign my WAN under the Interfaces menu but my switch and lan ports are no longer available. Wifi is fine. Does anyone have a default /etc/config/network file for 5.x they can post the contents I may reference to make my switch and wired lan operational again?

Thanks

So I bit the bullet and pulled the trigger to update my TO to 5.
Script seemed to go fine, email notifications as timing, I think I kicked off around 16:35 (“Updater approvals were deactivated to prevent problems during migration to latest major release of Turris OS!” email).
Received the updates applied email around 16:54
Now on:
:: TurrisOS 5.0.1 :: TurrisOS 5.0.1 e752fc1ff9d1d4f50a32155dd714dcde4b070bd4 :: 5.0.1.e752fc1ff9 ::

I don’t have LXC yet which caused some problems as I use pihole on a LXC so need to workout how to get that running again.
I needed to power off and back on again to get the full network up (wifi didn’t work)
I am receiving an error on the LXC page thus:

If I click the login button and login, it cycles back to the same message and I have to log in again, sometimes after the second login I get a text screen saying that there is a corrupt file.
“/usr/lib/lua/luci/dispatcher.lua:426: /etc/config/luci seems to be corrupt, unable to find section ‘main’”

Here you go, this is my 5.0 network file:

config interface 'loopback'
	option proto 'static'
	option ipaddr '127.0.0.1'
	option netmask '255.0.0.0'
	option ifname 'lo'

config globals 'globals'
	option ula_prefix 'fd47:9f75:add1::/48'

config interface 'lan'
	option force_link '1'
	option type 'bridge'
	option proto 'static'
	option ipaddr '192.168.1.1'
	option netmask '255.255.255.0'
	option ip6assign '60'
	option _orig_ifname 'eth0 eth2 wlan0 wlan1'
	option _orig_bridge 'true'
	option mtu '1492'
	option igmp_snooping '0'
	option delegate '0'
	option _turris_mode 'managed'
	list ifname 'lan0'
	list ifname 'lan1'
	list ifname 'lan2'
	list ifname 'lan3'
	list ifname 'lan4'

config interface 'wan'
	option proto 'pppoe'
	option username 'XXXXXXXXXXXXXXXXXXXXXXX'
	option password 'XX'
	option mtu '1492'
	option ipv6 'auto'
	option peerdns '0'
	option dns '192.168.1.4'
	option ifname 'eth2'

config interface 'wan6'
	option proto 'dhcpv6'
	option reqaddress 'try'
	option reqprefix 'auto'
	option ifname '@wan'

config interface 'vpn_turris'
	option enabled '1'
	option proto 'none'
	option auto '1'
	option ifname 'tun_turris'

config route
	option interface 'lan'
	option target '192.168.2.0/24'
	option netmask '255.255.255.0'
	option gateway '192.168.1.2'

config interface 'guest_turris'
	option enabled '1'
	option type 'bridge'
	option proto 'static'
	option ipaddr '10.111.222.1'
	option netmask '255.255.255.0'
	option bridge_empty '1'
	option ifname 'guest_turris_0'

Thanks jiberjaber! Working great now!

I noticed no switch configuration exists in your network file. Any idea why not? Was this done away with in 5.0?

I do recall this existing in 3.x and the Switch menu showing up under the Network tab in LuCi.

1 Like

Please search for keyword „dsa“ on this forum, you will find plenty of information :slight_smile:

Like this:

EDIT: Btw I think a change like this should be added to release notes / migration documentation mentiond in first post…

TO 2 GB, WiFi, simple config, 2x lxc; TOS 3.11.17 (rc)

Installed sw

from Updater:
Data Collection
LuCI extensions
NAS
SSH Honeypot
LXC utilities
Extensions of network protocols
Internet connection speed measurement
Cloud Backups
another sw:
Ludus
Atlas-sw-probe
mc
netdata
omnia-led-colors

Attempted migration to TOS 5 to no avail :frowning: Twice :frowning:

TLDR; unsuccessful migration, unfunctioning WAN, WiFi without internet
access. Rollback. Thus staying on 3.11.17, waiting for miracle or advice.

Maybe it would be better to download all needed packages to some temporary
location prior to make changes in networking :wink:

1st try

Went according to recipe,
in updater-supervisor -d step after about 10 mins pkgupdate
ceased to work; LuCI, Foris, SSH were working… According SSH and Foris TOS
was in 5.0.1 (HBK) version :slight_smile: but without internet. Tried to set WiFi and
WAN, never succeeded :frowning: Switch-branch to HBS with multiple errors like
“* opkg_download: Failed to download https://repo.turris.cz/hbs/omnia/packages/…”;
nevertheless ended with message “You are now on stable the latest version of
Turris OS”. Rollback to last 3.11.17 snapshot.

To my surprise after about two or three hours later TOS without any warning
or question updated itself again to version 5.0.1. (probably because 3.11.17 was
in rc branch?). Situation was this time nearly the same, i.e. no internet.
Again rolled back to 3.11.17, and switched branch to deploy. After that was
system stable.

2nd try

Similar situation as in 1st try. After about 10 mins from start pkgupdate
ceased to work; LuCI, Foris, SSH were working… According SSH and Foris TOS
was in 5.0.1 (HBK) version :slight_smile: again without internet. /tmp/update-state/state
stated failure. This time no attempts to make WAN and WiFi work :wink:
As far as I found on forum that in such a situation pkgupdate might help,
I run it… of course it ended with error. After reboot I wanted to switch
branch to HBS, which ended with errors, as well, but stated that “You are now
on stable the latest version of Turris OS”. I gave up and rolled back to last
3.11.17 snapshot.

So any thoughts on how I can fix the “/usr/lib/lua/luci/dispatcher.lua:426: /etc/config/luci seems to be corrupt, unable to find section ‘main’” issue on the LXC page, I would like to just try and create an LXC so I can use it for a template to get my previous LXC working again :slight_smile:

Is the python3-python package installed?

1 Like

Yep, version 1.0.0-1.0