Error message: “Attempt to write a readonly database” 2021

System: Pi 3 Model B. OS: Raspbian GNU/Linux 9 (stretch). Web server - apache2
Update from/to - -

pihole -v
  Pi-hole version is v4.3 (Latest: v5.3.1)
  AdminLTE version is v4.3 (Latest: v5.5)
  FTL version is v4.3.1 (Latest: v5.8.1)

Update Method(s)- Both pihole -up & uninstall Pi-hole version v4.3 & install (Latest: v5.3.1) - same result both times.

Problems when trying to whitelist sites using web ui -
1 - Initially - 'Unable to write to read only database'.
2 - After trying 1-4 (below) then error changed to 'something went wrong'
Subsequently realized after refreshing webpage that site added in ui.
3 - Tried blacklisting website in web ui same result, but did not actually blacklist.
Did not try blacklist with cli
Verified ad-blocker working with adblock test site.
It was possible to add new groups without errors.

Request for help - how to find out what 'something went wrong' specifically meant ?

Tried -
1
pihole -r
2
usermod -a -G pihole www-data
3

sudo adduser www-data pihole
sudo systemctl restart apache2

4

sudo chown pihole:www-data -R /var/www/html/
sudo chmod 0775 -R /var/www/html/

Restart after each change.

Other Info -

grep pihole /etc/group
pihole:x:996:www-data

$ ps -o uid,user,gid,group,pid,cmd -C apache2
  UID USER       GID GROUP      PID CMD
    0 root         0 root       733 /usr/sbin/apache2 -k start
   33 www-data    33 www-data   865 /usr/sbin/apache2 -k start
   33 www-data    33 www-data   867 /usr/sbin/apache2 -k start
   33 www-data    33 www-data   868 /usr/sbin/apache2 -k start
   33 www-data    33 www-data  1946 /usr/sbin/apache2 -k start
   33 www-data    33 www-data  1947 /usr/sbin/apache2 -k start
   33 www-data    33 www-data  2169 /usr/sbin/apache2 -k start
   33 www-data    33 www-data  2363 /usr/sbin/apache2 -k start
   33 www-data    33 www-data  2365 /usr/sbin/apache2 -k start
   33 www-data    33 www-data  2649 /usr/sbin/apache2 -k start
   33 www-data    33 www-data  3038 /usr/sbin/apache2 -k start

Ownership/Permissions

-rw-r--r-- 1 root   root        65 May  4 17:07 adlists.list
-rw-r--r-- 1 root   root         0 May  4 16:40 custom.list
-rw-r--r-- 1 pihole pihole       0 May  4 18:27 dhcp.leases
-rw-r--r-- 1 root   root       618 May  4 17:07 dns-servers.conf
-rw-r--r-- 1 root   root        18 May  4 18:28 GitHubVersions
-rw-rw-r-- 1 pihole pihole 4767744 May  4 18:44 gravity.db
-rw-r--r-- 1 root   root      1051 May  4 17:07 install.log
-rw-r--r-- 1 root   root   1653257 May  4 18:10 list.1.raw.githubusercontent.com.domains
-rw-r--r-- 1 root   root        95 May  4 17:07 list.1.raw.githubusercontent.com.domains.sha1
-rw-r--r-- 1 root   root        20 May  4 18:50 localbranches
-rw-r--r-- 1 root   root        46 May  4 18:10 local.list
-rw-r--r-- 1 root   root        46 May  4 18:50 localversions
-rw-r--r-- 1 root   root       234 May  4 17:07 logrotate
-rw-r--r-- 1 pihole pihole 2662400 May  4 16:40 macvendor.db
drwxr-xr-x 2 root   root      4096 May  4 16:41 migration_backup
-rw-rw-r-- 1 pihole root        15 May  4 17:07 pihole-FTL.conf
-rw-rw-r-- 1 pihole pihole  225280 May  4 18:51 pihole-FTL.db
-rw-r--r-- 1 root   root       317 May  4 17:07 setupVars.conf
-rw-r--r-- 1 root   root       317 May  4 17:07 setupVars.conf.update.bak

Initially when you experienced the read only database error, only thing amiss probably was the www-data user not being a member of the pihole group.
And the usermod -a -G pihole www-data command should have fixed that:

pi@ph5a:~ $ groups www-data
www-data : www-data pihole

I dont know why you run apache2 instead of the default lighttpd daemon but ... when you performed the chown and chmod commands on the html folder, you messed up ownership/permissions recursively (the -R argument) for all files and folders contained whitin.
Privies originally looks like below and are not all 755 or owned by a single user:

