Trying to have a local `Web page` with iframes so I can monitor all my Piholes

I have been trying for some time to have a web page with iframes so I can monitor all my Piholes settings so I only have 1 tab open not 10. I use it for other things as well.

I am also trying to have a PiHole on a Intel Atom N2800 x686 CPU Netbook with wattOS-R10-32. Cheaper than a Raspberrypi ($5.00 at rubbish tip + New $50 PSU).

I did a * apt-get dist-upgrade and now have Ubuntu 18.04 display on the boot screen but still with the wattOS-R10-32 desktop interface.
Its lost DNS settings in network for some reason.
Will get to it when time permits.

The issue I am facing:
I had the pihole running with PHP Version 8.2.3.

Somehow the apache web server is now installed.
I was using a full install of lighttpd as a web server and a Dnsmasq server sharing the DNS load to 5 Piholes as a test to play with, It also provides fault tolerance of the DNS queries on my network. Has been on my RaspberryPi after removing the Pihole over a year ago.
I upgraded raspbian to have a later version of PHP. Still had Version too low on one app.
This version of #Nextcloud is not compatible with PHP>=8.2. You are currently running 8.2.3. I went from condition under to over.....

I tried these commands and it cured my errors about Nextcloud PHP being to High. It also allowed me to Logon to my various PiHoles to work in an iframe on my network, firefox not chrome.

apt install php8.1-cli
apt install php-cli

Some how I now have Apache as my webserver and I can't get to the Pihole Admin page correctly its just PHP code in txt.

Apache/2.4.38 (Raspbian) Server at 192.168.1.5 Port 80
<?php
/*   Pi-hole: A black hole for Internet advertisements
*    (c) 2017 Pi-hole, LLC (https://pi-hole.net)
*    Network-wide ad blocking via your own hardware.
*
*    This file is copyright under the latest version of the EUPL.
*    Please see LICENSE file for your rights under this license.
*/

Base IP of web site.

# Index of /

