Login to GUI issue (not password error just redirects back to login page)

Expected Behaviour:
browse to http://pihole-02/admin/index.php?login enter the password and click login. Should then be redirected back to main page with additonal menu options down the left side.
Ubuntu 16.04.6 LTS (GNU/Linux 4.4.0-145-generic x86_64)
HP Server Running VSPHERE virtual machines

Actual Behaviour:
sent back to login page. If I press ctrl and enter at login page it looks like it logs in but then when I try to use any of the menu options (IE update gravity lists) it sends me back to login page.

I ran sudo apt-get update which afterwards allowed me to login once and generate the debug log but afterwards the same thing is happening.

I have another pihole which is practically identical and that works fine. I have tried to restart the pihole

On the dashboard page where I would expect to see stats of queries they are just showing -- except for Percent Blocked shows 'Undefined %'
Here a screen shot from the Dashboard
Pihole 2

Debug Token:

This is a common symptom of a disk filled to the brim. PHP won't be able to store a new session for you so the login can never succeed even if it was successful. Please verify that you have space available, using, e.g. df -h


Looks like /dev/sda1 is full. Whats the best most effective way to reduce this?

Filesystem      Size  Used Avail Use% Mounted on
udev            2.0G     0  2.0G   0% /dev
tmpfs           396M  5.7M  390M   2% /run
/dev/sda1        12G   12G     0 100% /
tmpfs           2.0G  4.8M  2.0G   1% /dev/shm
tmpfs           5.0M     0  5.0M   0% /run/lock
tmpfs           2.0G     0  2.0G   0% /sys/fs/cgroup
tmpfs           396M     0  396M   0% /run/user/1000


PS love the doggo :wink:

If you already have the tool ncdu, you can use this to get a nice graphical overview of what is using up the space. If you don't have this too, try the following command:

sudo du -a / 2> /dev/null | sort -n -r | head -n 100

It will scan all files on your system and sort them by size (in bytes). The output will be the largest 100 files (and directories). You can use this to check what you want to delete to make free space. Note that the command may need some time to finish entirely depending on the speed of your disk.

Thanks but I'm still unsure whats safe to delete and what I need to keep.

Below is the output of that command. Any clues what I can and cannot delete?

