PiHole Doesn't Start After upgrade to v6, pihole.toml missing

Expected Behaviour:

Pihole Migrates to v6 and starts.

Actual Behaviour:

Config File migration seems to have failed, /etc/pihole/pihole.toml doesn't exist. pihole -v shows wrong information

pi@pihole1:~ $ pihole -v
Core version is v5.18.4 (Latest: v5.18.4)
Web version is v5.21 (Latest: v5.21)
FTL version is v5.25.2 (Latest: v5.25.2)

But pihole -up thinks v6 is installed.

pi@pihole1:~ $ sudo pihole -up
  [✓] Supported OS detected
  [✓] Update local cache of available packages
  [✓] Building dependency package pihole-meta.deb
  [✓] Installing Pi-hole dependency package

  [i] Checking for updates...
  [i] Pi-hole Core:     up to date
  [i] Web Interface:    up to date
  [i] FTL:              up to date

  [✓] Everything is up to date!

Have tried using pihole -r to fix.

Running on Raspian 12

Debug Token:

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

You actually have v6 installed:

*** [ DIAGNOSING ]: Core version
[✓] Version: v6.0
[i] Remotes: origin	https://github.com/pi-hole/pi-hole.git (fetch)
             origin	https://github.com/pi-hole/pi-hole.git (push)
[i] Branch: master
[i] Commit: v6.0-0-g2d81552f

*** [ DIAGNOSING ]: Web version
[✓] Version: v6.0
[i] Remotes: origin	https://github.com/pi-hole/AdminLTE.git (fetch)
             origin	https://github.com/pi-hole/AdminLTE.git (push)
[i] Branch: master
[i] Commit: v6.0-0-ga66d859a

*** [ DIAGNOSING ]: FTL version
[✓] Version: v6.0
[i] Branch: master
[i] Commit: eaa7dbb4

But pihole.toml is actually missing.

We will check your log and answer as soon as we can.

Can you please run ls -la /etc/pihole and post the output here?