pi@ph5a:~ $ sudo find /var/www/ -exec stat -c "%U:%G - %a - %F - %n" {} \;
root:root - 755 - directory - /var/www/
www-data:www-data - 775 - directory - /var/www/html
root:root - 755 - directory - /var/www/html/admin
root:root - 644 - regular file - /var/www/html/admin/.gitignore
root:root - 644 - regular file - /var/www/html/admin/.gitattributes
root:root - 644 - regular file - /var/www/html/admin/taillog.php
root:root - 644 - regular file - /var/www/html/admin/queries.php
root:root - 644 - regular file - /var/www/html/admin/groups-domains.php
root:root - 644 - regular file - /var/www/html/admin/package.json
root:root - 644 - regular file - /var/www/html/admin/composer.json
root:root - 644 - regular file - /var/www/html/admin/gravity.php
root:root - 644 - regular file - /var/www/html/admin/messages.php
root:root - 644 - regular file - /var/www/html/admin/debug.php
root:root - 644 - regular file - /var/www/html/admin/db_queries.php
root:root - 644 - regular file - /var/www/html/admin/groups-adlists.php
root:root - 755 - directory - /var/www/html/admin/.git
root:root - 755 - directory - /var/www/html/admin/.git/logs
root:root - 755 - directory - /var/www/html/admin/.git/logs/refs
root:root - 755 - directory - /var/www/html/admin/.git/logs/refs/remotes
root:root - 755 - directory - /var/www/html/admin/.git/logs/refs/remotes/origin
root:root - 644 - regular file - /var/www/html/admin/.git/logs/refs/remotes/origin/master
root:root - 644 - regular file - /var/www/html/admin/.git/logs/refs/remotes/origin/HEAD
root:root - 755 - directory - /var/www/html/admin/.git/logs/refs/heads
root:root - 644 - regular file - /var/www/html/admin/.git/logs/refs/heads/master
root:root - 644 - regular file - /var/www/html/admin/.git/logs/HEAD
root:root - 644 - regular file - /var/www/html/admin/.git/config
root:root - 755 - directory - /var/www/html/admin/.git/objects
root:root - 755 - directory - /var/www/html/admin/.git/objects/pack
root:root - 444 - regular file - /var/www/html/admin/.git/objects/pack/pack-d2d54e7051924dfb286995bec2f7513701353599.idx
root:root - 444 - regular file - /var/www/html/admin/.git/objects/pack/pack-90c91a9ed084c31631133788ba015247cad2c46d.pack
root:root - 444 - regular file - /var/www/html/admin/.git/objects/pack/pack-90c91a9ed084c31631133788ba015247cad2c46d.idx
root:root - 444 - regular file - /var/www/html/admin/.git/objects/pack/pack-d2d54e7051924dfb286995bec2f7513701353599.pack
root:root - 755 - directory - /var/www/html/admin/.git/objects/info
root:root - 644 - regular file - /var/www/html/admin/.git/packed-refs
root:root - 644 - regular file - /var/www/html/admin/.git/description
root:root - 755 - directory - /var/www/html/admin/.git/info
root:root - 644 - regular file - /var/www/html/admin/.git/info/exclude
root:root - 755 - directory - /var/www/html/admin/.git/hooks
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/pre-push.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/fsmonitor-watchman.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/prepare-commit-msg.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/pre-applypatch.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/pre-commit.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/commit-msg.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/pre-rebase.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/post-update.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/update.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/pre-receive.sample
root:root - 755 - regular file - /var/www/html/admin/.git/hooks/applypatch-msg.sample
root:root - 755 - directory - /var/www/html/admin/.git/refs
root:root - 755 - directory - /var/www/html/admin/.git/refs/tags
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.3.1
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.4
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v4.3.2
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.2
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v4.3
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v4.1
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.1.1
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v4.1.1
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.5
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.3
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v4.0
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.2.1
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.0
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.2.2
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v3.2.1
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.1
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v3.3
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v4.3.3
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v4.2
root:root - 644 - regular file - /var/www/html/admin/.git/refs/tags/v5.3.2
root:root - 755 - directory - /var/www/html/admin/.git/refs/remotes
root:root - 755 - directory - /var/www/html/admin/.git/refs/remotes/origin
root:root - 644 - regular file - /var/www/html/admin/.git/refs/remotes/origin/master
root:root - 644 - regular file - /var/www/html/admin/.git/refs/remotes/origin/HEAD
root:root - 755 - directory - /var/www/html/admin/.git/refs/heads
root:root - 644 - regular file - /var/www/html/admin/.git/refs/heads/master
root:root - 644 - regular file - /var/www/html/admin/.git/FETCH_HEAD
root:root - 644 - regular file - /var/www/html/admin/.git/ORIG_HEAD
root:root - 644 - regular file - /var/www/html/admin/.git/shallow
root:root - 644 - regular file - /var/www/html/admin/.git/index
root:root - 755 - directory - /var/www/html/admin/.git/branches
root:root - 644 - regular file - /var/www/html/admin/.git/HEAD
root:root - 644 - regular file - /var/www/html/admin/auditlog.php
root:root - 644 - regular file - /var/www/html/admin/cname_records.php
root:root - 644 - regular file - /var/www/html/admin/groups.php
root:root - 644 - regular file - /var/www/html/admin/index.php
root:root - 644 - regular file - /var/www/html/admin/db_graph.php
root:root - 644 - regular file - /var/www/html/admin/README.md
root:root - 755 - directory - /var/www/html/admin/.github
root:root - 644 - regular file - /var/www/html/admin/.github/PULL_REQUEST_TEMPLATE.md
root:root - 755 - directory - /var/www/html/admin/.github/workflows
root:root - 644 - regular file - /var/www/html/admin/.github/workflows/codeql.yml
root:root - 644 - regular file - /var/www/html/admin/.github/workflows/test.yml
root:root - 644 - regular file - /var/www/html/admin/.github/workflows/phpstan.yml
root:root - 644 - regular file - /var/www/html/admin/.github/ISSUE_TEMPLATE.md
root:root - 644 - regular file - /var/www/html/admin/.user.php.ini
root:root - 644 - regular file - /var/www/html/admin/groups-clients.php
root:root - 755 - directory - /var/www/html/admin/img
root:root - 755 - directory - /var/www/html/admin/img/favicons
root:root - 644 - regular file - /var/www/html/admin/img/favicons/favicon.ico
root:root - 644 - regular file - /var/www/html/admin/img/favicons/android-chrome-512x512.png
root:root - 644 - regular file - /var/www/html/admin/img/favicons/manifest.json
root:root - 644 - regular file - /var/www/html/admin/img/favicons/apple-touch-icon.png
root:root - 644 - regular file - /var/www/html/admin/img/favicons/safari-pinned-tab.svg
root:root - 644 - regular file - /var/www/html/admin/img/favicons/favicon-32x32.png
root:root - 644 - regular file - /var/www/html/admin/img/favicons/android-chrome-192x192.png
root:root - 644 - regular file - /var/www/html/admin/img/favicons/mstile-150x150.png
root:root - 644 - regular file - /var/www/html/admin/img/favicons/favicon-16x16.png
root:root - 644 - regular file - /var/www/html/admin/img/logo.svg
root:root - 644 - regular file - /var/www/html/admin/img/boxed-bg.jpg
root:root - 644 - regular file - /var/www/html/admin/img/boxed-bg-dark.jpg
root:root - 644 - regular file - /var/www/html/admin/img/donate.gif
root:root - 755 - directory - /var/www/html/admin/style
root:root - 755 - directory - /var/www/html/admin/style/themes
root:root - 644 - regular file - /var/www/html/admin/style/themes/default-light.css
root:root - 644 - regular file - /var/www/html/admin/style/themes/default-darker.css
root:root - 644 - regular file - /var/www/html/admin/style/themes/default-dark.css
root:root - 644 - regular file - /var/www/html/admin/style/pi-hole.css
root:root - 755 - directory - /var/www/html/admin/style/vendor
root:root - 644 - regular file - /var/www/html/admin/style/vendor/js-warn.css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/icheck-material.min.css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/datatables.min.css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/animate.min.css
root:root - 755 - directory - /var/www/html/admin/style/vendor/SourceSansPro
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-600italic.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-300italic.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-700.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-300.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-regular.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-600italic.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-600.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-300italic.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-300.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-700.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/SourceSansPro.css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-regular.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-600.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-italic.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/SourceSansPro/source-sans-pro-v13-latin-italic.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/AdminLTE.min.css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/icheck-bootstrap.min.css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/select2.min.css
root:root - 755 - directory - /var/www/html/admin/style/vendor/font-awesome
root:root - 755 - directory - /var/www/html/admin/style/vendor/font-awesome/js
root:root - 644 - regular file - /var/www/html/admin/style/vendor/font-awesome/js/all.min.js
root:root - 644 - regular file - /var/www/html/admin/style/vendor/daterangepicker.min.css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/LICENSE
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap-select.min.css
root:root - 755 - directory - /var/www/html/admin/style/vendor/bootstrap
root:root - 755 - directory - /var/www/html/admin/style/vendor/bootstrap/js
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/js/bootstrap.min.js
root:root - 755 - directory - /var/www/html/admin/style/vendor/bootstrap/css
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/css/bootstrap.min.css.map
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/css/bootstrap.min.css
root:root - 755 - directory - /var/www/html/admin/style/vendor/bootstrap/fonts
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/fonts/glyphicons-halflings-regular.svg
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/fonts/glyphicons-halflings-regular.woff
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/fonts/glyphicons-halflings-regular.ttf
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/fonts/glyphicons-halflings-regular.woff2
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap/fonts/glyphicons-halflings-regular.eot
root:root - 644 - regular file - /var/www/html/admin/style/vendor/bootstrap-toggle.min.css
root:root - 644 - regular file - /var/www/html/admin/settings.php
root:root - 755 - directory - /var/www/html/admin/scripts
root:root - 755 - directory - /var/www/html/admin/scripts/pi-hole
root:root - 755 - directory - /var/www/html/admin/scripts/pi-hole/php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/teleporter.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/gravity.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/update_checker.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/debug.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/savesettings.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/auth.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/FTL.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/header.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/groups.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/theme.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/footer.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/gravity.sh.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/database.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/func.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/loginpage.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/queryads.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/password.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/customcname.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/customdns.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/api_token.php
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/php/tailLog.php
root:root - 755 - directory - /var/www/html/admin/scripts/pi-hole/js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/customdns.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/db_queries.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/messages.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/taillog.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/footer.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/queryads.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/ip-address-sorting.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/db_graph.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/db_lists.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/debug.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/groups-adlists.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/gravity.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/utils.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/settings.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/taillog-FTL.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/auditlog.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/groups-clients.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/queries.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/customcname.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/groups-domains.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/index.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/network.js
root:root - 644 - regular file - /var/www/html/admin/scripts/pi-hole/js/groups.js
root:root - 755 - directory - /var/www/html/admin/scripts/vendor
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/daterangepicker.min.js.map
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/select2.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/bootstrap-select.min.js.map
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/adminlte.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/moment.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/bootstrap-select.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/bootstrap-notify.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/jquery.confirm.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/datatables.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/Chart.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/daterangepicker.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/jquery.min.js
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/qrcode.php
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/LICENSE
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/bootstrap-toggle.min.js.map
root:root - 644 - regular file - /var/www/html/admin/scripts/vendor/bootstrap-toggle.min.js
root:root - 644 - regular file - /var/www/html/admin/api_db.php
root:root - 644 - regular file - /var/www/html/admin/api_FTL.php
root:root - 644 - regular file - /var/www/html/admin/db_lists.php
root:root - 644 - regular file - /var/www/html/admin/package-lock.json
root:root - 644 - regular file - /var/www/html/admin/queryads.php
root:root - 644 - regular file - /var/www/html/admin/dns_records.php
root:root - 644 - regular file - /var/www/html/admin/network.php
root:root - 644 - regular file - /var/www/html/admin/CONTRIBUTING.md
root:root - 644 - regular file - /var/www/html/admin/api.php
root:root - 644 - regular file - /var/www/html/admin/LICENSE
root:root - 644 - regular file - /var/www/html/admin/phpstan.neon.dist
root:root - 644 - regular file - /var/www/html/admin/composer.lock
root:root - 644 - regular file - /var/www/html/admin/taillog-FTL.php
root:root - 755 - directory - /var/www/html/pihole
root:root - 644 - regular file - /var/www/html/pihole/index.php
root:root - 644 - regular file - /var/www/html/pihole/blockingpage.css
root:root - 644 - regular file - /var/www/html/index.lighttpd.orig

Try fix that first.
For the admin folder, you could try below to delete and pull the files/folders fresh from Gitub:

And aftrerwards check the apache2 logs live for errors/warnings when trying to white/blacklist at the same time:

sudo tail -F /var/log/apache2/{access,error}.log

I dont have apache2 running on my Pi-hole host so am not sure if there are other requirements.

1 Like

Thank You... I was lost in the forest...
OK so 'fresh' pihole -up on 'clean' sd card.
Verified 'usermod -a -G pihole www-data ' (only) writes whitelist BUT gives error something went wrong

sudo tail -F /var/log/apache2/{access,error}.log

    • 'Uncaught Error: Call to undefined function utf8_encode() in /var/www/html/admin/api_FTL.php:393\nStack trace:\n#0 /var/www/html/admin/api.php(165): require()\n#1 {main}\n thrown in /var/www/html/admin/api_FTL.php on line 393,'

Which was fixed by - - "Client activity is empty, Query Log error" - - sudo apt-get install php-xml

Again, thank you - all resolved.

1 Like

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