Since updating to the most recent version if Dietpi I can no longer access my web interface. I completed removed and reinstalled pi-hole via the dietpi-software option. I can control pi-hole via ssh but I cannot access the webpage. I receive a xheader error when running pihole -d to view the debug log. I also am unable to upload the debug log as it asks at the end of the debug log. I am a novice with regards to Linux and Dietpi but have really enjoyed this feature. I didn’t make any other changes other than updating the dietpi software so I’m not really sure what could’ve happened. Any help is appreciated!
Any help would be appreciated, I’m still at a standstill after reaching out to Pi-hole.
Can you check the relevant files and folders under /var/www have the correct ownership i.e www-data?
In my case they are /var/www/admin and /var/www/pihole
Is the webserver otherwise working?
/var/www/pihole and /var/www/admin are both showing owner and group as www-data.
The only other web interface I use is for Transmission and it seems to be working correctly as I am able to log in and add a torrent.
Try
pihole -up
If that doesn’t fix it it could be a php problem - try reinstalling php through the dietpi-software menu.
Pihole -up, all up to date.
PHP – uninstall, reboot, reinstall, reboot. Same result of error 503. Pihole developer also pointed to php being the issue. Any other ideas?
2019-06-01 16:26:17: (mod_fastcgi.c.2686) fcgi-server re-enabled: unix:/run/php/php7.3-fpm.sock
2019-06-01 16:26:54: (mod_fastcgi.c.1926) connect failed: No such file or directory on unix:/run/php/php7.3-fpm.sock
2019-06-01 16:26:54: (mod_fastcgi.c.2842) backend died; we’ll disable it for 1 seconds and send the request to another backend instead: reconnects: 0 load: 1
2019-06-01 16:26:54: (mod_fastcgi.c.1689) all handlers for /index.php? on .php are down.
Please see attachments below.
I have now gotten to a point where if I enter the command
systemctl start php7.3-fpm
the web interface will work correctly until I reboot.
If I reboot and run
service php7.3-fpm status
it shows
Active: failed (Result: timeout)
Any clues in the php logs?
pwrdbytrd
PHP-FPM times out on boot. Looks like it is related to the low entropy issue: https://github.com/MichaIng/DietPi/issues/2806
Real source and solution for this issue is outside of our control, seems to need to fix on Debian side. But you can work around it by installing haveged: G_AGI haveged
While this solves hanging boot and service start timeout, it is not a very well solution since it bears the risk of pseudo-randomness which is a potential security risk when you think about encryption keys where it is essential that /dev/random provides real random output that is not predictable or something.
Since I want to collect info about which systems are affected, might you please send us a bug report and paste the ID here?
dietpi-bugreport
00b60c5e-4a10-48a5-8a2b-a9c5c950a28c
I ran across this topic when I initially had a problem with accessing the webgui after an update. To this date, I have yet to regain access to the webui for pihole. None of the fixes/workarounds in this thread have helped. I’m using Dietpi on an Odroid C2.
Is this a problem unique to me, or is it widespread?
Regards
Christian
kaptain_zero
Which webserver do you use? Assuming Lighttpd (default), could you paste:
journalctl -u lighttpd
journalctl -u php7.3-fpm
MichaIng
journalctl -u lighttpd identified the issue… the Daemon was not running, nor would it start.
I uninstalled and re-installed LLSP and all is back to normal. Thank you for the help!
Regards
Christian
Hi,
I’ve done the same (Uninstall/Install LLSP) since I can’t access my admin interface anymore BUT, I still have the problem and this error :
Nov 27 11:21:00 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 1.
Nov 27 11:21:00 DietPi systemd[1]: Stopped Lighttpd Daemon.
Nov 27 11:21:00 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 11:21:00 DietPi lighttpd[5948]: 2020-11-27 11:21:00: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf failed: No such file or directory
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTION
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 11:21:00 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 11:21:01 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 11:21:01 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 2.
Nov 27 11:21:01 DietPi systemd[1]: Stopped Lighttpd Daemon.
Nov 27 11:21:01 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 11:21:01 DietPi lighttpd[5949]: 2020-11-27 11:21:01: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf failed: No such file or directory
Nov 27 11:21:01 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTION
Nov 27 11:21:01 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Someone has an other idea ?
Thanks !
Hi,
your web server is not starting anymore as you are missing lighttpd configuration file /etc/lighttpd/lighttpd.conf
opening configfile /etc/lighttpd/lighttpd.conf failed: No such file or directory
pls can you post ls -la /etc/lighttpd/
Hi,
Thanks for your help
there it is :
total 20
drwxr-xr-x 4 root root 4096 Nov 2 07:10 .
drwxr-xr-x 81 root root 4096 Nov 27 11:34 ..
drwxr-xr-x 2 root root 4096 Oct 9 08:07 conf-available
drwxr-xr-x 2 root root 4096 Oct 9 08:07 conf-enabled
-rw-r--r-- 1 root root 2057 Sep 19 20:59 lighttpd.conf.bak
create a new config file
nano /etc/lighttpd/lighttpd.conf
and insert whole content as follow
server.modules = (
"mod_indexfile",
"mod_setenv",
"mod_access",
"mod_alias",
"mod_redirect",
"mod_accesslog",
)
server.document-root = "/var/www"
server.upload-dirs = ( "/var/cache/lighttpd/uploads" )
server.errorlog = "/var/log/lighttpd/error.log"
server.pid-file = "/var/run/lighttpd.pid"
server.username = "www-data"
server.groupname = "www-data"
server.port = 80
accesslog.filename = "/var/log/lighttpd/access.log"
# strict parsing and normalization of URL for consistency and security
# https://redmine.lighttpd.net/projects/lighttpd/wiki/Server_http-parseoptsDetails
# (might need to explicitly set "url-path-2f-decode" = "disable"
# if a specific application is encoding URLs inside url-path)
server.http-parseopts = (
"header-strict" => "enable",# default
"host-strict" => "enable",# default
"host-normalize" => "enable",# default
"url-normalize-unreserved"=> "enable",# recommended highly
"url-normalize-required" => "enable",# recommended
"url-ctrls-reject" => "enable",# recommended
"url-path-2f-decode" => "enable",# recommended highly (unless breaks app)
#"url-path-2f-reject" => "enable",
"url-path-dotseg-remove" => "enable",# recommended highly (unless breaks app)
#"url-path-dotseg-reject" => "enable",
#"url-query-20-plus" => "enable",# consistency in query string
)
index-file.names = ( "index.php", "index.html" )
url.access-deny = ( "~", ".inc" )
static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
compress.cache-dir = "/var/cache/lighttpd/compress/"
compress.filetype = ( "application/javascript", "text/css", "text/html", "text/plain" )
# default listening port for IPv6 falls back to the IPv4 port
include_shell "/usr/share/lighttpd/use-ipv6.pl " + server.port
include_shell "/usr/share/lighttpd/create-mime.conf.pl"
include "/etc/lighttpd/conf-enabled/*.conf"
#server.compat-module-load = "disable"
server.modules += (
"mod_compress",
"mod_dirlisting",
"mod_staticfile",
)
restart web server
systemctl restart lighttpd.service
Done
Know I can have
503 Service Not Available
When i try to connect from the webbrowser
what URL you are trying to connect? Pls provide following
systemctl restart lighttpd
systemctl status lighttpd
cat /var/log/lighttpd/error.log
journalctl -u lighttpd
journalctl -u php7.3-fpm
Thanks for the help
So for : systemctl status lighttpd
root@DietPi:~# systemctl status lighttpd
● lighttpd.service - Lighttpd Daemon
Loaded: loaded (/lib/systemd/system/lighttpd.service; disabled; vendor preset: enabled)
Active: active (running) since Fri 2020-11-27 21:05:51 GMT; 7s ago
Process: 11600 ExecStartPre=/usr/sbin/lighttpd -tt -f /etc/lighttpd/lighttpd.conf (code=exited, status=0/SUCCESS)
Main PID: 11606 (lighttpd)
Tasks: 1 (limit: 4442)
CGroup: /system.slice/lighttpd.service
└─11606 /usr/sbin/lighttpd -D -f /etc/lighttpd/lighttpd.conf
Nov 27 21:05:51 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 21:05:51 DietPi systemd[1]: Started Lighttpd Daemon.
cat /var/log/lighttpd/error.log
root@DietPi:~# cat /var/log/lighttpd/error.log
2020-11-27 20:42:18: (server.c.1464) server started (lighttpd/1.4.53)
2020-11-27 20:42:38: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:42:38: (gw_backend.c.956) all handlers for /admin/index.php? on .php are down.
2020-11-27 20:42:40: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:42:41: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:42:41: (gw_backend.c.956) all handlers for /admin/index.php? on .php are down.
2020-11-27 20:42:43: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:42:55: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:42:55: (gw_backend.c.956) all handlers for /admin/index.php? on .php are down.
2020-11-27 20:42:57: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:43:31: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:43:31: (gw_backend.c.956) all handlers for /pihole/index.php? on .php are down.
2020-11-27 20:43:33: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:43:39: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:43:39: (gw_backend.c.956) all handlers for /admin/index.php? on .php are down.
2020-11-27 20:43:41: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:44:26: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:44:26: (gw_backend.c.956) all handlers for /admin/index.php? on .php are down.
2020-11-27 20:44:28: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:50:14: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:50:14: (gw_backend.c.956) all handlers for /admin/index.php? on .php are down.
2020-11-27 20:50:16: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:51:50: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:51:50: (gw_backend.c.956) all handlers for /admin/index.php? on .php are down.
2020-11-27 20:51:52: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:55:32: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 20:55:32: (gw_backend.c.956) all handlers for /nextcloud/index.php? on .php are down.
2020-11-27 20:55:34: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 20:56:01: (mod_openssl.c.1746) SSL: 1 error:1408F10B:SSL routines:ssl3_get_record:wrong version number
2020-11-27 20:56:01: (mod_openssl.c.1746) SSL: 1 error:1408F10B:SSL routines:ssl3_get_record:wrong version number
2020-11-27 20:56:01: (mod_openssl.c.1746) SSL: 1 error:1408F10B:SSL routines:ssl3_get_record:wrong version number
2020-11-27 21:03:47: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 21:03:47: (gw_backend.c.956) all handlers for /nextcloud/index.php? on .php are down.
2020-11-27 21:03:49: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 21:04:36: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 21:04:36: (gw_backend.c.956) all handlers for /nextcloud/index.php? on .php are down.
2020-11-27 21:04:38: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 21:04:49: (gw_backend.c.240) establishing connection failed: No such file or directory socket: unix:/run/php/php7.3-fpm.sock
2020-11-27 21:04:49: (gw_backend.c.956) all handlers for /nextcloud/index.php? on .php are down.
2020-11-27 21:04:51: (gw_backend.c.319) gw-server re-enabled: unix:/run/php/php7.3-fpm.sock 0 /run/php/php7.3-fpm.sock
2020-11-27 21:05:50: (server.c.2059) server stopped by UID = 0 PID = 1
2020-11-27 21:05:51: (server.c.1464) server started (lighttpd/1.4.53)
root@DietPi:~#
journalctl -u lighttpd :
root@DietPi:~# journalctl -u lighttpd
-- Logs begin at Fri 2020-11-27 10:46:22 GMT, end at Fri 2020-11-27 21:05:51 GMT. --
Nov 27 10:47:10 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 10:47:10 DietPi lighttpd[753]: 2020-11-27 10:47:10: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf failed
: No such file or directory
Nov 27 10:47:10 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTIO
N
Nov 27 10:47:10 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 10:47:10 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 10:47:10 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 10:47:10 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 1.
Nov 27 10:47:10 DietPi systemd[1]: Stopped Lighttpd Daemon.
Nov 27 10:47:10 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 10:47:10 DietPi lighttpd[789]: 2020-11-27 10:47:10: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf failed
: No such file or directory
Nov 27 10:47:10 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTIO
N
Nov 27 10:47:10 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 10:47:10 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 2.
Nov 27 10:47:11 DietPi systemd[1]: Stopped Lighttpd Daemon.
Nov 27 10:47:11 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 10:47:11 DietPi lighttpd[790]: 2020-11-27 10:47:11: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf failed
: No such file or directory
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTIO
N
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 10:47:11 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 3.
Nov 27 10:47:11 DietPi systemd[1]: Stopped Lighttpd Daemon.
Nov 27 10:47:11 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 10:47:11 DietPi lighttpd[791]: 2020-11-27 10:47:11: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf failed
: No such file or directory
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTIO
N
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 10:47:11 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 4.
Nov 27 10:47:11 DietPi systemd[1]: Stopped Lighttpd Daemon.
Nov 27 10:47:11 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 10:47:11 DietPi lighttpd[792]: 2020-11-27 10:47:11: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf failed
: No such file or directory
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTIO
N
Nov 27 10:47:11 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 10:47:11 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 10:47:12 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 10:47:12 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 5.
Nov 27 10:47:12 DietPi systemd[1]: Stopped Lighttpd Daemon.
Nov 27 10:47:12 DietPi systemd[1]: lighttpd.service: Start request repeated too quickly.
Nov 27 10:47:12 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 10:47:12 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 11:21:00 DietPi systemd[1]: Starting Lighttpd Daemon...
Nov 27 11:21:00 DietPi lighttpd[5946]: 2020-11-27 11:21:00: (configfile.c.1328) opening configfile /etc/lighttpd/lighttpd.conf faile
d: No such file or directory
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Control process exited, code=exited, status=255/EXCEPTIO
N
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Failed with result 'exit-code'.
Nov 27 11:21:00 DietPi systemd[1]: Failed to start Lighttpd Daemon.
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Service RestartSec=100ms expired, scheduling restart.
Nov 27 11:21:00 DietPi systemd[1]: lighttpd.service: Scheduled restart job, restart counter is at 1.
Nov 27 11:21:00 DietPi systemd[1]: Stopped Lighttpd Daemon.
--More--
journalctl -u php7.3-fpm :
root@DietPi:~# journalctl -u php7.3-fpm
-- Logs begin at Fri 2020-11-27 10:46:22 GMT, end at Fri 2020-11-27 21:05:51 GMT. --
Nov 27 10:47:09 DietPi systemd[1]: Starting The PHP 7.3 FastCGI Process Manager...
Nov 27 10:47:10 DietPi systemd[1]: Started The PHP 7.3 FastCGI Process Manager.
Nov 27 11:29:04 DietPi systemd[1]: Stopping The PHP 7.3 FastCGI Process Manager...
Nov 27 11:29:04 DietPi systemd[1]: php7.3-fpm.service: Succeeded.
Nov 27 11:29:04 DietPi systemd[1]: Stopped The PHP 7.3 FastCGI Process Manager.
Nov 27 11:29:23 DietPi systemd[1]: Starting The PHP 7.3 FastCGI Process Manager...
Nov 27 11:29:23 DietPi systemd[1]: Started The PHP 7.3 FastCGI Process Manager.
Nov 27 11:30:29 DietPi systemd[1]: Stopping The PHP 7.3 FastCGI Process Manager...
Nov 27 11:30:29 DietPi systemd[1]: php7.3-fpm.service: Succeeded.
Nov 27 11:30:29 DietPi systemd[1]: Stopped The PHP 7.3 FastCGI Process Manager.
root@DietPi:~#
There it is, I’ve noticed that when i Try to acess my Nextcloud via the web interface it shows me the same message