Trishul SNMP Suite 2.0.2 is a bundle-first SNMP lab and operations platform. The
runtime is centered on:
trishul-snmptrishul-smiThe shipped runtime provides:
//docs/api/meta and /api/health/api/.../api/wsThere is no Nginx layer and no external WebSocket bridge or broker in the
current release path. FastAPI serves both the built UI and the live /api/ws socket
directly.
Typical browser flow:
/frontend/dist/api/settings/loginX-Auth-Token on authenticated requests/api/ws for live status, stats, trap, and simulator-log updates/api/... call flat backend services directlyIf frontend/dist does not exist, the backend serves a placeholder page that
asks the operator to build the frontend artifact.
Defined in backend/app/main.py.
Responsibilities at startup:
MibBundle instanceSource lives under frontend/ and builds to frontend/dist/.
The shipped UI is organized around seven pages:
DashboardSimulatorWalk & ParseTrapsMIB BrowserMIB ManagerSettingsThe shell uses hash navigation, page partial loading, and the API surface
exposed by the backend, plus /api/ws for live updates on the main
operational pages.
All routes live under backend/app/api/routes/ and call flat service modules
directly. There is no bridge or adapter layer between the routes and the
services.
Route modules:
settings.py — login, logout, session check, auth, app settingsstats.py — stats read and resetsimulator.py — simulator start, stop, restart, status, custom data, logswalker.py — walk executetraps.py — listener start, stop, status, send, event list, clearmibs.py — MIB status, upload, reload, validate, export, delete, objects, resolvebrowser.py — OID browser: modules, tree, search, node detailsystem.py — metadata, healthws.py — WebSocket endpointbackend/app/services/ contains flat service modules. Routes call them
directly — no intermediate shell or bridge classes.
Key services:
| Module | Responsibility |
|---|---|
runtime.py |
In-process SNMP responder, manager (GET/GETNEXT/GETBULK/walk), notification listener, trap/inform send, event decode |
bundles.py |
MIB bundle compile, activate, rollback via trishul-smi |
mib_sources.py |
Upload directory scanning, source group precedence, shadowing detection, remote source caching |
mib_mutations.py |
MIB upload, partial compile, dependency fetch, delete with rollback |
mibs_service.py |
Orchestrates mib_sources + mib_mutations + bundles for route handlers and source-group-aware status or export views |
browser_service.py |
OID resolve, module tree, OID tree, search via MibBundle |
traps_service.py |
Trap listener lifecycle, send, event formatting, history reads |
simulator_service.py |
Simulator lifecycle, custom data, logs |
walker_service.py |
Walk execution and result formatting |
stats_service.py |
Stats aggregation from runtime, history, and state store |
history.py |
Durable notification event storage and retrieval |
session.py |
Auth credential storage and session management |
state_store.py |
Persistent key-value settings backed by SQLite |
app_settings.py |
Operator app settings read and write |
realtime.py |
WebSocket connection manager and broadcast functions |
bundle_state.py |
In-memory MibBundle singleton |
backend/app/services/bundles.py drives MIB compilation through trishul-smi.
Compile output is stored as versioned bundle directories containing:
manifest.jsonoid_index.jsonSQLite records bundle metadata, compile runs, and the active-bundle pointer.
The active bundle is loaded into memory at startup as a MibBundle instance.
All catalog, browser, and trap resolution queries use this in-memory bundle —
there are no SQLite catalog index tables.
backend/app/services/runtime.py owns all live SNMP surfaces in-process as
async tasks. There are no worker subprocesses.
V2cResponder — SNMP agent responding to GET, GETNEXT, GETBULKV2cManager — manager-side GET, GETNEXT, GETBULK, walk, bulkwalkV2cNotifier — send trap or informV2cNotificationListener — receive traps and informsThe runtime supports simulation rules (counter, random, timestamp, uptime) and uses the active compiled bundle for symbolic translation and notification enrichment.
The default data root is backend/data/ locally or /app/backend/data/ in the
container.
Important runtime paths:
trishul_v2.sqlite3bundles/sets/bundles/cache/tsmi/mibs/configs/custom_data.jsonconfigs/Container deployments emit logs to stdout/stderr and rely on Docker log
rotation. backend/data/logs/backend.log is only used when file logging is
explicitly enabled.
The current SQLite schema covers:
app_settings — operator app settings key-value storeauth_sessions — durable session tokensbundle_sets — compiled bundle recordsbundle_modules — per-module compile output metadatacompile_runs — compile history with error capturenotification_events — durable received and sent notification history with FTSThere are no catalog index tables. The active bundle is queried in memory via
the loaded MibBundle instance.
The container path uses a multi-stage Docker build:
trishul-smi and trishul-snmpuvicorn app.main:app from /app/backendThe canonical operator entrypoint is ./install-trishul-snmp-suite.sh.