503 Service Not Available

Let's check some versions
What's the output of:

openssl version
php --version

OpenSSL 1.1.1c 28 May 2019

php seems to have a problem

PHP Warning:  Failed loading Zend extension 'opcache.so' (tried: /usr/lib/php/20180731/opcache.so (/usr/lib/php/20180731/opcache.so: invalid ELF header), /usr/lib/php/20180731/opcache.so.so (/usr/lib/php/20180731/opcache.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo.so' (tried: /usr/lib/php/20180731/pdo.so (/usr/lib/php/20180731/pdo.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pdo.so.so (/usr/lib/php/20180731/pdo.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo_sqlite.so' (tried: /usr/lib/php/20180731/pdo_sqlite.so (/usr/lib/php/20180731/pdo_sqlite.so: undefined symbol: php_pdo_unregister_driver), /usr/lib/php/20180731/pdo_sqlite.so.so (/usr/lib/php/20180731/pdo_sqlite.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

You're likely missing the php-sqlite package.
But without the correct PHP version, I am at a loss which package to recommend for manual updating.

I also admit I've overlooked a respective (if curt) warning at the start of your debug log:

*** [ DIAGNOSING ]: php version
[i] Warning:

See if Pi-hole can repair this itself.
Please run

pihole -r

and select Repair.

unfortunately it did not solve the problem, but right at the start I get this displayed, maybe this tells you more.

PHP Warning:  Failed loading Zend extension 'opcache.so' (tried: /usr/lib/php/20180731/opcache.so (/usr/lib/php/20180731/opcache.so: invalid ELF header), /usr/lib/php/20180731/opcache.so.so (/usr/lib/php/20180731/opcache.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo.so' (tried: /usr/lib/php/20180731/pdo.so (/usr/lib/php/20180731/pdo.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pdo.so.so (/usr/lib/php/20180731/pdo.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo_sqlite.so' (tried: /usr/lib/php/20180731/pdo_sqlite.so (/usr/lib/php/20180731/pdo_sqlite.so: undefined symbol: php_pdo_unregister_driver), /usr/lib/php/20180731/pdo_sqlite.so.so (/usr/lib/php/20180731/pdo_sqlite.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
  [i] Existing PHP installation detected : PHP version
PHP Warning:  Failed loading Zend extension 'opcache.so' (tried: /usr/lib/php/20180731/opcache.so (/usr/lib/php/20180731/opcache.so: invalid ELF header), /usr/lib/php/20180731/opcache.so.so (/usr/lib/php/20180731/opcache.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo.so' (tried: /usr/lib/php/20180731/pdo.so (/usr/lib/php/20180731/pdo.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pdo.so.so (/usr/lib/php/20180731/pdo.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo_sqlite.so' (tried: /usr/lib/php/20180731/pdo_sqlite.so (/usr/lib/php/20180731/pdo_sqlite.so: undefined symbol: php_pdo_unregister_driver), /usr/lib/php/20180731/pdo_sqlite.so.so (/usr/lib/php/20180731/pdo_sqlite.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  Failed loading Zend extension 'opcache.so' (tried: /usr/lib/php/20180731/opcache.so (/usr/lib/php/20180731/opcache.so: invalid ELF header), /usr/lib/php/20180731/opcache.so.so (/usr/lib/php/20180731/opcache.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo.so' (tried: /usr/lib/php/20180731/pdo.so (/usr/lib/php/20180731/pdo.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pdo.so.so (/usr/lib/php/20180731/pdo.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'pdo_sqlite.so' (tried: /usr/lib/php/20180731/pdo_sqlite.so (/usr/lib/php/20180731/pdo_sqlite.so: undefined symbol: php_pdo_unregister_driver), /usr/lib/php/20180731/pdo_sqlite.so.so (/usr/lib/php/20180731/pdo_sqlite.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

Let's ask your packet manager what it knows about PHP:

apt-cache show php

Sure :slightly_smiling_face:

Package: php
Source: php-defaults (69)
Version: 2:7.3+69
Installed-Size: 12
Maintainer: Debian PHP Maintainers <team+pkg-php@tracker.debian.org>
Architecture: all
Depends: php7.3
Size: 5964
SHA256: 0fbe0870fccbbcab2c5f6489af12167189d87db0d399295812e784f376151daa
SHA1: 3fa3f80e53f5ba1e0ed1a6d80307d3481638c693
MD5sum: c4a7abb123cb816fc2a7a546e6700e90
Description: server-side, HTML-embedded scripting language (default)
 PHP (recursive acronym for PHP: Hypertext Preprocessor) is a widely-used
 open source general-purpose scripting language that is especially suited
 for web development and can be embedded into HTML.
 .
 This package is a dependency package, which depends on latest stable
 PHP version (currently 7.3).
Description-md5: 8877e9f08f3b7f9ce8d66848cbb639e7
Section: php
Priority: optional
Filename: pool/main/p/php-defaults/php_7.3+69_all.deb

See if trying to reinstall php-sqlite3 fixes your issue:

sudo apt-get install php-sqlite3

unfortunately, that didn't help.

udo apt-get install php-sqlite3
Reading package lists... Done
Building dependency tree
Reading state information... Done
php-sqlite3 is already the newest version (2:7.3+69).
0 upgraded, 0 newly installed, 0 to remove and 152 not upgraded.

All errors are PHP related.
Might want to start with a fresh PHP stack.
Figure out currently installed PHP packages:

apt list --installed '*php*'

Purge/uninstall them all:

sudo apt purge <PACKAGE_1> <PACKAGE_2> <PACKAGE_3> etc

Select repair:

pihole -r

And test web GUI.

1 Like

I did what you said. Unfortunately, the web gui is still not available.
when i now enter php --version the following message appears

php --version
Segmentation fault

Something awfully wrong with your setup.
Is this a Raspi ?
If so, what does below output ?

dmesg -e | grep -i voltage

1 Like

it is a raspi.
I think you're right. Something's gone completely wrong.
a few errors..

[  +4.160051] Voltage normalised (0x00000000)
[Aug12 14:44] Under-voltage detected! (0x00050005)
[  +4.159903] Voltage normalised (0x00000000)
[Aug12 14:50] Under-voltage detected! (0x00050005)
[  +4.160044] Voltage normalised (0x00000000)
[Aug12 15:06] Under-voltage detected! (0x00050005)
[  +6.239933] Voltage normalised (0x00000000)
[ +24.960257] Under-voltage detected! (0x00050005)
[Aug12 15:07] Voltage normalised (0x00000000)
[  +8.320059] Under-voltage detected! (0x00050005)
[  +8.320154] Voltage normalised (0x00000000)
[  +0.000009] Voltage normalised (0x00000000)
[  +0.000008] Under-voltage detected! (0x00050005)
[  +4.159990] Voltage normalised (0x00000000)
[  +2.080211] Under-voltage detected! (0x00050005)
[Aug12 15:13] Voltage normalised (0x00000000)
[  +4.160115] Under-voltage detected! (0x00050005)
[  +0.000007] Under-voltage detected! (0x00050005)
[  +0.000007] Voltage normalised (0x00000000)
[Aug12 15:18] Under-voltage detected! (0x00050005)
[  +4.159997] Voltage normalised (0x00000000)
[  +4.160111] Under-voltage detected! (0x00050005)
[  +6.240042] Voltage normalised (0x00000000)
[  +0.000007] Under-voltage detected! (0x00050005)
[  +0.000005] Voltage normalised (0x00000000)
[Aug12 15:24] Under-voltage detected! (0x00050005)
[  +4.160034] Voltage normalised (0x00000000)
[Aug12 15:25] Under-voltage detected! (0x00050005)
[  +6.240196] Voltage normalised (0x00000000)

and it goes on. i only copied a small part but the error is always the same

Under-voltage means your power adapter is not up to the task resulting in segmentation errors.
It could also be caused by a bad cable.
Need to get one with higher wattage depending connected devices etc.

Thanks for all the help. i will buy a new power supply. hopefully everything will work again.

2 Likes

Found below for reference:

Since your SD card may be quite corrupted, I would plan on (1) installing a completely fresh OS on the same card after formatting the card, or (2) replace the card and then put a fresh OS on the new card.

1 Like

that's weird. i actually have a 3 amp power supply. but it's probably just defective.

yes i will completely rewrite this on a new sd card

Some adapters are good for charging but not stable enough to power Pi.
Can you exchange the cable ?
Any USB devices connected ?

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