Cannot access admin page for my pihole

Just finished installing Pi Hole, everything was working fine. After unplugging my Pi and moving it closer to my router, I still cannot access the webpage. After trying to do some digging here, I ran pihole -r, and it doesn't give me an option to ‘repair or reconfigure anything. My Pi seems to have no “lighttpd” because everything I try with that doesn't fix it. Please help!!!

Expected Behaviour:

Able to log onto my admin page

Actual Behaviour:

Hmmm… can't reach this page
192.168.0.178 refused to connect.
Try:

Search the web for 192 168 0 178
Checking the connection
Checking the proxy and the firewall
ERR_CONNECTION_REFUSED

Debug Token:

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

Your debug log shows the web server didn't start and FTL encountered some errors:

FTL.log shows your database is corrupted:

2026-03-29 19:07:03.374 EDT [16032M] ERROR: SQLite3: recovered 1 frames from WAL file /etc/pihole/pihole-FTL.db-wal (283)
2026-03-29 19:07:03.374 EDT [16032M] INFO: Database version is 21
2026-03-29 19:07:03.379 EDT [16032M] INFO: Database successfully initialized
2026-03-29 19:07:03.381 EDT [16032M] ERROR: SQLite3: database corruption at line 74493 of [b270f8339e] (11)
2026-03-29 19:07:03.381 EDT [16032M] ERROR: SQLite3: database corruption at line 74667 of [b270f8339e] (11)
2026-03-29 19:07:03.381 EDT [16032M] ERROR: SQLite3: statement aborts at 3: database disk image is malformed; [SELECT MAX(id) FROM disk.query_storage] (11)
2026-03-29 19:07:03.381 EDT [16032M] ERROR: init_disk_db_idx(): Failed to get MAX(id) from disk.query_storage: database disk image is malformed
2026-03-29 19:07:03.387 EDT [16032M] ERROR: SQLite3: database corruption at line 74493 of [b270f8339e] (11)
2026-03-29 19:07:03.387 EDT [16032M] ERROR: SQLite3: database corruption at line 74667 of [b270f8339e] (11)
2026-03-29 19:07:03.387 EDT [16032M] ERROR: SQLite3: statement aborts at 6: database disk image is malformed; [SELECT COUNT(*) FROM disk.query_storage WHERE timestamp BETWEEN ? AND ?] (11)
2026-03-29 19:07:03.387 EDT [16032M] ERROR: db_query_int_from_until(SELECT COUNT(*) FROM disk.query_storage WHERE timestamp BETWEEN ? AND ?) - SQL error step (11): database disk image is malformed
2026-03-29 19:07:03.387 EDT [16032M] WARNING: Could not fallocate() in realloc_shm() (/app/src/shmem.c:866): No space left on device
2026-03-29 19:07:03.387 EDT [16032M] CRIT: realloc_shm(): Failed to resize "/FTL-16032-queries" (10) to 309238824960: No space left on device (28)

The log above also says No space left on device, but apparently this is not the case (the debug log shows there is plenty space). This can indicate a files system error.

