When my OpenWRT router (ar71xx running r49388) boots up everything seems to work fine. However, after a while (not sure when it happens, but right now it has been up 43 days and is happening now) I can't login to the web interface any more. When I go to the URL (192.168.1.1) Firefox says
> Bad Gateway
> The process did not produce any response
and Google Chrome spins for a while then says:
> This site can’t be reached
> 192.168.1.1 took too long to respond.
In the past when I've encountered this I've just rebooted the device, but right now I can't because it's in production, and I'd have to wait for scheduled downtime, so I'd like to learn how to manually fix whatever is breaking in this case.
When I attempt to run
(replace _ with w; stupid link blocker is tripping on it) I get the following output:
/usr/bin/lua: /ww_/cgi-bin/luci:4: attempt to index field 'dispatcher' (a nil value) stack traceback: /ww_/cgi-bin/luci:4: in main chunk [C]: ?
That file is just a few lines long:
#!/usr/bin/lua require "luci.cacheloader" require "luci.sgi.cgi" luci.dispatcher.indexcache = "/tmp/luci-indexcache" luci.sgi.cgi.run()
If I comment out or delete the 3rd line (dispatcher) I get the following error instead:
/usr/bin/lua: /ww_/cgi-bin/luci:4: attempt to index field 'sgi' (a nil value) stack traceback: /ww_/cgi-bin/luci:4: in main chunk [C]: ?
so it seems like somehow required modules aren't getting loaded or something, but I don't know how to debug this further. Could anyone help me figure out what is wrong or where I should look next?