Skip to content

omni_vfs

Virtual File System

omnigres · Virtual File System

Overview

IDExtensionPackageVersionCategoryLicenseLanguage
2974omni_vfsomnigres0.2.2FEATApache-2.0C
AttributeHas BinaryHas LibraryNeed LoadHas DDLRelocatableTrusted
--s-d--NoYesNoYesnono

Packages

TypeRepoVersionPG Major CompatibilityPackage PatternDependencies
EXTPIGSTY0.2.219 18 17 16 15omnigresomni_vfs_types_v1, dblink
RPMPIGSTY2026021219 18 17 16 15omnigres_$vpostgresql$v-contrib, postgresql$v-plpython3, python3-pip
DEBPIGSTY2026021219 18 17 16 15postgresql-$v-omnigrespostgresql-plpython3-$v, python3-pip
Linux / PGPG19PG18PG17PG16PG15
el8.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
el8.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
el9.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
el9.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
el10.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
el10.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
d12.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
d12.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
d13.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
d13.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
u22.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
u22.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
u24.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
u24.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
u26.x86_64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212
u26.aarch64N/APIGSTY 20260212PIGSTY 20260212PIGSTY 20260212PIGSTY 20260212

Source

pig build pkg omnigres;		# build rpm/deb

Install

Make sure PGDG and PIGSTY repo available:

pig repo add pgsql -u   # add both repo and update cache

Install this extension with pig:

pig install omnigres;		# install by package name
pig install omni_vfs;		# install by extension name

pig install omni_vfs -v 18;   # install for PG 18
pig install omni_vfs -v 17;   # install for PG 17
pig install omni_vfs -v 16;   # install for PG 16
pig install omni_vfs -v 15;   # install for PG 15

Create this extension with:

CREATE EXTENSION omni_vfs CASCADE; -- requires omni_vfs_types_v1, dblink

Usage

omni_vfs: Virtual File System

The omni_vfs extension provides a unified Virtual File System API for PostgreSQL with multiple backend support.

Core Functions

omni_vfs.list(fs, path) – Lists directory contents, returns set of (name, kind).

omni_vfs.list_recursively(fs, path, max) – Recursive listing. Use max to limit results.

omni_vfs.file_info(fs, path) – Returns file metadata: size, created_at, accessed_at, modified_at, kind.

omni_vfs.read(fs, path, file_offset, chunk_size) – Reads file content as bytea.

omni_vfs.write(fs, path, content, create_file, append) – Writes content, returns bytes written.

Backends

Local filesystem:

SELECT omni_vfs.local_fs('/mount/path');
-- No access outside this directory is permitted

Database-backed (table_fs):

SELECT omni_vfs.table_fs('filesystem_name');

Remote filesystem:

SELECT omni_vfs.remote_fs('dbname=otherdb host=127.0.0.1', $$omni_vfs.local_fs('/path')$$);

Example

WITH fs AS (SELECT omni_vfs.local_fs('/data') AS fs),
     entries AS (SELECT fs, (omni_vfs.list(fs, '')).* FROM fs)
SELECT entries.name, entries.kind,
       (omni_vfs.file_info(fs, '/' || entries.name)).*
FROM entries;

Table reader