Also, your pihole.log is completely corrupted, showing many invalid characters:

   -----tail of pihole.log------
   Ј�X���qt��Vߟ(�d��h�C�:j��"�iFp�|1�T����{�L�'Er�P��n�ξ��D��Qr]0����b?i�mW��ȏ�+/@����Њ��u:7 (...)
   (...)

I suspect the entire filesystem is corrupted.

You should try to reinstall the OS, preferably using a new SD card, if available.

Notes unrelated to your issue:

The command pihole -r should be used to recover / reinstall Pi-hole files, but nothing else on your system (like network interfaces, ports, users) will be changed.

This is expected.

Pi-hole doesn't use lighttpd.

Old versions (Pi-hole v5 and previous versions) used lighttpd as web server, but since February 2025, Pi-hole v6 has its own embedded web server.

Yea that makes sense i used a cheap sd card i got off some rando website :joy::joy:. But now what I got to reinstall the OS do i need to start from square 1? And redo all the changes i made to make my ip static?

  • Buy new microSDXC card.
  • Flash Raspberry Pi OS based on Debian 13 a.k.a. Trixie
  • Connect Raspberry Pi to a Monitor and attach a Keyboard.
  • Configure the New User.
  • Configure the Static IP Address.
  • apt update && apt upgrade -y
  • Enable OpenSSH Server
  • Install Pi-Hole v6
  • Do whatever you have to do in the Pi-Hole webGUI.

Enjoy your Ads Free LAN :smiling_face_with_sunglasses::grimacing::+1::+1:

Do I need to connect a mouse and keyboard to the Pi and set everything up manually? When I try to SSH into the Pi, I just get “connection refused,” even after changing the static IP in my DHCP server configuration on my router.

I did not typ the above instructions without a reason you know :wink:

A lot has changed the last couple of years when setting up a Raspberry Pi OS installation and because I am fed up with all the weirdness from the Raspberry Pi Foundation I have switched to the above basic method that simply works and I suggest you try it too! :grimacing:

In the past I used a totally different more advanced approach, but that does not seem to work reliably anymore so I don’t do that anymore…
And their flashing tool has become a mess according to a lot of people on their own Blog and Forum so that’s out of the question too!

1 Like

You have to enable ssh while writing the image.

There are 2 ways to do that:

  1. Raspberry Pi Imager:
  • In the Raspberry Pi Imager, after selecting your OS and Storage, click the Settings icon (the gear) or press Ctrl + Shift + X
  • Check the box for "Enable SSH"
  1. The headless way
  • Write the image to the sd-card
  • Put it into your computer
  • Open the partition named boot or bootfs
  • Create a completely empty file named simply ssh
  • Eject
  • Put the card in you pi and boot

ssh is now enabled

1 Like

Or after writing, boot up, and run below on console:

sudo systemctl enable --now ssh.service

2 Likes

If its a Pi and you're experiencing files getting corrupted, the power supply is the first suspect:

Low quality power supplies can corrupt storage or cause unpredictable behaviour within the Raspberry Pi.

https://www.raspberrypi.com/documentation/computers/raspberry-pi.html#power-supply-warnings

1 Like

lol yea I just didn’t have a keyboard cause I use a laptop. I one of those guys lol. I can get one the no biggie. And yea after doing research ive seen people say the imager is broken when I comes to ssh. There was a long thread that ended in the beginning of the year where an engineer said he brought it up. But I guess nothing came from it.

1 Like

I did this both ways before I asked and nothing worked :smiling_face_with_tear:

1 Like

I got a crappy sd card from some random website, so that’s what we’re contributing to the file corruption too. I can double-check the power supply, though. I just got it, so it should be fine.

I don’t think can run sudo in command prompt but will try this.

Assumption is the mother of all f*ups!

EDIT: Oh stupid of me, when on console and you know the root password, you can login with that and enable ssh.service without sudo.
Only root logins via SSH (via network) are not allowed.

Disregard below :wink:


You should be able to.
Or else become the root user with below if you know the root password:

su -

And run it without sudo.

FYI:

$ man su
[..]
DESCRIPTION
       su allows commands to be run with a substitute user and group ID.

       When called with no user specified, su defaults to running an
       interactive shell as root. When user is specified, additional
       arguments can be supplied, in which case they are passed to the
       shell.
[..]
OPTIONS
[..]
       -, -l, --login
           Start the shell as a login shell with an environment similar to
           a real login:

           •   clears all the environment variables except TERM and
               variables specified by --whitelist-environment

           •   initializes the environment variables HOME, SHELL, USER,
               LOGNAME, and PATH

           •   changes to the target user’s home directory

           •   sets argv[0] of the shell to '-' in order to make the shell
               a login shell
1 Like
$ man sshd_config
[..]
     PermitRootLogin
             Specifies whether root can log in using ssh(1).  The argument
             must be yes, prohibit-password, forced-commands-only, or no.
             The default is prohibit-password.

             If this option is set to prohibit-password (or its deprecated
             alias, without-password), password and keyboard-interactive
             authentication are disabled for root.
$ grep PermitRootLogin /etc/ssh/sshd_config
#PermitRootLogin prohibit-password
# the setting of "PermitRootLogin prohibit-password".
1 Like

Piimager offers all you need.
User, password, wifi name, wifi password, ssh, sdh password.

Keep simple things simple.