Skip to content

How to Get System Information

This page explains how to use the INFO API endpoints to obtain information about databases, tables, sessions, processes, and system.

KDB.AI provides a set of utility APIs that let you inspect the current operational state of your environment — from data storage and compute resources to active sessions and overall system metrics. These tools help developers monitor usage, troubleshoot performance issues, and validate system configurations.

Get table info

Retrieve information about a specific table in a database:

db = session.database("default")
table = db.table("table1")
table.info()
// Open connection
`gw set hopen 8082;

// Get table info
gw(`getTableInfo;args:`database`table!(`default;`table1))
curl -H 'Content-Type: application/json' localhost:8082/api/v2/info/databases/default/tables/table1

Get database info

Retrieve information and table summaries for a single database:

db = session.database("default")
db.info()
// Open connection
`gw set hopen 8082;

// Get Database Info
gw(`getDatabaseInfo;args:enlist[`database]!enlist `default)
curl -H 'Content-Type: application/json' localhost:8082/api/v2/info/databases/default

Get databases info

Retrieve information about all databases (and included tables) in your environment:

session = kdbai.Session(endpoint='http://localhost:8082')
session.databases_info()
// Open connection
`gw set hopen 8082;

// Get databases info
gw(`getAllDatabasesInfo;`)
curl -H 'Content-Type: application/json' localhost:8082/api/v2/info/databases

Get session info

Monitor how many sessions are active and when they were started. This data is helpful for tracking session activity, monitoring system usage, and managing concurrent access to the system.

session = kdbai.Session(endpoint='http://localhost:8082')
session.session_info()
// Open connection
`gw set hopen 8082;

// Get session info
gw(`getSessionInfo;`)
curl -H 'Content-Type: application/json' localhost:8082/api/v2/info/session

Get process info

Retrieve detailed runtime information about the active KDB.AI processes. This includes internal engine status such as process ID, memory usage, uptime, CPU load, and other key metrics.

session = kdbai.Session(endpoint='http://localhost:8082')
session.process_info()
// Open connection
`gw set hopen 8082;

// Get processes info
gw(`getProcessInfo;`)
curl -H 'Content-Type: application/json' localhost:8082/api/v2/info/process

Get system info

Retrieve a full snapshot of the KDB.AI system’s current state, including information on databases, processes, and sessions. This consolidated view is ideal for health checks, diagnostics, and resource monitoring.

session = kdbai.Session(endpoint='http://localhost:8082')
session.system_info()
// Open connection
`gw set hopen 8082;

// Get system info
gw(`getSystemInfo;`)
curl -H 'Content-Type: application/json' localhost:8082/api/v2/info/system

The returned object contains:

  • Database summary: Disk usage, number of databases, and per-table statistics (row counts, disk per table).

  • Process overview: Live metrics on memory, CPU, and state of each process (worker or gateway), along with currently assigned tasks.

  • Session info: List of active sessions, including IDs and start times.

This API is especially useful for system-wide audits and capacity planning.