What NSAdaTop is
nsadatop is Nacarsoft’s Adabas session monitor: a real-time terminal UI (TUI) inspired by htop/top. It shows the active sessions of an Adabas database with colors, delta metrics (calls/transactions since the last refresh, not cumulative) and interactive keyboard navigation: sort by any column, filter, and adjust the interval without leaving the tool. It reads data through the adaopr command.
DBID 50 in the examples is fictitious: use your real Adabas database ID.
Use cases
1. Live activity monitoring
See at a glance how many sessions exist, which ones consume calls, and how the database evolves, refreshing every 10 seconds:
nsadatop -dbid 50
The header shows DBID, time, interval and filters; the status bar totals sessions, delta calls and delta transactions.
2. Hunting bottlenecks
Find the session with the highest calls-per-second rate and see which Natural program it runs and how many ISNs it holds:
nsadatop -dbid 50 -sort rate -limit 20
Use </> (or ←/→) to change the sort column live (calls, dcalls, dtrans, isns…) and ↑/↓ to inspect the suspicious row.
3. Batch windows and noise filtering
During a batch window, hide idle sessions and refresh faster to follow only the real work:
nsadatop -dbid 50 -int 3 -dcall 5 -limit 15
Press f to toggle the delta-calls filter on/off, and +/- to adjust the interval without restarting.
Command reference
Flags (all supported)
| Flag | Description | Required | Default |
|---|---|---|---|
-dbid | Adabas database ID to monitor (connects via adaopr) | Yes | — |
-int | Refresh interval in seconds (minimum 1) | No | 10 |
-dcall | Minimum delta-calls filter: only sessions with at least these calls in the interval | No | 0 (all) |
-limit | Maximum rows to display | No | all |
-sort | Initial sort column: rate, user, pid, calls, dcalls, dtrans, isns, time | No | rate |
-sort values: rate (calls/second), user (login username), pid (Adabas entry ID), calls (cumulative calls), dcalls (delta calls), dtrans (delta transactions), isns (ISNs held), time (time since logon).
Keyboard navigation
| Key | Action |
|---|---|
↑ / ↓ or k / j | Navigate rows |
< / > or ← / → | Change sort column |
+ / - | Increase/decrease the interval |
f | Toggle delta-calls filter |
r | Force immediate refresh |
h | Toggle help display |
q / ESC | Quit |
PgUp / PgDn | Page through sessions |
Home / End | Jump to first/last session |
Output columns
| Column | Description |
|---|---|
| TYPE | Session type: TERM (terminal/interactive) or BATCH (background) |
| USER | Login username of the Adabas session |
| PID | Adabas entry / process ID |
| USER-ID | Adabas user identifier |
| ENTRY-ID | Entry point identifier |
| TIME_ACTIVE | Duration since logon |
| CUR_CALLS | Cumulative ADABAS calls |
| dCALLS | Delta calls in the interval |
| dTRANS | Delta transactions in the interval |
| ISNs | ISNs held by the session |
| OPEN | Number of open files |
| TERMINAL | Terminal identifier (tty, pts) for terminal sessions |
| PROGRAM | Program or Natural object being executed |
The interface also shows a header (banner, DBID, time, interval, filters, limit), a status bar (session/call/transaction totals, active sort and filter) and a footer with the shortcuts.
Commented examples
# 1. Basic monitoring of database 50 (10 s refresh)
nsadatop -dbid 50
# 2. Faster refresh (5 s) to follow a spike
nsadatop -dbid 50 -int 5
# 3. Only sessions with at least 10 delta calls (cuts noise)
nsadatop -dbid 50 -dcall 10
# 4. Top 20 sessions sorted by delta calls
nsadatop -dbid 50 -sort dcalls -limit 20
# 5. Combined: 3 s interval, filter 5, 15 rows
nsadatop -dbid 50 -int 3 -dcall 5 -limit 15
# 6. Sessions holding the most ISNs (possible lock holders)
nsadatop -dbid 50 -sort isns -limit 20
FAQ
Error about missing adaopr? Make the Adabas operational utilities available in PATH: nsadatop uses them to read sessions.
No colors or broken layout? Use a color-capable terminal with UTF-8 encoding, preferably fullscreen.
What does dCALLS 0 on every row mean? These are interval deltas: 0 means sessions idle since the last refresh. Raise -dcall to hide them or press f.
How do I change the sort order without restarting? With </> or ←/→ inside the TUI; -sort only sets the initial order.
Minimum interval? 1 second (-int 1); adjust it live with +/-.