Can't Connect to LuCi After OpenWrt Upgrade - Solution

Powered by Drupal
Submitted by Sam Hobbs on

openwrt-barrier-breaker.png I just upgraded my OpenWrt router from Attitude Adjustment (12.09) to Barrier Breaker (14.07) on my TP-Link WDR3600. There are many methods of doing this, I chose the GUI way in the web interface LuCi. I downloaded the new firmware, uploaded it via LuCi, it flashed successfully and rebooted. My config files were preserved and all of my devices reconnected successfully. Great! But wait... no LuCi! Whatever I tried, I couldn't get LuCi to connect. After tearing my hair out for a bit, I discovered what was wrong.

HTTPS in uhttpd

A few months ago I modified the configuration file for uhttpd, OpenWrt's HTTP server, to enable HTTPS connections. At the same time I disabled HTTP to avoid sending my password in the clear. SSL/TLS capabilities for uhttpd are provided by a package that is not installed by default: uhttpd-mod-tls - I had to install this when I made the changes. What I forgot is that when openwrt does a sysupgrade it doesn't re-install packages you installed with opkg. I had to re-install this package to ge LuCi working again:

opkg update
opkg install uhttpd-mod-tls

And then restart uhttpd:

/etc/init.d/uhttpd restart

Voila! LuCi was available again at https://openwrt.lan :) As a bonus, LuCi has even had a bit of a makeover - it now looks more modern whilst retaining all of its previous functionality. openwrt-new-luci-realtime-load.png In case you were wondering, flashing a sysupgrade from the GUI doesn't seem to be a problem if you are using an extroot overlay on a USB flash drive to increase your memory. I was concerned at first that it might cause problems, but everything went smoothly. Hopefully that will save someone some hair-tearing!

Comments

Newer versions of LuCi need a different package to run HTTPS as uhttpd-mod-tls is no more.

Do the following instead of trying that package if you run into problems.

opkg update
opkg isntall luci-ssl
/etc/init.d/uhttpd restart

If it matters, I'm running openwrt-19.07.6-ath79-generic-tplink_archer-a7-v5-squashfs-sysupgrade.bin.

Add new comment

The content of this field is kept private and will not be shown publicly.

Filtered HTML

  • Web page addresses and email addresses turn into links automatically.
  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.