Telemetry via Sink SQLite

The Netify SQLite output interface stores network telemetry and metadata from the DPI engine in local SQLite databases. Each channel maps incoming payloads onto one or more tables using a JSON column mapping, so you can choose exactly which fields are kept without writing any code. This makes it a good fit for on-device reporting, dashboards on embedded gateways, and any tool that can query a SQLite file.

For alternative methods of accessing network telemetry, see the related Netify Sink options.


License

The Netify Sink SQLite plugin is a proprietary plugin requiring a license. Please contact us for details.


Installation

Netify plugins are distributed through the same packaging workflow as the Netify Agent, allowing for a consistent installation experience using standard package manager syntax. While pre-compiled binaries are readily available for x86_64 architectures via our public mirrors, support for ARM, MIPS, and other specialized architectures is available upon request. Please contact us for details.

Step 1 - Select your installation target:

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo apt-get update
sudo apt-get -y install curl gnupg2
sudo curl https://download.netify.ai/5/debian/netify-archive-keyring.gpg -o /usr/share/keyrings/netify-archive-keyring.gpg
echo 'deb [signed-by=/usr/share/keyrings/netify-archive-keyring.gpg] http://download.netify.ai/5/debian/13/ /' | sudo tee /etc/apt/sources.list.d/netify.list

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo apt update
sudo apt install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo apt-get update
sudo apt-get -y install curl gnupg2
sudo curl https://download.netify.ai/5/debian/netify-archive-keyring.gpg -o /usr/share/keyrings/netify-archive-keyring.gpg
echo 'deb [signed-by=/usr/share/keyrings/netify-archive-keyring.gpg] http://download.netify.ai/5/debian/12/ /' | sudo tee /etc/apt/sources.list.d/netify.list

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo apt update
sudo apt install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo apt-get update
sudo apt-get -y install curl gnupg2
sudo curl https://download.netify.ai/5/ubuntu/netify-archive-keyring.gpg -o /usr/share/keyrings/netify-archive-keyring.gpg
echo 'deb [signed-by=/usr/share/keyrings/netify-archive-keyring.gpg] http://download.netify.ai/5/ubuntu/resolute/ /' | sudo tee /etc/apt/sources.list.d/netify.list

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo apt update
sudo apt install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo apt-get update
sudo apt-get -y install curl gnupg2
sudo curl https://download.netify.ai/5/ubuntu/netify-archive-keyring.gpg -o /usr/share/keyrings/netify-archive-keyring.gpg
echo 'deb [signed-by=/usr/share/keyrings/netify-archive-keyring.gpg] http://download.netify.ai/5/ubuntu/noble/ /' | sudo tee /etc/apt/sources.list.d/netify.list

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo apt update
sudo apt install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo apt-get update
sudo apt-get -y install curl gnupg2
sudo curl https://download.netify.ai/5/ubuntu/netify-archive-keyring.gpg -o /usr/share/keyrings/netify-archive-keyring.gpg
echo 'deb [signed-by=/usr/share/keyrings/netify-archive-keyring.gpg] http://download.netify.ai/5/ubuntu/jammy/ /' | sudo tee /etc/apt/sources.list.d/netify.list

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo apt update
sudo apt install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo apt-get update
sudo apt-get -y install curl gnupg2
curl -fsSL https://download.netify.ai/5/ubuntu/apt-gpg-key-netify.asc | sudo apt-key add -
echo 'deb http://download.netify.ai/5/ubuntu/focal/ /' | sudo tee /etc/apt/sources.list.d/netify.list

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo apt update
sudo apt install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
wget https://download.netify.ai/5/openwrt/netify-6a0f68af.rsa.pub -O /etc/apk/keys/netify-6a0f68af.rsa.pub
echo 'https://download.netify.ai/5/openwrt/25.12/x86/packages.adb' >> /etc/apk/repositories.d/customfeeds.list

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
apk update
apk add netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
wget https://download.netify.ai/5/openwrt/key-build.pub -O /etc/opkg/keys/b18c240cb821dad2
echo 'src/gz netify https://download.netify.ai/5/openwrt/24.10/x86' >> /etc/opkg/customfeeds.conf

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
opkg update
opkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
wget https://download.netify.ai/5/openwrt/key-build.pub -O /etc/opkg/keys/b18c240cb821dad2
echo 'src/gz netify https://download.netify.ai/5/openwrt/23.05/x86' >> /etc/opkg/customfeeds.conf

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
opkg update
opkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
wget https://download.netify.ai/5/openwrt/key-build.pub -O /etc/opkg/keys/b18c240cb821dad2
echo 'src/gz netify https://download.netify.ai/5/openwrt/22.03/x86' >> /etc/opkg/customfeeds.conf

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
opkg update
opkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
wget https://download.netify.ai/5/openwrt/key-build.pub -O /etc/opkg/keys/b18c240cb821dad2
echo 'src/gz netify https://download.netify.ai/5/openwrt/21.02/x86' >> /etc/opkg/customfeeds.conf

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
opkg update
opkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
wget http://download.netify.ai/5/openwrt/key-build.pub -O /etc/opkg/keys/b18c240cb821dad2
echo 'src/gz netify http://download.netify.ai/5/openwrt/19.07/x86' >> /etc/opkg/customfeeds.conf

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
opkg update
opkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo rpm --import https://download.netify.ai/5/opensuse/15.6/stable/RPM-GPG-KEY-netify
sudo curl https://download.netify.ai/5/opensuse/netify.repo -o /etc/zypp/repos.d/repo-netify.repo

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo zypper update
sudo zypper install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo rpm --import https://download.netify.ai/5/opensuse/15.5/stable/RPM-GPG-KEY-netify
sudo curl https://download.netify.ai/5/opensuse/netify.repo -o /etc/zypp/repos.d/repo-netify.repo

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo zypper update
sudo zypper install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo rpm --import https://download.netify.ai/5/almalinux/9/stable/RPM-GPG-KEY-netify
sudo curl https://download.netify.ai/5/almalinux/9/netify.repo -o /etc/yum.repos.d/netify.repo

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo yum update
sudo yum install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo rpm --import https://download.netify.ai/5/almalinux/8/stable/RPM-GPG-KEY-netify
sudo curl https://download.netify.ai/5/almalinux/8/netify.repo -o /etc/yum.repos.d/netify.repo

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo yum update
sudo yum install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo rpm --import http://download.netify.ai/5/rockylinux/9/stable/RPM-GPG-KEY-netify
sudo curl https://download.netify.ai/5/rockylinux/9/netify.repo -o /etc/yum.repos.d/netify.repo

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo yum update
sudo yum install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
sudo rpm --import http://download.netify.ai/5/rockylinux/8/stable/RPM-GPG-KEY-netify
sudo curl https://download.netify.ai/5/rockylinux/8/netify.repo -o /etc/yum.repos.d/netify.repo

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
sudo yum update
sudo yum install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/opnsense/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/opnsense/26.7",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/opnsense/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/opnsense/26.1",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/opnsense/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/opnsense/25.7",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/opnsense/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/opnsense/24.7",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/freebsd/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/freebsd/15.1",
  signature_type: "fingerprints",
  mirror_type: "none",
  priority: 11,

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/freebsd/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/freebsd/15.0",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/freebsd/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/freebsd/15.0",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/freebsd/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/freebsd/14.0",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Step 2 - Add Netify's package signing key and repository:

