Help required : Luci Upgraded to Death - How To Fix?

My little OpenWRT/Lede home router has run fine for years, no problems with installation or updates whatsoever. Yesterday, I apparently had to much time on my hands and started going through the extended Luci options, including the package managers UPGRADE options. I foolishly then started upgrading packages, not having read this:

Blindly upgrading packages (manually or via script) can lead you into all sorts of trouble.
https://openwrt.org/docs/guide-user/installation/sysupgrade.cli

I know, it's all my fault. Router still boots up and I can access the system via SSH, but Luci seems to have taken a hit.

If it's any help here is the error message I get, when trying to reach Luci:

/usr/lib/lua/luci/template.lua:97: Failed to execute template 'sysauth'.
A runtime error occurred: /usr/lib/lua/luci/template.lua:97: Failed to execute template 'header'.
A runtime error occurred: /usr/lib/lua/luci/template.lua:97: Failed to execute template 'themes/bootstrap/header'.
A runtime error occurred: [string "/usr/lib/lua/luci/view/themes/bootstrap/hea..."]:20: attempt to call field 'node_childs' (a nil value)
stack traceback:
	[string "/usr/lib/lua/luci/view/themes/bootstrap/hea..."]:20: in main chunk
stack traceback:
	[C]: in function 'error'
	/usr/lib/lua/luci/template.lua:97: in function 'render'
	/usr/lib/lua/luci/dispatcher.lua:755: in function 'include'
	[string "/usr/lib/lua/luci/view/header.htm"]:3: in main chunk
stack traceback:
	[C]: in function 'error'
	/usr/lib/lua/luci/template.lua:97: in function 'render'
	/usr/lib/lua/luci/dispatcher.lua:755: in function 'include'
	[string "/usr/lib/lua/luci/view/sysauth.htm"]:1: in main chunk
stack traceback:
	[C]: in function 'error'
	/usr/lib/lua/luci/template.lua:97: in function </usr/lib/lua/luci/template.lua:85>
	(tail call): ?
	(tail call): ?
	/usr/lib/lua/luci/dispatcher.lua:979: in function 'dispatch'
	/usr/lib/lua/luci/dispatcher.lua:478: in function </usr/lib/lua/luci/dispatcher.lua:477>

Can you help me getting out of this mess?
I'm not very confident using OpenWrt on the command line, but I would now try to perform a systemupgrade to the last version I had running.
Is this the right approach, or is there something else I should do?
Thanks for your help.
Simon

Try Factory Reset

https://openwrt.org/docs/guide-user/troubleshooting/failsafe_and_factory_reset

3 Likes

Which would mean loosing all my settings.

I was hoping to keep my old settings with a forced sysupgrade of the last image.

You can copy your settings from /etc/config before resetting.

I don't see why you can't sysupgrade to the same current version

https://openwrt.org/docs/guide-user/installation/sysupgrade.cli

2 Likes

See if this helps:

1 Like

Many Thanks for your advice, Bill.

Factory Reset got Luci back up and running and I then applied a backup of my settings through Luci. Very simple and everything is now running again as usual.

1 Like

If your problem is solved, please consider marking this topic as [Solved]. See How to mark a topic as [Solved] for a short how-to.

Hi Thomas, you're faster than me.
I was busy getting my router back up to speed.
Factory Reset got my system back to life, so I am sorry I won't be able to try the fix you suggested. I could say, maybe next time, but then hopefully there won't be a next time. Thank you anyways.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.