I'm on DietPi (Debian based) and am using nginx as a webserver. I also used their script to install Pi-hole. But I strongly doubt that that's the issue.
Expected Behaviour:
I enter some settings on the webinterface and click on save. I expect those settings to be applied and be saved.
If I click on Generate Debug Log, I expect a debug log to be generated and the token to be displayed.
Actual Behaviour:
Settings aren't applied not saved. If I change the theme to dark layout, the dark layout is applied for like 10 seconds and then jumps back to bright layout.
Clicking on Generate Debug Log doesn't seem to do anything. The button is just grayed out, but no text is coming up.
Nginx is not a supported web server for Pi-hole. Also, DietPi has a different implementation of the web server. Your best source for a solution may be here:
I solved the problem. The solution was to set the setuid-bit of /usr/bin/sudo via chmod u+s /usr/bin/sudo. www-data was correctly registered in the sudoers file but couldn't execute the sudo command because of the missing bit.
My question is now: Do you have an idea why this bit was missing? Could it be a bug in DietPi?
I converted my root file system to btrfs a while ago. My only other explanation for the missing bit is that the conversion caused the loss of a bit.
Now I'm quite sure that I screwed up during the btrfs partition creation. I formatted the partition manually and copied the data from the original ext4 partition to btrfs. I should have used --preserve=all as argument for cp to keep things like a setuid-bit