Unable to start lighttpd daemon

Hi,

I am using Pihole alongside Nginx proxy manager, so I changed the Pihole port to 8080. and it was working just fine until it didn't, so I spent so much time trying to fix it thinking this was the issue, as a last resort I stopped the Nginx docker and changed the Pihole port back to 80. and that didn't work. I've been trying to fix a non-existent issue -=-. The lighttpd logs in /var/log/lighttpd were empty for some reason and with a limited explanation in systemctl status lighttpd.service, I`m not sure how to proceed with resolving my issue.
lighttpd version:1.4.69
pihole version:5.18.4

Expected Behaviour:

being able to access the web ui
-operating system:Debian 12 bookworm
-hardware: Orange pi zero 3 2gb

Actual Behaviour:

lighttpd daemon is not running

Debug Token:

gykTL4uw

Your debug log shows a different configuration:

  • Pi-hole is configured to use port 80;
  • nginx is currently using port 8081
*** [ DIAGNOSING ]: Ports in use
    (...)
    tcp:0.0.0.0:8081 is in use by nginx
    (...)
    tcp:[::]:8081 is in use by nginx

Actually the error log shows the reason for the failure:

*** [ DIAGNOSING ]: contents of /var/log/lighttpd

-rw-r--r-- 1 www-data www-data 528 Feb  1 01:31 /var/log/lighttpd/error-pihole.log

   -----tail of error-pihole.log------
   2025-02-01 01:19:07: (server.c.1704) server started (lighttpd/1.4.69)
   2025-02-01 01:19:07: (mod_accesslog.c.450) opening log '/var/log/lighttpd/access.log' failed: Permission denied
   2025-02-01 01:19:07: (server.c.1708) Configuration of plugins failed. Going down.
   2025-02-01 01:31:40: (server.c.1704) server started (lighttpd/1.4.69)
   2025-02-01 01:31:40: (mod_accesslog.c.450) opening log '/var/log/lighttpd/access.log' failed: Permission denied
   2025-02-01 01:31:40: (server.c.1708) Configuration of plugins failed. Going down.

There is a permission error in access.log.

Please check if /var/log/lighttpd/access.log file exists and if the permissions and ownership are correct.

It should be:

-rw-r--r-- 1 www-data www-data      0 Jan 19 06:42 access.log

Then restart lighttpd with sudo systemctl restart lighttpd.service.

8081 is OMV, but 80 is for nginx proxy manager (before i stopped the docker and changed pihole back to 80).

changed the owner of the logs and now i can start the service!! Thank you.