mombro
February 8, 2023, 9:01pm
1
Please follow the below template, it will help us to help you!
Expected Behaviour:
First example:
I go to "Clients"
I select some known client and add a comment
I click on "Add"
The client is added to the list
Second example:
I go to domains
I enter www.googleads.com and add a comment
I click on "Add to Whitelist"
www.googleads.com is added to the list of domains below
Actual Behaviour:
I receive an error message in red on the top-right corner, saying:
" Error, something went wrong!
While executing INSERT OR IGNORE: attempt to write a readonly database
Added 0 out of 1 domains"
Debug Token:
I cannot add the debug token as the output contains sensitive data. I instead uploaded the file here.
Any idea what I did wrong or how I can mount the database read/write?
I do have read this
while I tried to change status of whitelist entry I got this error.
my config;
ubuntu 18.04 5.3.0-1021-raspi2 (raspberry 4)
apache 2.4.29
php 7.4.6
ownership of /etc/.pihole = root
ownership of /etc/pihole = pihole
ownership of /var/www/html/admin = www-data
I also add user www-data to pihole group
permission of pihole-FTL.db = 0644
ownership of pihole-FTL.db = pihole all
I still can't change whitelist status?
and that
Installation went fine, and everything seems to work properly, except for the Group Management area. If I try to change anything relating to a group or client or domain, I get a message: "Error, something went wrong! While executing: attempt to write a readonly database."
[11%20PM]
To make sure this wasn't related to something I'd done to my install (I run an Nginx reverse proxy in front of it), I uninstalled Pihole completely, then reinstalled the latest stable version, then upgraded to the b…
and also this
https://github.com/pi-hole/docker-pi-hole/issues/860
I also tried to add my user "pi" to the group "www-data" as well as the user "pihole":
$ cat /etc/group |grep www
www-data:x:33:pihole
pi:x:1000:www-data
pihole:x:1001:www-data
# not sure which is correct, so i did both:
$ sudo usermod -aG pihole www-data
$ sudo usermod -aG www-data pihole
$ sudo reboot
[wait]
$ groups pihole
pihole : pihole www-data
Still, problem persists
Any idea what might have gone wrong? I have a pretty default installation here, nothing fancy
Edit: File removed by staff.
The uploaded version is only accessible to the developers and support staff. The file here is available to anyone and everyone.
mombro
February 9, 2023, 5:29am
4
I think it would be great if the pihole and the forum would say that, too
The log is here: https://tricorder.pi-hole.net/A57JzIWk/
jfb
February 9, 2023, 5:49am
6
The third line of your debug log:
"NOTE: All log files auto-delete after 48 hours and ONLY the Pi-hole developers can access your data via the given token. We have taken these extra steps to secure your data and will work to further reduce any personal information gathered."
The pihole -d
command does mention that ("The debug log can be uploaded to tricorder.pi-hole.net for sharing with developers only. ") but the web admin text doesn't. It does come up now and again where people are concerned about the log content. Could the web admin text be tweaked to also mention it, something like "The URL token will be shown at the end of the report, once finished. Only Pi-hole developers have access to debug logs and they are automatically deleted after 48 hours. "?
mombro
February 12, 2023, 10:49am
8
I looked up the ownerships as mentioned here:
make sure the ownerhips are correct in directory /etc/pihole. (you can find right ownership list @deHakkelaar post below.)
usermod -aG pihole www-data
reboot
this solved my problem. some of the files owned by root and that's why readonly error occured.
and they seem correct:
$ stat -c "%U:%G %a %n" /etc/pihole/* | column -t
root:root 644 /etc/pihole/adlists.list
root:root 644 /etc/pihole/adlists.list.old
root:root 644 /etc/pihole/custom.list
pihole:pihole 644 /etc/pihole/dhcp.leases
root:root 644 /etc/pihole/dns-servers.conf
pihole:pihole 664 /etc/pihole/gravity.db
pihole:pihole 664 /etc/pihole/gravity_old.db
root:root 644 /etc/pihole/install.log
root:root 644 /etc/pihole/list.10.v.firebog.net.domains
root:root 644 /etc/pihole/list.10.v.firebog.net.domains.sha1
root:root 644 /etc/pihole/list.11.pgl.yoyo.org.domains
root:root 644 /etc/pihole/list.11.pgl.yoyo.org.domains.sha1
root:root 644 /etc/pihole/list.13.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.13.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.14.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.14.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.15.www.technoy.de.domains
root:root 644 /etc/pihole/list.15.www.technoy.de.domains.sha1
root:root 644 /etc/pihole/list.16.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.16.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.17.www.technoy.de.domains
root:root 644 /etc/pihole/list.17.www.technoy.de.domains.sha1
root:root 644 /etc/pihole/list.18.www.technoy.de.domains
root:root 644 /etc/pihole/list.18.www.technoy.de.domains.sha1
root:root 644 /etc/pihole/list.19.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.19.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.1.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.1.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.20.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.20.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.21.someonewhocares.org.domains
root:root 644 /etc/pihole/list.21.someonewhocares.org.domains.sha1
root:root 644 /etc/pihole/list.2.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.2.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.3.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.3.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.4.v.firebog.net.domains
root:root 644 /etc/pihole/list.4.v.firebog.net.domains.sha1
root:root 644 /etc/pihole/list.5.adaway.org.domains
root:root 644 /etc/pihole/list.5.adaway.org.domains.sha1
root:root 644 /etc/pihole/list.6.v.firebog.net.domains
root:root 644 /etc/pihole/list.6.v.firebog.net.domains.sha1
root:root 644 /etc/pihole/list.7.v.firebog.net.domains
root:root 644 /etc/pihole/list.7.v.firebog.net.domains.sha1
root:root 644 /etc/pihole/list.8.raw.githubusercontent.com.domains
root:root 644 /etc/pihole/list.8.raw.githubusercontent.com.domains.sha1
root:root 644 /etc/pihole/list.9.s3.amazonaws.com.domains
root:root 644 /etc/pihole/list.9.s3.amazonaws.com.domains.sha1
root:root 644 /etc/pihole/local.list
root:root 644 /etc/pihole/logrotate
pihole:pihole 644 /etc/pihole/macvendor.db
root:root 755 /etc/pihole/migration_backup
pihole:root 664 /etc/pihole/pihole-FTL.conf
pihole:pihole 664 /etc/pihole/pihole-FTL.db
root:root 644 /etc/pihole/setupVars.conf
root:root 644 /etc/pihole/versions
mombro
February 12, 2023, 12:35pm
9
Oh no ... I restarted the Pi and it instantly worked. I must have forgotten this ...
Sorry guys, and thanks for the help!
system
Closed
March 5, 2023, 12:35pm
10
This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.