pg_sina_csd
pg_sina_csd · Read-only PostgreSQL query offload to SNIA/FEMU computational storage
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 102452 | pg_sina_csd | pg_sina_csd | 0.3 | OLAP | C |
PostgreSQL · 12
| Relationships | |
|---|---|
| Requires | plpgsql |
Usage
Sources:
pg_sina_csd 0.3 is the SQLerate research extension for read-only PostgreSQL 12 query execution on SNIA/FEMU computational storage. It needs the project’s device programs, SNIA library, NVMe permissions and prepared frozen heap images. It is not a general-purpose accelerator for a writable database; the reviewed extension directory has no separate verified license grant.
Prepare an Experimental Relation
Install the matching extension/device stack first. A superuser creates the extension and prepares an already frozen, immutable experimental table. The schema is fixed as sina_csd. The 0.3 installation is reached through the supplied 0.2 base and 0.2-to-0.3 update script, which uses PL/pgSQL.
The table must already satisfy the visible/frozen-image requirements. sina_csd.prepare validates heap/index files, relation identity and FIEMAP extents and stores mappings in sina_csd.relations, sina_csd.columns, sina_csd.indexes and sina_csd.extents. Reprepare after restarting FEMU, reloading database files, reindexing or changing file layouts. Never keep using a stale mapping.
Execution Modes
pg_sina_csd.exe_path selects host-only, filter-only, csd-without-hpcp, csd-with-hpcp or SQLerate. The first retains native execution; the others progressively offload supported work. Unsupported plans fall back to PostgreSQL. The special ibex mode uses prepared integer-leading B-tree mappings for a constrained aggregate workload; sina_csd.prepare_ibex creates its group boundaries. The advertised auto mode is not implemented.
pg_sina_csd.hpcp controls host file-page-cache population and defaults on; pg_sina_csd.dcp controls PostgreSQL buffer population and defaults off. HPCP needs the project’s guest kernel module and device permissions. Both paths are specific to the frozen read-only image. pg_sina_csd.profile exposes timing/counter details; cache population is best-effort and need not accelerate the current query.
Session and Safety Boundary
LOAD initializes connection-local SNIA resources. For automatic loading, preserve existing session_preload_libraries entries and reconnect after adding this library. Do not put it in shared_preload_libraries: the upstream design avoids inheriting device connections and threads across fork. Prepare and benchmark in the documented isolated environment, keep the mapped data immutable, and compare results with the native host-only mode before interpreting performance measurements.