Cannot access web interface

Expected Behaviour:

I had pihole running for about 2 years on an orange pi with no problems with the latest version.

Actual Behaviour:

The last 5 days i cannot access the web interface with pi.hole/admin or the ip.
I can ping the ip with no problem. A can connect through ssh, but no interface.
Any help?

Debug Token:

https://tricorder.pi-hole.net/6zb1hdkbyg

(Seems you'd unintentionally flicked a character when typing your debug token.
I've fixed that in your post.
:wink: )

Your debug log shows Pi-hole's web server lighttpd to be inactive:

*** [ DIAGNOSING ]: Pi-hole processes
[✗] lighttpd daemon is failed
[✓] pihole-FTL daemon is active

*** [ DIAGNOSING ]: Dashboard and block page
[✗] Block page X-Header: X-Header does not match or could not be retrieved.
[✗] Web interface X-Header: X-Header does not match or could not be retrieved.

You may test your lighttpd installation for syntactical correctness by running:

lighttpd -t -f /etc/lighttpd/lighttpd.conf

If that comes back with Syntax OK, try restarting it:

sudo service lighttpd restart

In case that fails, please provide the output for:

sudo systemctl status --full --no-pager lighttpd.service

All above commands need to be run on your Pi-hole machine.

Thanks in advance.
I run all the commands.
Restart does not work
So the system results are:

root@orangepipc:/var# lighttpd -t -f /etc/lighttpd/lighttpd.conf
Syntax OK
root@orangepipc:/var# sudo service lighttpd restart
root@orangepipc:/var# sudo systemctl status --full --no-pager lighttpd.service
● lighttpd.service - Lighttpd Daemon
   Loaded: loaded (/lib/systemd/system/lighttpd.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Sat 2020-09-19 12:00:12 UTC; 59s ago
  Process: 27313 ExecStart=/usr/sbin/lighttpd -D -f /etc/lighttpd/lighttpd.conf (code=exited, status=255)
  Process: 27304 ExecStartPre=/usr/sbin/lighttpd -tt -f /etc/lighttpd/lighttpd.conf (code=exited, status=0/SUCCESS)
 Main PID: 27313 (code=exited, status=255)

Sep 19 12:00:12 orangepipc systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Sep 19 12:00:12 orangepipc systemd[1]: lighttpd.service: Service hold-off time over, scheduling restart.
Sep 19 12:00:12 orangepipc systemd[1]: Stopped Lighttpd Daemon.
Sep 19 12:00:12 orangepipc systemd[1]: lighttpd.service: Start request repeated too quickly.
Sep 19 12:00:12 orangepipc systemd[1]: Failed to start Lighttpd Daemon.
Sep 19 12:00:12 orangepipc systemd[1]: lighttpd.service: Unit entered failed state.
Sep 19 12:00:12 orangepipc systemd[1]: lighttpd.service: Failed with result 'exit-code'.

lighttpd fails to start at all. It may do so e.g. if it can't access its log files, either due to permissions or because they don't exist at all.

Let's check for that. What's the output of:

sudo ls -lah /var/log/lighttpd/
 sudo ls -lah /var/log/lighttpd
total 8.0K
drwxr-x--- 2 root root 4.0K Sep 13 06:30 .
drwxr-xr-x 9 root root 4.0K Sep 19 05:58 ..
-rw-r--r-- 1 root root    0 Sep 18 17:30 access.log
-rw-r--r-- 1 root root    0 Sep 18 17:30 error.log

(You can format your output for readability by using the </> Preformatted text menu option. I've just done that for your above command output. :wink: )

That directory shouldn't be owned by root.
Did you intentionally change that?

Try fixing that by running:

sudo chown -R www-data:www-data /var/log/lighttpd

and restartt lighttpd afterwards.

1 Like

I didn't change the permitions. I don't how that happend.
Anyway following your last tip fixed the problems.

Thank you very much.

OrangePi? Which OS are you using, Armbian?

If you have a ramlog setup for /var/log then make sure the auto-creation of the directory is configured to use the proper owner.

Yes Armbian it is.

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