pi@pihole1:~ $ ls -la /etc/pihole/
total 1516740
drwxr-xr-x   5 pihole pihole       4096 Feb 18 13:38 .
drwxr-xr-x 107 root   root        12288 Feb 18 13:30 ..
-rw-r--r--   1 pihole pihole          0 Feb 18 13:20 04-pihole-static-dhcp.conf.gsb
-rw-r--r--   1 pihole pihole          0 Jul 19  2024 05-pihole-custom-cname.conf.gsb
-rw-r--r--   1 pihole pihole         65 Feb 18 13:38 adlists.list
-rw-r--r--   1 pihole pihole         65 Feb 14  2022 adlists.list.old
-rw-r--r--   1 pihole pihole        108 Nov 26 10:58 custom.list
-rw-r--r--   1 pihole pihole        108 Nov 26 11:00 custom.list.gsb
-rw-r--r--   1 pihole pihole          0 Apr  4  2022 dhcp.leases
-rw-r--r--   1 pihole pihole        651 Feb 17 19:28 dns-servers.conf
-rw-rw-r--   1 pihole pihole   81399808 Feb 17 19:30 gravity.db
-rw-r--r--   1 pihole pihole   81399808 Feb 17 19:46 gravity.db.gsb
-rw-rw-r--   1 pihole pihole   81784832 Feb 16 05:31 gravity_old.db
drwxr-xr-x   2 pihole pihole       4096 Feb 18 13:17 hosts
-rw-r--r--   1 pihole pihole        408 Feb 18 13:38 install.log
-rw-r--r--   1 pihole pihole     138405 Feb 17 19:29 list.10.adaway.org.domains
-rw-r--r--   1 pihole pihole         81 Feb 17 19:29 list.10.adaway.org.domains.sha1
-rw-r--r--   1 pihole pihole     936594 Feb 17 19:29 list.11.v.firebog.net.domains
-rw-r--r--   1 pihole pihole         84 Feb 17 19:29 list.11.v.firebog.net.domains.sha1
-rw-r--r--   1 pihole pihole    1013616 Feb 17 19:29 list.12.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:29 list.12.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole     499179 Feb 17 19:29 list.14.v.firebog.net.domains
-rw-r--r--   1 pihole pihole         84 Feb 17 19:29 list.14.v.firebog.net.domains.sha1
-rw-r--r--   1 pihole pihole      57427 Feb 17 19:29 list.15.pgl.yoyo.org.domains
-rw-r--r--   1 pihole pihole         83 Feb 17 19:29 list.15.pgl.yoyo.org.domains.sha1
-rw-r--r--   1 pihole pihole        204 Feb 17 19:29 list.16.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:29 list.16.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole     337345 Feb 17 19:29 list.17.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:29 list.17.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole     912523 Feb 17 19:29 list.18.v.firebog.net.domains
-rw-r--r--   1 pihole pihole         84 Feb 17 19:29 list.18.v.firebog.net.domains.sha1
-rw-r--r--   1 pihole pihole      70291 Feb 17 19:29 list.19.v.firebog.net.domains
-rw-r--r--   1 pihole pihole         84 Feb 17 19:29 list.19.v.firebog.net.domains.sha1
-rw-r--r--   1 pihole pihole    2679128 Feb 17 19:28 list.1.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         95 Feb 17 19:28 list.1.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole     217164 Feb 17 19:29 list.20.gitlab.com.domains
-rw-r--r--   1 pihole pihole         81 Feb 17 19:29 list.20.gitlab.com.domains.sha1
-rw-r--r--   1 pihole pihole      49889 Feb 17 19:29 list.21.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:29 list.21.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole       9366 Feb 17 19:29 list.22.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:29 list.22.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole   10972543 Feb 17 19:29 list.23.www.github.developerdan.com.domains
-rw-r--r--   1 pihole pihole         98 Feb 17 19:29 list.23.www.github.developerdan.com.domains.sha1
-rw-r--r--   1 pihole pihole     799161 Feb 17 19:29 list.24.hostfiles.frogeye.fr.domains
-rw-r--r--   1 pihole pihole         91 Feb 17 19:29 list.24.hostfiles.frogeye.fr.domains.sha1
-rw-r--r--   1 pihole pihole     650540 Feb 17 19:29 list.25.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:29 list.25.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole       2429 Feb 17 19:29 list.26.osint.digitalside.it.domains
-rw-r--r--   1 pihole pihole         91 Feb 17 19:29 list.26.osint.digitalside.it.domains.sha1
-rw-r--r--   1 pihole pihole      44078 Feb 17 19:29 list.27.s3.amazonaws.com.domains
-rw-r--r--   1 pihole pihole         87 Feb 17 19:29 list.27.s3.amazonaws.com.domains.sha1
-rw-r--r--   1 pihole pihole    2656363 Feb 17 19:29 list.29.v.firebog.net.domains
-rw-r--r--   1 pihole pihole         84 Feb 17 19:29 list.29.v.firebog.net.domains.sha1
-rw-r--r--   1 pihole pihole      43844 Feb 17 19:29 list.32.bitbucket.org.domains
-rw-r--r--   1 pihole pihole         84 Feb 17 19:29 list.32.bitbucket.org.domains.sha1
-rw-r--r--   1 pihole pihole    5584335 Feb 17 19:29 list.33.phishing.army.domains
-rw-r--r--   1 pihole pihole         84 Feb 17 19:30 list.33.phishing.army.domains.sha1
-rw-r--r--   1 pihole pihole       2423 Feb 17 19:30 list.34.gitlab.com.domains
-rw-r--r--   1 pihole pihole         81 Feb 17 19:30 list.34.gitlab.com.domains.sha1
-rw-r--r--   1 pihole pihole     146607 Feb 17 19:30 list.36.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:30 list.36.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole      40645 Feb 17 19:30 list.37.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         96 Feb 17 19:30 list.37.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole       5172 Feb 17 19:30 list.38.urlhaus.abuse.ch.domains
-rw-r--r--   1 pihole pihole         87 Feb 17 19:30 list.38.urlhaus.abuse.ch.domains.sha1
-rw-r--r--   1 pihole pihole     412329 Feb 17 19:28 list.3.sysctl.org.domains
-rw-r--r--   1 pihole pihole         80 Feb 17 19:28 list.3.sysctl.org.domains.sha1
-rw-r--r--   1 pihole pihole        521 Feb 17 19:28 list.4.s3.amazonaws.com.domains
-rw-r--r--   1 pihole pihole         86 Feb 17 19:28 list.4.s3.amazonaws.com.domains.sha1
-rw-r--r--   1 pihole pihole      43529 Feb 17 19:28 list.5.s3.amazonaws.com.domains
-rw-r--r--   1 pihole pihole         86 Feb 17 19:28 list.5.s3.amazonaws.com.domains.sha1
-rw-r--r--   1 pihole pihole          0 Feb 17 19:28 list.7.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         95 Feb 17 19:28 list.7.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole       1172 Feb 17 19:29 list.8.raw.githubusercontent.com.domains
-rw-r--r--   1 pihole pihole         95 Feb 17 19:29 list.8.raw.githubusercontent.com.domains.sha1
-rw-r--r--   1 pihole pihole       6898 Feb 17 19:29 list.9.v.firebog.net.domains
-rw-r--r--   1 pihole pihole         83 Feb 17 19:29 list.9.v.firebog.net.domains.sha1
-rw-r--r--   1 pihole pihole         65 Feb 17 19:30 local.list
-rw-r--r--   1 pihole pihole        358 Feb 18 13:18 logrotate
-rw-r--r--   1 pihole pihole    3256320 Feb 18 13:17 macvendor.db
drwxr-xr-x   2 pihole pihole       4096 Feb  9  2022 migration_backup
drwxr-xr-x   2 root   root         4096 Feb 18 13:25 migration_backup_v6
-rw-rw-r--   1 pihole pihole       1485 Feb 17 19:28 pihole-FTL.conf
-rw-rw-r--   1 pihole pihole 1276686336 Feb 18 13:17 pihole-FTL.db
-rw-r--r--   1 pihole pihole        732 Feb 17 19:28 setupVars.conf
-rw-r--r--   1 pihole pihole        862 Jun 21  2022 setupVars.conf.update.bak
-rw-r--r--   1 pihole pihole        325 Feb 17 19:41 versions

