FTL logging in database after the update to v5.3.1

Pi-hole version is v5.2 (Latest: v5.2)
AdminLTE version is v5.2 (Latest: v5.2)
FTL version is v5.3.1 (Latest: v5.3.1)

FTL logs into the database after the update to v5.3.1 even if MAXDBDAYS=0 is in /etc/pihole/pihole-FTL.conf

The network details are stored in the long term database, so it is never completely disabled.

With your setting of 0 days what logging are you seeing?

1 Like

Ftl logging in database screenshot, it happens on reboot as well.

pihole-FTL.log file (live)

[2020-12-02 16:02:31.705 102365M] Shutting down...
[2020-12-02 16:02:31.707 102365M] ########## FTL terminated after 3h 4m 51s ! ##########
[2020-12-02 16:02:32.612 121068M] Using log file /var/log/pihole-FTL.log
[2020-12-02 16:02:32.612 121068M] ########## FTL started! ##########
[2020-12-02 16:02:32.612 121068M] FTL branch: master
[2020-12-02 16:02:32.612 121068M] FTL version: v5.3.1
[2020-12-02 16:02:32.612 121068M] FTL commit: e1db31d
[2020-12-02 16:02:32.612 121068M] FTL date: 2020-11-28 21:59:12 +0100
[2020-12-02 16:02:32.612 121068M] FTL user: pihole
[2020-12-02 16:02:32.612 121068M] Compiled for aarch64 (compiled on CI) using aarch64-linux-gnu-gcc (Debian 6.3.0-18) 6.3.0 20170516
[2020-12-02 16:02:32.612 121068M] Starting config file parsing (/etc/pihole/pihole-FTL.conf)
[2020-12-02 16:02:32.612 121068M]    SOCKET_LISTENING: only local
[2020-12-02 16:02:32.612 121068M]    AAAA_QUERY_ANALYSIS: Show AAAA queries
[2020-12-02 16:02:32.612 121068M]    MAXDBDAYS: --- (DB disabled)
[2020-12-02 16:02:32.612 121068M]    RESOLVE_IPV6: Resolve IPv6 addresses
[2020-12-02 16:02:32.612 121068M]    RESOLVE_IPV4: Resolve IPv4 addresses
[2020-12-02 16:02:32.612 121068M]    DBINTERVAL: saving to DB file every minute
[2020-12-02 16:02:32.612 121068M]    DBFILE: Using /etc/pihole/pihole-FTL.db
[2020-12-02 16:02:32.612 121068M]    MAXLOGAGE: Importing up to 24.0 hours of log data
[2020-12-02 16:02:32.612 121068M] Notice: Increasing privacy level from 0 to 3
[2020-12-02 16:02:32.612 121068M]    PRIVACYLEVEL: Set to 3
[2020-12-02 16:02:32.612 121068M]    IGNORE_LOCALHOST: Show queries from localhost
[2020-12-02 16:02:32.612 121068M]    BLOCKINGMODE: Null IPs for blocked domains
[2020-12-02 16:02:32.612 121068M]    ANALYZE_ONLY_A_AND_AAAA: Disabled. Analyzing all queries
[2020-12-02 16:02:32.612 121068M]    DBIMPORT: Importing history from database
[2020-12-02 16:02:32.612 121068M]       Hint: Exporting queries has been disabled (MAXDBDAYS=0)!
[2020-12-02 16:02:32.612 121068M]    PIDFILE: Using /run/pihole-FTL.pid
[2020-12-02 16:02:32.612 121068M]    PORTFILE: Using /run/pihole-FTL.port
[2020-12-02 16:02:32.612 121068M]    SOCKETFILE: Using /run/pihole/FTL.sock
[2020-12-02 16:02:32.612 121068M]    SETUPVARSFILE: Using /etc/pihole/setupVars.conf
[2020-12-02 16:02:32.612 121068M]    MACVENDORDB: Using /etc/pihole/macvendor.db
[2020-12-02 16:02:32.613 121068M]    GRAVITYDB: Using /etc/pihole/gravity.db
[2020-12-02 16:02:32.613 121068M]    PARSE_ARP_CACHE: Active
[2020-12-02 16:02:32.613 121068M]    CNAME_DEEP_INSPECT: Active
[2020-12-02 16:02:32.613 121068M]    DELAY_STARTUP: No delay requested.
[2020-12-02 16:02:32.613 121068M]    BLOCK_ESNI: Enabled, blocking _esni.{blocked domain}
[2020-12-02 16:02:32.613 121068M]    NICE: Set process niceness to -10 (default)
[2020-12-02 16:02:32.613 121068M]    MAXNETAGE: No automated removal of IP addresses and host names from the network table
[2020-12-02 16:02:32.613 121068M]    NAMES_FROM_NETDB: Enabled, trying to get names from network database
[2020-12-02 16:02:32.613 121068M]    EDNS0_ECS: Overwrite client from ECS information
[2020-12-02 16:02:32.613 121068M] Finished config file parsing
[2020-12-02 16:02:32.613 121068M] Creating mutex
[2020-12-02 16:02:32.615 121068M] Database version is 9
[2020-12-02 16:02:32.615 121068M] Imported 0 alias-clients
[2020-12-02 16:02:32.615 121068M] Not using the database for storing queries
[2020-12-02 16:02:32.615 121068M] Database successfully initialized
[2020-12-02 16:02:32.615 121068M] Imported 0 queries from the long-term database
[2020-12-02 16:02:32.616 121068M]  -> Total DNS queries: 0
[2020-12-02 16:02:32.616 121068M]  -> Cached DNS queries: 0
[2020-12-02 16:02:32.616 121068M]  -> Forwarded DNS queries: 0
[2020-12-02 16:02:32.616 121068M]  -> Blocked DNS queries: 0
[2020-12-02 16:02:32.616 121068M]  -> Unknown DNS queries: 0
[2020-12-02 16:02:32.616 121068M]  -> Unique domains: 0
[2020-12-02 16:02:32.616 121068M]  -> Unique clients: 0
[2020-12-02 16:02:32.616 121068M]  -> Known forward destinations: 0
[2020-12-02 16:02:32.616 121068M] Successfully accessed setupVars.conf
[2020-12-02 16:02:32.621 121070M] PID of FTL process: 121070
[2020-12-02 16:02:32.622 121070M] INFO: FTL is running as user pihole (UID 998)
[2020-12-02 16:02:32.622 121070/T121073] Listening on Unix socket
[2020-12-02 16:02:32.622 121070M] Reloading DNS cache
[2020-12-02 16:02:32.623 121070/T121072] Listening on port 4711 for incoming IPv6 telnet connections
[2020-12-02 16:02:32.623 121070/T121071] Listening on port 4711 for incoming IPv4 telnet connections
[2020-12-02 16:02:32.623 121070M] Blocking status is enabled
[2020-12-02 16:02:33.590 121070/T121074] Compiled 0 whitelist and 0 blacklist regex filters for 0 clients in 0.5 msec
[2020-12-02 16:03:19.193 121070M] New upstream server: 8.8.4.4:53 (0/512)
[2020-12-02 16:03:22.933 121070M] New upstream server: 8.8.8.8:53 (1/512)