11471092        /
9647588 /etc
9632080 /etc/pihole
9618192 /etc/pihole/pihole-FTL.db
726096  /lib
594412  /usr
435516  /lib/modules
353216  /var
274476  /usr/lib
248528  /var/lib
240932  /lib/firmware
218040  /var/lib/apt
217988  /var/lib/apt/lists
217784  /lib/modules/4.4.0-145-generic
217728  /lib/modules/4.4.0-142-generic
213088  /lib/modules/4.4.0-145-generic/kernel
213032  /lib/modules/4.4.0-142-generic/kernel
190908  /usr/share
151520  /lib/modules/4.4.0-145-generic/kernel/drivers
151508  /lib/modules/4.4.0-142-generic/kernel/drivers
117512  /usr/bin
108508  /boot
99484   /usr/lib/x86_64-linux-gnu
72848   /usr/lib/snapd
53644   /var/log
40836   /var/lib/apt/lists/gb.archive.ubuntu.com_ubuntu_dists_xenial_universe_binary-amd64_Packages
40700   /var/www
40696   /var/www/html
40676   /var/lib/apt/lists/gb.archive.ubuntu.com_ubuntu_dists_xenial_universe_binary-i386_Packages
40652   /var/www/html/admin
38936   /boot/initrd.img-4.4.0-145-generic
38936   /boot/initrd.img-4.4.0-142-generic
35580   /var/www/html/admin/.git
35112   /var/www/html/admin/.git/objects
34468   /lib/modules/4.4.0-145-generic/kernel/drivers/net
34460   /lib/modules/4.4.0-142-generic/kernel/drivers/net
34184   /var/www/html/admin/.git/objects/pack
30084   /usr/share/vim
30064   /usr/share/vim/vim74
28892   /usr/share/locale
27740   /var/lib/dpkg
26384   /var/lib/dpkg/info
25308   /usr/lib/x86_64-linux-gnu/libicudata.so.55.1
24852   /lib/x86_64-linux-gnu
24568   /usr/lib/python3.5
24028   /usr/lib/snapd/snapd
23144   /var/www/html/admin/.git/objects/pack/pack-6d630d63739247a1e36b8d7b4c52eb89150839d2.pack
22884   /var/lib/apt/lists/gb.archive.ubuntu.com_ubuntu_dists_xenial_universe_i18n_Translation-en
20784   /usr/lib/python2.7
20672   /usr/share/doc
19548   /usr/share/perl
19544   /usr/share/perl/5.22.1
19236   /lib/firmware/netronome
19144   /usr/lib/x86_64-linux-gnu/perl
19144   /lib/modules/4.4.0-142-generic/kernel/drivers/media
19140   /lib/modules/4.4.0-145-generic/kernel/drivers/media
19092   /usr/lib/x86_64-linux-gnu/perl/5.22.1
19064   /usr/bin/snap
17556   /var/log/auth.log
17388   /lib/modules/4.4.0-145-generic/kernel/net
17388   /lib/modules/4.4.0-142-generic/kernel/net
16760   /lib/modules/4.4.0-145-generic/kernel/fs
16728   /lib/modules/4.4.0-142-generic/kernel/fs
16172   /usr/lib/git-core
16012   /bin
15520   /var/lib/apt/lists/gb.archive.ubuntu.com_ubuntu_dists_xenial_universe_i18n_Translation-en%5fGB
15304   /lib/firmware/brcm
14648   /var/log/installer
14416   /usr/bin/pihole-FTL
14408   /lib/modules/4.4.0-145-generic/kernel/drivers/net/wireless
14408   /lib/modules/4.4.0-142-generic/kernel/drivers/net/wireless
14268   /lib/firmware/amdgpu
14052   /lib/modules/4.4.0-145-generic/kernel/sound
14052   /lib/modules/4.4.0-142-generic/kernel/sound
14036   /usr/share/man
13964   /lib/modules/4.4.0-145-generic/kernel/drivers/net/ethernet
13964   /lib/modules/4.4.0-142-generic/kernel/drivers/net/ethernet
13952   /var/log/installer/cdebconf
13832   /var/log/installer/cdebconf/templates.dat
13644   /usr/lib/snapd/snap-repair
13484   /sbin
13236   /usr/lib/snapd/snapctl
13220   /usr/share/i18n
12992   /usr/lib/x86_64-linux-gnu/perl/5.22.1/auto
12540   /lib/udev
11640   /usr/bin/lxd
11452   /lib/firmware/intel
11296   /lib/modules/4.4.0-145-generic/kernel/drivers/gpu
11292   /lib/modules/4.4.0-145-generic/kernel/drivers/gpu/drm
11292   /lib/modules/4.4.0-142-generic/kernel/drivers/gpu
11288   /lib/modules/4.4.0-142-generic/kernel/drivers/gpu/drm
11272   /lib/modules/4.4.0-145-generic/kernel/drivers/scsi
11272   /lib/modules/4.4.0-142-generic/kernel/drivers/scsi
10868   /usr/sbin
10820   /lib/modules/4.4.0-145-generic/kernel/drivers/staging
10820   /lib/modules/4.4.0-142-generic/kernel/drivers/staging
10740   /var/lib/apt/lists/gb.archive.ubuntu.com_ubuntu_dists_xenial-updates_main_binary-amd64_Packages
10600   /var/log/syslog
10168   /lib/systemd
9832    /usr/share/i18n/locales


You have a long-term database that is almost 10 GB is size. For an operating system on a 12 GB disk, this is clearly too much.

Suggestion 1: Simply increase the disk size of your virtualization (perfered)
Suggestion 2: Remove the database, restart Pi-hole and set a limit for MAXDBDAYS to something small (maybe 30 days).

Thank you very much.

For now I've removed the DB. I'll look into expanding the HDD size. on the VM its easy I just need to figure out how to do it Linux commands...