Terminal - Netify
×
mkdir -p /usr/local/etc/pkg/fingerprints/Netify/trusted
curl https://download.netify.ai/5/freebsd/fingerprint -o /usr/local/etc/pkg/fingerprints/Netify/trusted/fingerprint
cat << EOF >  /usr/local/etc/pkg/repos/Netify.conf
Netify: {
  fingerprints: "/usr/local/etc/pkg/fingerprints/Netify",
  url: "https://download.netify.ai/5/freebsd/14.0",
  signature_type: "fingerprints",
  mirror_type: "http",
  priority: 11,
  enabled: yes
}
EOF

Step 3 - Install Netify Sink SQLite:

Terminal - Netify
×
pkg update
pkg install netify-sink-sqlite

Setup

To use the Netify Sink SQLite plugin, ensure your license.json includes the netify-sink-sqlite entitlement.

All plugins are disabled by default, and the Netify Sink SQLite plugin is no different. Use netifyd's --enable-plugin and --disable-plugin flags to enable or disable the plugin.

Terminal - Netify
×
netifyd --enable-plugin sink-sqlite  # Enables loader
netifyd --disable-plugin sink-sqlite # Disables loader

For orchestration tools or manual setup, you can also directly update configuration file in the plugins.d subdirectory and set enable to yes.

See the advanced configuration section for details on instantiating multiple instances of the plugin.

Terminal - Netify
×
$ cat 10-netify-sink-sqlite.conf
[sink-sqlite]
enable = yes
plugin_library = /usr/lib64/libnetify-sink-sqlite.so.0.0.0
conf_filename = ${path_state_persistent}/netify-sink-sqlite.json