I have no idea how to use the database.., give me some commands @jfb

sqlite> .open /etc/pihole/pihole-FTL.db
sqlite> .databases
main: /etc/pihole/pihole-FTL.db
sqlite> .tables
aliasclient        ftl                network            queries
counters           message            network_addresses
sqlite> .indexes
idx_queries_timestamps                sqlite_autoindex_network_addresses_1
sqlite_autoindex_network_1
sqlite> .fullschema
CREATE TABLE queries ( id INTEGER PRIMARY KEY AUTOINCREMENT, timestamp INTEGER NOT NULL, type INTEGER NOT NULL, status INTEGER NOT NULL, domain TEXT NOT NULL, client TEXT NOT NULL, forward TEXT , additional_info TEXT);
CREATE INDEX idx_queries_timestamps ON queries (timestamp);
CREATE TABLE ftl ( id INTEGER PRIMARY KEY NOT NULL, value BLOB NOT NULL );
CREATE TABLE counters ( id INTEGER PRIMARY KEY NOT NULL, value INTEGER NOT NULL );
CREATE TABLE message ( id INTEGER PRIMARY KEY AUTOINCREMENT, timestamp INTEGER NOT NULL, type TEXT NOT NULL, message TEXT NOT NULL, blob1 BLOB, blob2 BLOB, blob3 BLOB, blob4 BLOB, blob5 BLOB );
CREATE TABLE IF NOT EXISTS "network_addresses" ( network_id INTEGER NOT NULL, ip TEXT UNIQUE NOT NULL, lastSeen INTEGER NOT NULL DEFAULT (cast(strftime('%s', 'now') as int)), name TEXT, nameUpdated INTEGER, FOREIGN KEY(network_id) REFERENCES network(id));
CREATE TABLE IF NOT EXISTS "network" ( id INTEGER PRIMARY KEY NOT NULL, hwaddr TEXT UNIQUE NOT NULL, interface TEXT NOT NULL, firstSeen INTEGER NOT NULL, lastQuery INTEGER NOT NULL, numQueries INTEGER NOT NULL, macVendor TEXT, aliasclient_id INTEGER);
CREATE TABLE aliasclient (id INTEGER PRIMARY KEY NOT NULL, name TEXT NOT NULL, comment TEXT);
/* No STAT tables available */

Please upload a debug log and post just the token generated by

pihole -d

allowing to upload when prompted, or do it through the Web interface:

Tools > Generate Debug Log

1 Like

@jfb https://tricorder.pi-hole.net/1mu6qtxbml

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.