This is strange

Feb 18 13:17:46 pihole1 systemd[1]: Stopping pihole-FTL.service - Pi-hole FTL...
Feb 18 13:17:46 pihole1 systemd[1]: pihole-FTL.service: Deactivated successfully.
Feb 18 13:17:46 pihole1 systemd[1]: Stopped pihole-FTL.service - Pi-hole FTL.

What happens if your run

systemctl restart pihole-FTL

Afterwards, please post the log output since the last FTL restart from /var/log/pihole/FTL.log

It appears to restart the FTL system

2025-02-18 14:42:24.207 EST [30842M] INFO: ########## FTL started on pihole1! ##########
2025-02-18 14:42:24.207 EST [30842M] INFO: FTL branch: master
2025-02-18 14:42:24.207 EST [30842M] INFO: FTL version: v6.0
2025-02-18 14:42:24.207 EST [30842M] INFO: FTL commit: eaa7dbb4
2025-02-18 14:42:24.207 EST [30842M] INFO: FTL date: 2025-02-18 17:19:26 +0000
2025-02-18 14:42:24.207 EST [30842M] INFO: FTL user: pihole
2025-02-18 14:42:24.207 EST [30842M] INFO: Compiled for linux/arm/v6 (compiled on CI) using cc (Alpine 14.2.0) 14.2.0
2025-02-18 14:42:24.208 EST [30842M] INFO: Config file /etc/pihole/pihole.toml not available (r): No such file or directory
2025-02-18 14:42:24.208 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.1 not available (r): No such file or directory
2025-02-18 14:42:24.208 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.2 not available (r): No such file or directory
2025-02-18 14:42:24.208 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.3 not available (r): No such file or directory
2025-02-18 14:42:24.209 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.4 not available (r): No such file or directory
2025-02-18 14:42:24.209 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.5 not available (r): No such file or directory
2025-02-18 14:42:24.209 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.6 not available (r): No such file or directory
2025-02-18 14:42:24.209 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.7 not available (r): No such file or directory
2025-02-18 14:42:24.209 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.8 not available (r): No such file or directory
2025-02-18 14:42:24.209 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.9 not available (r): No such file or directory
2025-02-18 14:42:24.209 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.10 not available (r): No such file or directory
2025-02-18 14:42:24.210 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.11 not available (r): No such file or directory
2025-02-18 14:42:24.210 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.12 not available (r): No such file or directory
2025-02-18 14:42:24.210 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.13 not available (r): No such file or directory
2025-02-18 14:42:24.210 EST [30842M] INFO: Config backup file /etc/pihole/config_backups/pihole.toml.14 not available (r): No such file or directory
2025-02-18 14:42:24.210 EST [30842M] INFO: No config file nor backup available, using defaults
2025-02-18 14:42:24.211 EST [30842M] INFO: Config initialized with webserver ports 80 (HTTP) and 443 (HTTPS), IPv6 support is enabled
2025-02-18 14:42:24.215 EST [30842M] INFO: Wrote config file:
2025-02-18 14:42:24.215 EST [30842M] INFO:  - 152 total entries
2025-02-18 14:42:24.215 EST [30842M] INFO:  - 151 entries are default
2025-02-18 14:42:24.215 EST [30842M] INFO:  - 1 entry is modified
2025-02-18 14:42:24.215 EST [30842M] INFO:  - 0 entries are forced through environment
2025-02-18 14:42:24.216 EST [30842M] INFO: Config file written to /etc/pihole/pihole.toml
2025-02-18 14:42:24.221 EST [30842M] INFO: PID file does not exist or not readable
2025-02-18 14:42:24.221 EST [30842M] INFO: No other running FTL process found.
2025-02-18 14:42:24.228 EST [30842M] INFO: PID of FTL process: 30842
2025-02-18 14:42:24.229 EST [30842M] INFO: listening on 0.0.0.0 port 53
2025-02-18 14:42:24.230 EST [30842M] INFO: listening on :: port 53
2025-02-18 14:42:24.232 EST [30842M] INFO: PID of FTL process: 30842
2025-02-18 14:42:24.238 EST [30842M] INFO: Database version is 12
2025-02-18 14:42:24.239 EST [30842M] INFO: Updating long-term database to version 13
2025-02-18 14:42:24.265 EST [30842M] INFO: Updating long-term database to version 14
2025-02-18 14:42:24.276 EST [30842M] INFO: Updating long-term database to version 15
2025-02-18 14:42:24.295 EST [30842M] INFO: Updating long-term database to version 16
2025-02-18 14:42:24.311 EST [30842M] INFO: Updating long-term database to version 17
2025-02-18 14:42:24.332 EST [30842M] INFO: Updating long-term database to version 18
2025-02-18 14:42:24.350 EST [30842M] INFO: Updating long-term database to version 19
2025-02-18 14:42:24.366 EST [30842M] INFO: Updating long-term database to version 20
2025-02-18 14:42:24.393 EST [30842M] INFO: Updating long-term database to version 21
2025-02-18 14:42:24.408 EST [30842M] INFO: Database successfully initialized
2025-02-18 14:43:15.617 EST [30842M] INFO: Imported 28366 queries from the on-disk database (it has 21722041 rows)
2025-02-18 14:43:15.618 EST [30842M] INFO: Parsing queries in database
2025-02-18 14:43:15.941 EST [30842M] INFO:   10000 queries parsed...
2025-02-18 14:43:16.251 EST [30842M] INFO:   20000 queries parsed...
2025-02-18 14:43:16.447 EST [30842M] INFO: Imported 28366 queries from the long-term database
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> Total DNS queries: 28366
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> Cached DNS queries: 13620
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> Forwarded DNS queries: 11380
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> Blocked DNS queries: 3258
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> Unknown DNS queries: 0
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> Unique domains: 1025
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> Unique clients: 15
2025-02-18 14:43:16.447 EST [30842M] INFO:  -> DNS cache records: 0
2025-02-18 14:43:16.448 EST [30842M] INFO:  -> Known forward destinations: 2
2025-02-18 14:43:17.538 EST [30842M] INFO: FTL is running as user pihole (UID 999)
2025-02-18 14:43:17.570 EST [30842M] INFO: Created SSL/TLS certificate for pi.hole at /etc/pihole/tls.pem
2025-02-18 14:43:17.570 EST [30842M] INFO: Reading certificate from /etc/pihole/tls.pem ...
2025-02-18 14:43:17.570 EST [30842M] INFO: Using SSL/TLS certificate file /etc/pihole/tls.pem
2025-02-18 14:43:17.572 EST [30842M] INFO: Web server ports:
2025-02-18 14:43:17.572 EST [30842M] INFO:   - 80 (HTTP, IPv4, optional)
2025-02-18 14:43:17.572 EST [30842M] INFO:   - 443 (HTTPS, IPv4, optional)
2025-02-18 14:43:17.572 EST [30842M] INFO:   - 80 (HTTP, IPv6, optional)
2025-02-18 14:43:17.572 EST [30842M] INFO:   - 443 (HTTPS, IPv6, optional)
2025-02-18 14:43:17.573 EST [30842M] INFO: Restored 0 API sessions from the database
2025-02-18 14:43:17.605 EST [30842M] WARNING: WARNING in dnsmasq core: no upstream servers configured
2025-02-18 14:43:17.610 EST [30842M] INFO: Blocking status is enabled
2025-02-18 14:43:17.751 EST [30842/T30871] INFO: Compiled 1 allow and 0 deny regex for 15 clients in 97.9 msec
2025-02-18 14:43:17.751 EST [30842/T30871] WARNING: List with ID 39 (https://zerodot1.gitlab.io/CoinBlockerLists/hosts_browser) was inaccessible during last gravity run
2025-02-18 14:43:18.121 EST [30842M] ERROR: SQLite3: no such column: adlist_id in "SELECT adlist_id from vw_gravity WHERE domain = ? AND group_id IN (0);" (1)
2025-02-18 14:43:18.122 EST [30842M] ERROR: gravityDB_open("SELECT(... vw_gravity ...)") - SQL error prepare: SQL logic error
2025-02-18 14:43:18.140 EST [30842M] ERROR: SQLite3: no such column: adlist_id in "SELECT adlist_id from vw_gravity WHERE domain = ? AND group_id IN (0);" (1)
2025-02-18 14:43:18.140 EST [30842M] ERROR: gravityDB_open("SELECT(... vw_gravity ...)") - SQL error prepare: SQL logic error
2025-02-18 14:43:18.141 EST [30842M] ERROR: Gravity database not available (allowlist)
2025-02-18 14:43:22.116 EST [30842/T30870] WARNING: Warning NTP client: No valid NTP replies received, check server and network connectivity
2025-02-18 14:43:22.120 EST [30842/T30870] INFO: Local time is too inaccurate, retrying in 600 seconds before launching NTP server
2025-02-18 14:45:47.487 EST [30842/T30898] WARNING: API: Bad request (The API is hosted at pi.hole/api, not pi.hole/admin/api)
2025-02-18 14:45:47.519 EST [30842/T30898] WARNING: API: Bad request (The API is hosted at pi.hole/api, not pi.hole/admin/api)

Ok, FTL starts now, but there are some issues.

Are you able to access the web interface at

pi.hole/admin

If so, please set an upstream DNS server.

I am able to access the Admin interface. I had previously set Unbound (127.0.0.1#5335) as my upstream, it seems to have lost that config option. I put it back.

Yes. It was lost during the broken upgrade step (missing pihole.toml).

Do you have a teleporter backup from your old configuration. You should be able to import it into v6.

Nope, but I can do a Teleporter export from my other pihole instance. Everything appears to be working fine at the moment. Going to wait a week or so before upgrading my second node.

Thanks!

Have a look at FTL.log from time to time and see if the SQL errors persist

2025-02-18 14:43:18.121 EST [30842M] ERROR: SQLite3: no such column: adlist_id in "SELECT adlist_id from vw_gravity WHERE domain = ? AND group_id IN (0);" (1)
2025-02-18 14:43:18.122 EST [30842M] ERROR: gravityDB_open("SELECT(... vw_gravity ...)") - SQL error prepare: SQL logic error
2025-02-18 14:43:18.140 EST [30842M] ERROR: SQLite3: no such column: adlist_id in "SELECT adlist_id from vw_gravity WHERE domain = ? AND group_id IN (0);" (1)
2025-02-18 14:43:18.140 EST [30842M] ERROR: gravityDB_open("SELECT(... vw_gravity ...)") - SQL error prepare: SQL logic error
2025-02-18 14:43:18.141 EST [30842M] ERROR: Gravity database not available (allowlist)

So it crashed after I tried to bring in my Teleporter backup from my primary PiHole instance, and it reverted the pihole.toml to defaults.

2025-02-18 15:23:34.376 EST [31718/T31736] WARNING: List with ID 39 (https://zerodot1.gitlab.io/CoinBlockerLists/hosts_browser) was inaccessible during last gravity run
2025-02-18 15:23:35.866 EST [31718M] ERROR: SQLite3: no such column: adlist_id in "SELECT adlist_id from vw_gravity WHERE domain = ? AND group_id IN (0);" (1)
2025-02-18 15:23:35.867 EST [31718M] ERROR: gravityDB_open("SELECT(... vw_gravity ...)") - SQL error prepare: SQL logic error
2025-02-18 15:23:35.885 EST [31718M] ERROR: SQLite3: no such column: adlist_id in "SELECT adlist_id from vw_gravity WHERE domain = ? AND group_id IN (0);" (1)
2025-02-18 15:23:35.885 EST [31718M] ERROR: gravityDB_open("SELECT(... vw_gravity ...)") - SQL error prepare: SQL logic error
2025-02-18 15:23:35.886 EST [31718M] ERROR: Gravity database not available (allowlist)


2025-02-18 15:28:02.754 EST [31718/T31753] WARNING: API: Could not read domains from database table (Database not available)
2025-02-18 15:28:13.448 EST [31718/T31753] INFO: import_json_table(adlist.json): JSON array contains 32 entries
2025-02-18 15:28:13.510 EST [31718/T31753] INFO: import_json_table(adlist_by_group.json): JSON array contains 32 entries
2025-02-18 15:28:13.529 EST [31718/T31753] INFO: import_json_table(blacklist.exact.json): JSON array contains 0 entries
2025-02-18 15:28:13.535 EST [31718/T31753] INFO: import_json_table(blacklist.regex.json): JSON array contains 0 entries
2025-02-18 15:28:13.540 EST [31718/T31753] INFO: import_json_table(client.json): JSON array contains 4 entries
2025-02-18 15:28:13.569 EST [31718/T31753] INFO: import_json_table(client_by_group.json): JSON array contains 6 entries
2025-02-18 15:28:13.591 EST [31718/T31753] INFO: import_json_table(domainlist_by_group.json): JSON array contains 7 entries
2025-02-18 15:28:13.625 EST [31718/T31753] INFO: import_json_table(group.json): JSON array contains 3 entries
2025-02-18 15:28:13.642 EST [31718/T31753] INFO: import_json_table(whitelist.exact.json): JSON array contains 6 entries
2025-02-18 15:28:13.665 EST [31718/T31753] INFO: import_json_table(whitelist.regex.json): JSON array contains 1 entry
2025-02-18 15:28:13.690 EST [31718/T31753] INFO: Writing file "custom.list" (108 bytes) to "/etc/pihole/custom.list"
2025-02-18 15:28:13.699 EST [31718/T31753] INFO: Writing file "pihole-FTL.conf" (1485 bytes) to "/etc/pihole/pihole-FTL.conf"
2025-02-18 15:28:13.700 EST [31718/T31753] INFO: Writing file "setupVars.conf" (725 bytes) to "/etc/pihole/setupVars.conf"
2025-02-18 15:28:13.712 EST [31718/T31753] INFO: Migrating config to Pi-hole v6.0 format
2025-02-18 15:28:13.713 EST [31718/T31753] INFO: Reading legacy config files from /etc/pihole/pihole-FTL.conf
2025-02-18 15:28:13.713 EST [31718/T31753] INFO:    WEBROOT: Empty path is not possible, using default
2025-02-18 15:28:13.714 EST [31718/T31753] INFO:    WEBHOME: Empty path is not possible, using default
2025-02-18 15:28:13.714 EST [31718/T31753] INFO:    API_INFO_LOG: Empty path is not possible, using default
2025-02-18 15:28:13.714 EST [31718/T31753] INFO:    WEBDOMAIN: Empty path is not possible, using default
2025-02-18 15:28:13.715 EST [31718/T31753] ERROR: Debug config item with index 255 requested but we have only 29 debug elements
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: ---------------------------->  FTL crashed!  <----------------------------
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: Please report a bug at https://github.com/pi-hole/FTL/issues
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: and include in your report already the following details:
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: FTL has been running for 330 seconds
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: FTL branch: master
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: FTL version: v6.0
2025-02-18 15:28:13.717 EST [31718/T31753] INFO: FTL commit: eaa7dbb4
2025-02-18 15:28:13.718 EST [31718/T31753] INFO: FTL date: 2025-02-18 17:19:26 +0000
2025-02-18 15:28:13.728 EST [31718/T31753] INFO: FTL user: started as pihole, ended as pihole
2025-02-18 15:28:13.728 EST [31718/T31753] INFO: Compiled for linux/arm/v6 (compiled on CI) using cc (Alpine 14.2.0) 14.2.0
2025-02-18 15:28:13.728 EST [31718/T31753] INFO: Process details: MID: 31718
2025-02-18 15:28:13.728 EST [31718/T31753] INFO:                  PID: 31718
2025-02-18 15:28:13.728 EST [31718/T31753] INFO:                  TID: 31753
2025-02-18 15:28:13.728 EST [31718/T31753] INFO:                  Name: civetweb-worker
2025-02-18 15:28:13.729 EST [31718/T31753] INFO: Received signal: Segmentation fault
2025-02-18 15:28:13.729 EST [31718/T31753] INFO:      at address: 0x18
2025-02-18 15:28:13.729 EST [31718/T31753] INFO:      with code:  SEGV_MAPERR (Address not mapped to object)
2025-02-18 15:28:13.729 EST [31718/T31753] INFO: !!! INFO: pihole-FTL has not been compiled with glibc/backtrace support, not generating one !!!
2025-02-18 15:28:13.729 EST [31718/T31753] INFO: ------ Listing content of directory /dev/shm ------
2025-02-18 15:28:13.729 EST [31718/T31753] INFO: File Mode User:Group      Size  Filename
2025-02-18 15:28:13.732 EST [31718/T31753] INFO: rwxrwxrwx root:root       360   .
2025-02-18 15:28:13.733 EST [31718/T31753] INFO: rwxr-xr-x root:root         4K  ..
2025-02-18 15:28:13.733 EST [31718/T31753] INFO: rw------- pihole:pihole   786K  FTL-31718-recycler
2025-02-18 15:28:13.733 EST [31718/T31753] INFO: rw------- pihole:pihole     4K  FTL-31718-dns-cache-lookup
2025-02-18 15:28:13.734 EST [31718/T31753] INFO: rw------- pihole:pihole    12K  FTL-31718-domains-lookup
2025-02-18 15:28:13.734 EST [31718/T31753] INFO: rw------- pihole:pihole     4K  FTL-31718-clients-lookup
2025-02-18 15:28:13.734 EST [31718/T31753] INFO: rw------- pihole:pihole   560K  FTL-31718-fifo-log
2025-02-18 15:28:13.734 EST [31718/T31753] INFO: rw------- pihole:pihole     4K  FTL-31718-per-client-regex
2025-02-18 15:28:13.735 EST [31718/T31753] INFO: rw------- pihole:pihole    20K  FTL-31718-dns-cache
2025-02-18 15:28:13.735 EST [31718/T31753] INFO: rw------- pihole:pihole     8K  FTL-31718-overTime
2025-02-18 15:28:13.737 EST [31718/T31753] INFO: rw------- pihole:pihole     2M  FTL-31718-queries
2025-02-18 15:28:13.737 EST [31718/T31753] INFO: rw------- pihole:pihole    12K  FTL-31718-upstreams
2025-02-18 15:28:13.738 EST [31718/T31753] INFO: rw------- pihole:pihole   340K  FTL-31718-clients
2025-02-18 15:28:13.738 EST [31718/T31753] INFO: rw------- pihole:pihole    37K  FTL-31718-domains
2025-02-18 15:28:13.738 EST [31718/T31753] INFO: rw------- pihole:pihole    82K  FTL-31718-strings
2025-02-18 15:28:13.739 EST [31718/T31753] INFO: rw------- pihole:pihole   136   FTL-31718-settings
2025-02-18 15:28:13.739 EST [31718/T31753] INFO: rw------- pihole:pihole   328   FTL-31718-counters
2025-02-18 15:28:13.739 EST [31718/T31753] INFO: rw------- pihole:pihole    56   FTL-31718-lock
2025-02-18 15:28:13.739 EST [31718/T31753] INFO: ---------------------------------------------------
2025-02-18 15:28:13.739 EST [31718/T31753] INFO: Please also include some lines from above the !!!!!!!!! header.
2025-02-18 15:28:13.740 EST [31718/T31753] INFO: Thank you for helping us to improve our FTL engine!
2025-02-18 15:28:13.740 EST [31718/T31753] INFO: Waiting for threads to join
2025-02-18 15:28:13.749 EST [31718/T31739] INFO: Terminating timer thread
2025-02-18 15:28:14.229 EST [31718/T31738] INFO: Terminating resolver thread
2025-02-18 15:28:15.741 EST [31718/T31753] INFO: Thread database (0) is still busy, cancelling it.
2025-02-18 15:28:15.742 EST [31718/T31754] ERROR: Error when obtaining outer SHM lock: Previous owner died
2025-02-18 15:28:15.742 EST [31718/T31754] ERROR: Error when obtaining inner SHM lock: Previous owner died
2025-02-18 15:28:15.743 EST [31718/T31737] INFO: Terminating GC thread
2025-02-18 15:28:15.743 EST [31718/T31753] INFO: All threads joined
2025-02-18 15:28:15.746 EST [31718/T31753] INFO: PID file emptied
2025-02-18 15:28:15.750 EST [31718/T31753] INFO: Stored 0 API sessions in the database

Thanks for the report. We'll look into that.
@DL6ER

Please follow the steps described here

and provide the backtrace information after such a crash. If you see pihole-FTL stop due to anything else than a crash, please tell us this as well and just go on running it using the command continue.

Looks like I'm having the same issue.
Upgraded to v6.0 according to pihole -v

I now have to insert "sudo" in front of phole -v... never used to.

Answered "yes" to remove lighttpd.

Responds to pings but cannot access webpage.

Did you try to sudo systemctl restart pihole-FTL

I did. That runs without issue. No messages - but issue still remains unfortunately.

Initial Crash Output

Thread 10 "civetweb-worker" received signal SIGSEGV, Segmentation fault.
[Switching to LWP 9008]
0x00307f4c in setDebugOption (fp=0x71622070, option=0x4a6ad4 "DEBUG_ALL", flag=255) at /app/src/config/legacy_reader.c:818
818     /app/src/config/legacy_reader.c: No such file or directory.

Backtrace output

(gdb) backtrace
#0  0x00307f4c in setDebugOption (fp=0x71622070, option=0x4a6ad4 "DEBUG_ALL", flag=255) at /app/src/config/legacy_reader.c:818
#1  readDebugingSettingsLegacy (fp=0x71622070) at /app/src/config/legacy_reader.c:841
#2  readFTLlegacy (conf=<optimized out>) at /app/src/config/legacy_reader.c:588
#3  0x00300648 in migrate_config_v6 () at /app/src/config/config.c:1685
#4  0x00062004 in process_received_tar_gz (api=0x716768e0, data=0x71676790) at /app/src/api/teleporter.c:846
#5  api_teleporter_POST (api=0x716768e0) at /app/src/api/teleporter.c:294
#6  api_teleporter (api=0x716768e0) at /app/src/api/teleporter.c:863
#7  0x0003facc in api_handler (conn=0x719d62f8, ignored=<optimized out>) at /app/src/api/api.c:193
#8  0x00084690 in handle_request (conn=conn@entry=0x719d62f8) at /app/src/webserver/civetweb/civetweb.c:15413
#9  0x00088198 in handle_request_stat_log (conn=0x719d62f8) at /app/src/webserver/civetweb/civetweb.c:6831
#10 process_new_connection (conn=conn@entry=0x719d62f8) at /app/src/webserver/civetweb/civetweb.c:19977
#11 0x00089950 in worker_thread_run (conn=0x719d62f8) at /app/src/webserver/civetweb/civetweb.c:20349
#12 worker_thread (thread_func_param=0x719d62f8) at /app/src/webserver/civetweb/civetweb.c:20496
#13 0x00443bd4 in start (p=0x7167bd70) at src/thread/pthread_create.c:207
#14 0x0044eca0 in __clone () at src/thread/arm/clone.s:23
(repeat for 1300 lines)

That backtrace command is still running and outputting #${LINENO} 0x0044eca0 in __clone () at src/thread/arm/clone.s:23. I'm going to let it keep running and see if it actually completes.

Do you, by any chance, have DEBUG_ALL = true set in your v5 config? The code path working on this has a small bug I've just discovered.

@kyralretsam Please try if the crash still happens after you ran

sudo pihole checkout ftl fix/debug_crash
1 Like

I didn't have that setting in my imported V5 config, but the import works after doing that checkout

1 Like