|![[ICO]](http://192.168.1.5/icons/blank.gif)|[Name](http://192.168.1.5/?C=N;O=D)|[Last modified](http://192.168.1.5/?C=M;O=A)|[Size](http://192.168.1.5/?C=S;O=A)|[Description](http://192.168.1.5/?C=D;O=A)|
| --- | --- | --- | --- | --- |
|---|
|![[DIR]](http://192.168.1.5/icons/folder.gif)|[admin/](http://192.168.1.5/admin/)|2023-02-20 05:09|-||
|![[TXT]](http://192.168.1.5/icons/text.gif)|[index2.html](http://192.168.1.5/index2.html)|2023-02-18 04:56|972K||
|![[TXT]](http://192.168.1.5/icons/text.gif)|[index2a.html](http://192.168.1.5/index2a.html)|2023-02-18 04:16|972K||
|![[DIR]](http://192.168.1.5/icons/folder.gif)|[pihole/](http://192.168.1.5/pihole/)|2023-02-18 04:18|-||
|---|

The Pihole is maybe still running.
Seems to interact with iframe.

# Domain management

### Add a new domain or regex filter

* [Domain](http://192.168.1.5/admin/groups-domains.php#tab_domain)
* [RegEx filter](http://192.168.1.5/admin/groups-domains.php#tab_regex)

Domain:

Details about my system:

RaspberryPi 3B.

uname -r 6.1.11-v7+
 cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"

What I have changed since installing Pi-hole:
I downgraded just 2 components of PHP from PHP 8.2.3 to PHP 8.1 to satisfy requirement's of other programs complaining about being iframed with the wrong version of PHP.

apt install php8.1-cli
apt install php-cli

https://tricorder.pi-hole.net/FoUsAdD0/

Many Thanks

You can even nest a few iframes to reduce the size of the complete page.

I didn't understand what you want.

Do you want to use lighttpd or apache2?

Your debug log shows PHP 8.2.3:

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

Note:
I never heard about running a few PHP components using a different version than the rest of PHP.

To run a Pihole + use the web server for other things which is built in to Pihole.

If you want to use only lighttpd as web server, you will need to uninstall apache2.

I think it was installed by Nextcloud.

I'm not sure if Nextcloud will work with lighttpd and if it does, you will need to find out how to configure it.

I only run a iframe to a Nextcloud server, it had a problem with the PHP version.

If you don't need Apache on your Raspberry Pi, uninstall it.

Ok Thanks.
I can get to it again via /admin/index.php but the home splash page is not there but not really worried about that at the moment.

The following package was automatically installed and is no longer required:
  apache2-data
Use 'apt autoremove' to remove it.
The following packages will be REMOVED:
  apache2
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
After this operation, 614 kB disk space will be freed.
Do you want to continue? [Y/n]

Will try a reboot.

I noticed your Pi-hole installation is using the stock lighttpd.conf file. This is the default for new installations.

This file includes every config inside /etc/lighttpd/conf-enabled/, but it doesn't include the old external.conf. You will need to move/rename this file:

mv /etc/lighttpd/external.conf /etc/lighttpd/conf-enabled/20-pihole-external.conf
2 Likes

Ok doing repair and reboot.

Looks ok

Existing PHP installation detected : PHP version 8.2.3
  [✓] Checking for php8.2-common
  [✓] Checking for php8.2-cgi
  [✓] Checking for php8.2-sqlite3
  [✓] Checking for php8.2-xml
  [✓] Checking for php8.2-intl
root@raspberrypi:~# pihole -r

  [✓] Root user check

        .;;,.
        .ccccc:,.
         :cccclll:.      ..,,
          :ccccclll.   ;ooodc
           'ccll:;ll .oooodc
             .;cll.;;looo:.
                 .. ','.
                .',,,,,,'.
              .',,,,,,,,,,.
            .',,,,,,,,,,,,....
          ....''',,,,,,,'.......
        .........  ....  .........
        ..........      ..........
        ..........      ..........
        .........  ....  .........
          ........,,,,,,,'......
            ....',,,,,,,,,,,,.
               .',,,,,,,,,'.
                .',,,,,,'.
                  ..'''.

  [i] SELinux not detected
  [✓] Update local cache of available packages
  [i] Existing PHP installation detected : PHP version 8.2.3

  [✓] Checking apt-get for upgraded packages... 5 updates available
  [i] It is recommended to update your OS after installing the Pi-hole!

  [i] Checking for / installing Required dependencies for OS Check...
  [✓] Checking for grep
  [✓] Checking for dnsutils

  [✓] Supported OS detected
  [i] Checking for / installing Required dependencies for this install script...
  [✓] Checking for git
  [✓] Checking for iproute2
  [✓] Checking for dialog
  [✓] Checking for ca-certificates

  [i] Repair option selected
  [i] Performing reconfiguration, skipping download of local repos
  [✓] Resetting repository within /etc/.pihole...
  [✓] Resetting repository within /var/www/html/admin...
  [i] Checking for / installing Required dependencies for Pi-hole software...
  [✓] Checking for cron
  [✓] Checking for curl
  [✓] Checking for iputils-ping
  [✓] Checking for psmisc
  [✓] Checking for sudo
  [✓] Checking for unzip
  [✓] Checking for idn2
  [✓] Checking for libcap2-bin
  [✓] Checking for dns-root-data
  [✓] Checking for libcap2
  [✓] Checking for netcat-openbsd
  [✓] Checking for procps
  [✓] Checking for jq
  [✓] Checking for lighttpd
  [✓] Checking for php8.2-common
  [✓] Checking for php8.2-cgi
  [✓] Checking for php8.2-sqlite3
  [✓] Checking for php8.2-xml
  [✓] Checking for php8.2-intl

  [✓] Enabling lighttpd service to start on reboot...
  [✓] Checking for user 'pihole'

  [i] FTL Checks...

  [✓] Detected ARMv7 processor (with hard-float support)
  [i] Checking for existing FTL binary...
  [i] Latest FTL Binary already installed (v5.21). Confirming Checksum...
  [i] Checksum correct. No need to download!
  [✓] Installing scripts from /etc/.pihole

  [i] Installing configs from /etc/.pihole...
  [i] Existing dnsmasq.conf found... it is not a Pi-hole file, leaving alone!
  [✓] Installed /etc/dnsmasq.d/01-pihole.conf
  [✓] Installed /etc/dnsmasq.d/06-rfc6761.conf

  [✓] Installing sudoer file

  [✓] Installing latest Cron script

  [i] Installing latest logrotate script...
        [i] Existing logrotate file found. No changes made.
  [i] Backing up /etc/dnsmasq.conf to /etc/dnsmasq.conf.old
  [✓] man pages installed and database updated
  [i] Testing if systemd-resolved is enabled
  [i] Systemd-resolved is not enabled
  [✓] Restarting lighttpd service...
  [✓] Enabling lighttpd service to start on reboot...
  [i] Restarting services...
  [✓] Enabling pihole-FTL service to start on reboot...
  [✓] Restarting pihole-FTL service...
  [✓] Deleting existing list cache
  [i] Neutrino emissions detected...
  [✓] Pulling blocklist source list into range

  [✓] Preparing new gravity database
  [i] Using libz compression

  [i] Target: https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
  [✓] Status: Retrieval successful
  [i] Imported 183304 domains, ignoring 1 non-domain entries
      Sample of non-domain entries:
        - 0.0.0.0

  [✓] Creating new gravity databases
  [✓] Storing downloaded domains in new gravity database
  [✓] Building tree
  [✓] Swapping databases
  [✓] The old database remains available.

I lost remote ssh connection for some reason.
Doing reboot.

Now.
At 192.168.1.5 http error 500 but I have no problem with that. I will just add a hyperlink to it.
My Site and my pihole is working again Many Thanks for the help.

192.168.1.5/admin/ ok
192.168.1.5/index.html ok my site.

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