AI Integration

AI coding assistants can help you configure and debug the Sink SQLite plugin. Point your assistant at our AI and LLM resources (llms.txt, JSON schemas and the OpenAPI specification) so it works from accurate Netify documentation rather than guesswork. If something isn't working as expected, the troubleshooting guide covers common diagnostic steps. For example, try a prompt along these lines:

Example AI Prompt

Using the Netify Agent v5 documentation at https://www.netify.ai/developer/agent/v5/llms.txt,
configure the netify-sink-sqlite plugin to store flow telemetry from netify-proc-core
in a SQLite database under /var/lib/netifyd/db.

- Create a flows table keyed on flow_id, plus a flow_stats table for per-interval byte counts
- Purge rows older than 14 days
- Validate the configuration against the netify-config-sink-sqlite.json schema
- Show the matching sink entry in netify-proc-core.json
- Give me a SQL query listing the top 10 applications by total bytes

Configuration

The plugin is configured via the JSON file referenced by its loader (typically /etc/netifyd/netify-sink-sqlite.json ). Top-level properties set global defaults, such as the database directory and how long rows are kept. Each channel writes to its own database file and defines the tables and columns that incoming payloads are mapped onto.

The full configuration is described by the JSON schema, which also documents the table and column options. Validating your configuration against it catches misspelled keys and invalid table definitions before the agent loads them.

Global Configuration

db_path

string

Default directory for database files. Supports Agent variables such as ${path_state_persistent}. The directory must exist.

Default:
/tmp

purge_in_days

integer

Default age, in days, at which rows are purged. Purging runs at startup and once a day. 0 disables purging on core channels.

Default:
0

channels

object

Channel configurations, keyed by the channel name processor plugins dispatch payloads to.

Channel Configuration

enable

boolean

State of the channel. A disabled channel is skipped without being loaded.

Default:
true

db_name

string

Database file name, in db_path. SQLite keeps -wal and -shm files beside it.

db_path

string

Channel-specific directory for the database file. Supports Agent variables such as ${path_state_persistent}.

data_source

string

The processor whose payloads the channel receives: 'aggregator' (netify-proc-aggregator interval summaries) or 'core' (netify-proc-core per-event telemetry). It decides the shape of tables.

Options:
aggregator core

purge_in_days

integer

Channel-specific purge age in days.

tables

array

Table definitions. Their shape depends on data_source.

flow_metadata

object

Per-flow protocol metadata (ssl, http, dns, conntrack, ...) recorded in a flow_meta table, one row per key, from flow_dpi_complete payloads. Core channels only. Requires a flow_dpi_complete table with a primary_key column, which flow_meta rows reference.

Example Sink SQLite Plugin Configuration

{
    "db_path": "${path_state_persistent}/db",
    "purge_in_days": 30,
    "channels": {
        "core": {
            "db_name": "flows.db",
            "data_source": "core",
            "purge_in_days": 14,
            "tables": [
                {
                    "name": "flows",
                    "type": "flow_dpi_complete",
                    "upsert": true,
                    "purge_column": "last_seen_at",
                    "columns": [
                        { "name": "flow_id", "mapped": "flow.id.xxh64", "type": "TEXT", "primary_key": true, "not_null": true },
                        { "name": "local_ip", "mapped": "flow.local_ip", "type": "TEXT" },
                        { "name": "other_ip", "mapped": "flow.other_ip", "type": "TEXT" },
                        { "name": "application", "mapped": "flow.detected_application", "type": "INTEGER" },
                        { "name": "last_seen_at", "calculated_value": "flow.last_seen_at / 1000", "type": "INTEGER", "index": true }
                    ]
                }
            ]
        }
    }
}

Data Sources

Every channel sets a data_source , which tells the plugin the shape of the payloads it will receive:

  • aggregator — interval summaries from the Aggregator processor. Each interval gets a row in an automatically created <channel>_intervals table, and every application/protocol record in the interval becomes a row in your single configured table.
  • core — per-event telemetry from the Core processor. Each table handles one payload type (for example flow_dpi_complete or flow_stats ), and columns are read from dot-separated paths such as flow.local_ip . Tables can upsert, use foreign keys, and optionally record per-protocol flow metadata (TLS, HTTP, DNS, etc.) in a flow_meta table.

Rows older than purge_in_days are purged at startup and once a day. On core channels, only tables with a purge_column are purged. Databases are opened in WAL mode, so the database directory must be writable and on a local filesystem.