Reading Records
Single-page view · as markdown
Stored Records
Peios / Using Peios / Reading Records
eventd stores events, logs, and metrics so that you can inspect what a Peios machine recorded. Each kind answers a different question and has a different delivery guarantee.
The stores hold these records:
| Kind | Contents | Delivery |
|---|---|---|
| Events | Structured records from kernel rings | Sequence receipts and detected-loss records |
| Logs | Text with an origin and output-stream flag | Best effort through the trusted output broker |
| Metrics | Numeric samples identified by names and labels | Best effort with publication authorization |
A metric series combines a name with its labels. Samples from different label sets belong to different series even when they share a name.
Producers and record meaning #
Service output reaches eventd through peinit's output broker. A log retains
its origin, stream, and run context. Hooks and health checks can have their
own origin suffixes under the service name; jobs have job identifiers. A
service attached through TTYPath writes to its terminal instead of that
capture path. Standard error identifies a stream, not necessarily an error.
Read Service Output and
Logging for capture and
backpressure behavior.
Structured events identify a type and carry fields defined by its event
catalog. Use evman to interpret those fields rather than inferring identity
or causation from the event name. A kernel ring is volatile; eventd supplies
stored history within collection and retention limits.
Counters describe accumulating quantities, gauges describe changing levels,
and histograms describe distributions. Compare samples within the same label
set and account for producer restarts before interpreting a counter's rate.
eventd publishes its own health under eventd.*.
Use Event Viewer for interactive
inspection, or query records with
evctl. Its read policy is the same boundary for either client.
Visibility #
Queries run with the caller's socket identity. eventd checks access to record names and individual fields before returning data. It omits denied records and fields without announcing their existence. An empty result therefore does not establish that nothing happened.
Use the query client rather than opening the databases directly. Direct file access bypasses eventd's query authorization.
Retention and loss #
Stored history is finite. Retention removes old records and can remove records to meet configured size limits. Kernel event rings can overwrite records before eventd reads them; log and metric sockets can drop input. A successful send is not a persistence acknowledgment.
The eventd.events.lost event describes detected missing event sequences.
It cannot reconstruct their payloads. eventd.store.quarantined describes
a corrupt database moved aside. Use the eventd evman records to interpret
the fields of either event.
See Finding Missing Records when a result differs from what you expect.
Interpreting Events
Peios / Using Peios / Reading Records
An event records an observation: an access check completed, a service started, or a package changed. Its type identifies the observation, and its fields describe it. Read the definition before drawing conclusions from a record or from its absence.
Find the definition #
Each component supplies event and field definitions in .evman files under
/usr/share/evman. The event manual reads those
installed definitions. Consult the catalog shipped with the producer's
version when interpreting older records.
An event definition describes its trigger, tier, field presence, and any meaning specific to that event. A field definition supplies its general type and vocabulary. A group names fields that travel together. The catalog can define fields that no current event carries; a definition alone is not proof that a producer writes the field.
The catalog format defines how components maintain these records. Event and field lookup belongs to the catalog, rather than a separately maintained table in Learn.
Some components also describe their events in their manuals, where an event's meaning depends on the mechanism behind it:
- The kernel's access control subsystem describes its audit records in Event Families and Delivery. The registry's Audit page and StrataFS's Audit page describe theirs. The kernel's Emission Policy page describes how it decides which event types to write.
- eventd describes the events it writes about itself in Synthetic Event Payloads.
- Authentication Events describes the logon, attestation, and credential events of authd and lpsd.
Identify the transport and origin #
KMES carries kernel and userspace events in shared per-CPU rings. The kernel
adds the event's sequence, CPU, timestamp, and identity stamps. Userspace
chooses its event type and payload, so a kernel-looking type name does not
establish a kernel origin. Check emitter.class and distinguish the stamped
identity from identities asserted inside the payload.
emitter.token.guid identifies the effective token at emission;
emitter.true-token.guid identifies the primary token before impersonation.
emitter.process.guid identifies the process instance. A null identity stamp
must remain unknown. It does not identify a privileged caller. Read the
kernel event model for the stamp and
wire-layout contract.
Some records use other paths:
- eventd inserts its own operational events into its store. They have no KMES sequence or kernel-stamped emitter identity.
- LCS watch records report registry changes through a key file descriptor. They have their own binary format and are notifications, not KMES events or an audit trail.
- Logs and metrics use separate ingestion paths and stores. Their delivery guarantees differ from event collection.
A KMES identity stamp is kernel attribution, not a cryptographic signature. It does not authenticate the truth of an arbitrary payload or provide non-repudiation for an exported record.
Decode fields according to their definitions #
A dotted payload path describes nested MessagePack maps: subject.token.sid
means the sid key inside token inside subject. It is not a literal
subject.token.sid key at the top level. A path cannot be both a value and a
container for other fields.
Read absence against the event's declared presence: required, optional, or conditional. Do not replace an omitted value with zero, an empty string, or nil. Required data missing from a record needs investigation; optional data missing from it establishes no value.
Types carry units and wire representations. SIDs, GUIDs, and ACEs use binary values; time and duration values use nanoseconds. Masks need their object kind. Parallel arrays must be interpreted together. Resolve principal names for display while preserving the original SIDs. The value conventions define the complete table.
Consumers should ignore unknown fields and retain unfamiliar values from open enumerations. Closed enumerations and field types have stronger contracts. The extension rules distinguish additive changes from vocabulary changes that require a new version. Successful transport decoding does not prove catalog conformance.
Account for loss and ordering #
A reader has its own position in each shared ring; it does not receive a private buffer. Writers can overwrite unread events. Slow readers do not block other readers or the producer, and overwritten records cannot be recovered from KMES. A later attachment can still read records that remain in the ring.
Sequence establishes order within a CPU for one boot. Keep CPU and boot context with it. Wall-clock adjustments and different CPUs prevent timestamps from establishing a total causal order across the machine.
eventd persists the records it receives and reports detected sequence gaps. Collection, storage failure, retention, filtering, and authorization can all limit what a query returns. Follow the missing-record workflow before treating an empty result or a gap in a filtered display as proof of what happened.
Querying Records
Peios / Using Peios / Reading Records
Use evctl to read events, logs, and metrics from a terminal. It sends one
query to eventd and writes only the records that the caller can read.
Before you start #
Before querying:
- Install the
evctlclient and start the configured eventd service. - Use an identity permitted to read the requested records.
- Choose the record kind and time range needed for the investigation.
Run a query #
- Select an
EVENTS,LOGS, orMETRICquery using the observability query language in the Peios userspace protocols specification (PSPU). - Pass the complete query as one quoted argument to
evctl. Quoting prevents the shell from expanding patterns or splitting strings. - Read standard output for records and standard error for diagnostics. Check the exit status before treating a finite result as complete.
For exact flags, output formats, and exit statuses, read evctl(1).
The default socket is /run/eventd/query.sock; --socket selects the
configured path when the deployment uses another location.
Simplify an expression that exceeds the limit #
eventd rejects expressions deeper than 128 levels with the query error
expression depth exceeds 128 levels. The limit applies separately to
nested grouping parentheses and to the structure built from AND and
OR predicates. A long flat chain can exceed the limit even without
parentheses.
Remove redundant grouping and simplify the predicates before retrying. The rejection is a query error, not an empty successful result. Check standard error and the exit status as you would for another query error.
Check completion #
For a finite query, evctl holds the initial records in a temporary spool
until eventd confirms completion. A query failure before that confirmation
publishes none of those records. Copying a completed spool to the output
can still fail and leave partial output.
A streaming query confirms its initial result before publishing it, then prints live records as they arrive. A later failure does not invalidate records already published. Restarting the query starts a new query; it does not resume an acknowledged cursor.
An empty successful result means that no matching, readable records were returned. It does not prove that every record remains available.
Event Viewer
Peios / Using Peios / Reading Records
Event Viewer reads this machine's records from eventd. It separates Events, Metrics, Logs, and Settings, and performs queries as your account. The backend filters records according to their read policy.
Events and logs are displayed newest first. A list starts with the newest 200 records; Show older adds another 200, and a window holds at most 1,000. Pause keeps the list still and Resume continues updates. Selecting a row shows its available fields.
Event filters narrow by type and source. Log filters narrow by origin,
text, or errors. Metrics use named dashboards of charts rather than the
row list. Dashboard preferences are personal and stored under
CurrentUser\Software\gxwi-event-viewer.
Interpreting missing records #
A missing event is not proof that it did not occur. Retention, query filters, time range, and access policy all affect the result. Event Viewer tries to read the policy and explains known hidden names. When that policy cannot be read, it reports that some data could be hidden rather than claiming complete visibility.
The Settings tab edits eventd configuration and read policy only where access permits it. It uses eventd's registry manual for meaning, defaults, ranges, and application timing. The viewer's dashboard schema belongs to its own registry manual.
See Reading Events and Logs and
gxwi-event-viewer(1).
Reading Events and Logs
Peios / Using Peios / Reading Records
Use Event Viewer to find a recorded event or a service's logs. Narrow the query enough to inspect the relevant records, then retain the context needed to interpret them.
Before you start #
You need Event Viewer, a running eventd query service, and access to the records. Know the approximate time, origin, or event type involved.
Find a record #
- Open Event Viewer and select Events or Logs. Services Manager's Logs action can open the selected service's origin.
- Set the relevant type or source for events, or origin and text filter for logs. Use the errors-only filter when that matches the question.
- Select Pause if new rows make inspection difficult. Select a row to inspect its full visible fields.
- Use Show older to extend the displayed history and Resume when you want live updates again.
The initial time range is the last 24 hours. Select a range containing the incident before paging backward; any time removes the time restriction but cannot restore records removed by retention. Apply typed filters with Enter or Apply. An errors-only filter selects standard error, which is not proof that each selected line reports a failure.
If following stops, preserve the notice before selecting Show the newest. Resuming at the newest records does not establish what happened in the gap. Use Copy on relevant rows to preserve their visible fields with the job, boot, time range, and filters.
Check the result #
Read the record's time, type or origin, and fields, together with any
visibility note. A list is bounded to 1,000 rows, so use a narrower query
or evctl when your investigation needs a different range or query shape.
If eventd refuses the connection, address that refusal rather than treating the empty display as a result. If records remain absent, check the filter, retention, and read policy before concluding that nothing was recorded.
For a systematic check of scope, access, retention, and collection failures, follow Finding Missing Records. Keep a visibility notice with the evidence: it describes readable names or an unknown policy, not proof that hidden matching records exist.
Arranging Metric Dashboards
Peios / Using Peios / Reading Records
Event Viewer's Metrics tab lets you arrange charts into personal dashboards. A chart's time range, transformation, aggregation, and grouping change the question it asks eventd.
Before you start #
You need read access to the metric and permission to save your dashboard preferences if they should persist. Inspect what the metric measures before choosing its chart options.
Arrange a chart #
- Open Metrics and select or create the intended dashboard. Without saved dashboards, the viewer shows eventd health.
- Add the relevant metric and choose the time range.
- Select the transformation and aggregation suited to its meaning. A cumulative counter often needs a rate or delta; a measured level can use its recorded samples.
- Choose whether series are combined or displayed separately, then save the arrangement.
Check the result #
Check the chart's units, range, and series labels. A combined series can hide differences between its individual sources. A gap can indicate no sample or inaccessible data, not a measurement of zero.
Dashboard preferences allow up to 64 dashboards and 32 charts per
dashboard. Malformed saved entries are skipped. Exact storage syntax is
owned by gxwi-event-viewer.regman; eventd owns query and metric semantics.
Finding Missing Records
Peios / Using Peios / Reading Records
Check query scope and collection health before concluding that a record was never written. Keep the evidence before changing retention or removing stored files.
Before you start #
Record the incident time, service or event name, and relevant job and boot identifiers. A service restart creates another run; matching only its name can mix unrelated attempts. Preserve available records before changing retention or attempting storage recovery.
For Event Viewer controls and visibility notices, follow Reading Events and Logs. The daemon checks below apply regardless of the client.
Inspect the result #
- Check the query's record kind, name filters, and time range. A relative time range changes each time the query runs.
- Check the command's exit status and diagnostics. A connection or query error is not an empty successful result.
- Confirm the caller's identity and intended read policy. Authorization can omit records or fields without disclosing them.
- Inspect detected-loss and quarantine records when your identity can
read them. Consult
eventd.events.lostandeventd.store.quarantinedin evman for their field meanings. - Check retention and storage diagnostics. Records removed by retention or held in an excluded historical shard do not return through queries.
Interpret the evidence #
The absence of a loss record does not prove complete collection. eventd cannot count every datagram rejected by a full kernel socket queue, and a storage failure can prevent the daemon from persisting its own report.
Logs reflect text received from the output broker. Whether a service sends its output to that broker belongs to the service manager's configuration. Do not change eventd's read policy to compensate for a producer that never sent a record.
A logical retention limit is not a hard filesystem quota. SQLite can retain free pages, and write-ahead logs occupy additional disk space.
Retention and unavailable history #
Read the effective settings and their defaults in eventd's registry manual. Age and size limits are removal criteria, not a promise of minimum history. Size pressure can remove records younger than the age limit. Event retention can remove an earlier boot together with its loss records; log and metric retention remove older entries or samples.
A query timeout means the query failed to finish. It is not itself evidence that ingestion lost records. Save the error, then try a narrower time range to investigate the failing query.
A running daemon can exclude an unreadable or unsupported historical shard while serving its other stores. Inspect startup diagnostics as well as the query result. Corruption encountered during a query fails that query; quarantined stores are not silently repaired into complete history.
Current retention values cannot show which records an earlier configuration removed. Likewise, a missing loss event cannot account for the final volatile batch lost during power failure. Keep these limits with the investigation.
Preserve the store #
Do not delete live database files to make a query succeed. Preserve the query, diagnostics, timestamps, and relevant configuration, then follow the deployment's recovery procedure. Replacing a corrupt store gives the service an empty store; it does not recover lost history.
Deleting records leaves pages for reuse and does not necessarily shrink a
database file. eventd does not automatically run VACUUM. Do not treat a
logical retention setting as a procedure for repairing or compacting a live
store. Keep quarantined files intact for the administrator handling recovery.
Check the conclusion #
Record which possibilities the evidence supports: query scope, authorization, retention, collection loss, or unavailable storage. If the checks are inconclusive, retain that uncertainty. Save a completed query with its completion context instead of labeling an empty display as proof that an event never happened.
Saving Query Evidence
Peios / Using Peios / Reading Records
Keep a query result with its diagnostics and scope so that another reader can distinguish a completed capture from an empty or failed attempt.
Before you start #
Before capturing records:
- Choose a private directory and unused output filenames.
- Select a finite query without
STREAM. - Record the identity, machine, query text, time zone, and client version.
The destination directory's native security descriptor and inheritance must
restrict new files to the intended readers. A shell umask or chmod is not
a substitute for that Peios access policy. Use an existing directory you
control; ask its administrator to establish the policy if needed.
Check that both output names are unused regular-file destinations, not
existing files, symlinks, or pipes. Shell redirection can truncate a file
before the query runs. Allow space for the output and the client's temporary
spool. The process's temporary directory must be writable, suitable for
sensitive data, and support anonymous temporary files (O_TMPFILE).
Capture the result #
- Write standard output directly to the result file and standard error to a separate diagnostic file. Avoid a pipeline that can close early.
- Record the command's exit status immediately after it exits, before another command replaces the shell's status value.
- Inspect the diagnostics and mark a nonzero or interrupted attempt as failed. A failed output copy can leave part of a completed result.
- Keep the exact query, capture times, status, and diagnostics beside the result. Record any result-count limit and whether a relative time range was used.
For example, after checking the private destination and unused names:
capture_status=
This is at most 50 readable matching records since one hour ago, not all
records from that hour. The relative range moves on each attempt. Keep the
start and finish times, query, installed evctl version, and status beside
the capture. JSON Lines stores one JSON object per record.
If the shell cannot open a redirection target, the client might not run.
Preserve that error too. For a client failure, consult evctl(1) for exit
statuses and inspect both destination and temporary-storage errors. Use new
names for another attempt rather than overwriting its evidence.
evctl treats an output pipe closed by its reader as success. A pipeline
that selects only the first records therefore does not establish that the
whole query was captured. Filter a saved result after capture instead.
Check the result #
For a direct capture to a regular file, a zero status means the finite query and output publication completed. It does not establish complete system history: authorization, retention, and collection loss still bound what the result contains.
Keep the original capture private and unchanged. Permission to read a record does not automatically permit sharing it with another audience.
Finding an Event's Meaning
Peios / Using Peios / Reading Records
evman reads installed event documentation. It explains what an event records
and what its fields mean; it does not report which events occurred on this
machine.
Read the event and the field together #
An event definition describes when it is emitted and which fields it can carry. A field definition describes the field's general type and meaning. An event can add a narrower explanation for its use of that field.
Pay attention to required, optional, and conditional presence. A missing field is not necessarily malformed if the event's rules make it conditional. Likewise, a familiar field name does not imply that every event carries it.
Distinguish enumerated values from an open vocabulary #
A closed value list claims completeness under its definition. An open list can grow, so consumers need a deliberate policy for values they do not recognize.
Some common fields belong to the record header rather than the payload. Their documentation identifies that location. Do not assume that the same information appears twice.
Search the installed corpus #
Exact lookup selects a named event or field. Prefix lookup helps explore a subsystem, and keyword search matches names and summaries. Derived names can resolve through documented suffix or standard-attribute rules; read which rule supplied the result.
For example, look up an access-check event, a field, or a subsystem prefix:
The field card lists events that carry the field. Use those relationships when replacing a field-index lookup. The installed packages determine the available definitions; a missing package can mean missing documentation. For an older capture, keep the producer's version and catalog with the record rather than assuming the current definitions are identical.
Packages supply definitions under /usr/share/evman. Catalog validation
checks consistency across those definitions. A valid catalog describes an
interface; it does not establish that a particular event was recorded or that
its payload passed runtime validation.
Use the event store or Event Viewer to investigate occurrences. Use evman(1)
for lookup and catalog-validation syntax.
Inspecting the Raw Event Stream
Peios / Using Peios / Reading Records
revstrm reads KMES directly, without eventd's storage or query path. It is a
diagnostic consumer, not a durable audit sink. Use eventd for stored history
and retain its collection/retention limits when drawing conclusions.
Observe a bounded stream #
- Confirm that the caller has enabled
SeSecurityPrivilegeand the native event interface is available. Administrator membership alone does not establish that the privilege is enabled. - Run
revstrmto follow, orrevstrm --snapshotto drain available data and exit. Snapshot drains CPU rings in order; it is not an atomic cross-CPU snapshot or a request for history predating attachment. - Narrow display with repeatable
--typeglobs or--originclasses. Use--prettyto expand payloads when studying individual records. - Record loss markers and stderr with the output. A ring that falls behind overwrites old data, and display filtering does not prevent that loss.
The header gives UTC time of day, CPU, per-ring sequence, origin, and event type. It omits the calendar date and does not merge CPUs into one event order. Do not interpret a displayed sequence gap without accounting for filters.
Interpret payloads and completion #
The installed event catalog supplies field types. Known SIDs, GUIDs, masks, enumerations, timestamps, durations, and byte counts receive readable forms; unknown bits and values remain numeric. Without a matching catalog entry, field-name fallbacks are less authoritative. Malformed MessagePack falls back to a hex preview rather than becoming a decoded record.
Compact output can truncate a long payload. Pretty output expands it but can slow draining. Redirecting to a file or reducing output cost can help; neither guarantees lossless capture. Native file policy applies to the chosen destination.
Follow mode ends on interruption, output failure, or exhausted drain threads.
The implementation treats output failure as termination and can finish after
per-ring errors, so a zero exit status alone is not a complete-capture
attestation. Inspect diagnostics and loss accounting. revstrm(1) defines
its option and output details; evman explains event schemas.
Operating eventd
Peios / Using Peios / Reading Records
eventd runs as a managed service with protected store directories and a restricted service identity. Its package supplies registry seed files; installing those files does not apply their contents to the registry.
Startup configuration #
The registry key Machine\System\eventd supplies six required paths:
three store directories and three socket paths. Missing or invalid paths
prevent startup. eventd(8) and the eventd regman records describe the
command and configuration values.
The service definition runs a short --prepare-security hook as SYSTEM
before starting the daemon. That hook prepares registry authorization
defaults. The long-running service does not acquire policy-editing
permissions merely because the hook needed them.
A deployment must provision the service identity, privileges, registry configuration, and protected directories together. Copying the executable alone is not a complete installation.
Live changes #
The daemon watches configuration and applies valid tuning changes.
Invalid live changes keep the last valid setting. Store paths, socket
paths, and shard count apply at restart. Read each regman record's
applies field before planning a change.
Read policy and metric publication policy use security descriptors under
Machine\System\eventd\Security. A read grant does not grant metric
publication. Broader grants can disclose records that were already stored.
Health and storage #
The daemon writes its own eventd.* health samples directly to the metric
store. These do not pass through the publication socket. Health counters
restart when eventd restarts, so compare changes with that lifecycle in
mind.
A store-size metric measures disk use, while retention limits logical live data. A database can retain reusable free pages after deletion. Inspect both filesystem capacity and retained data when diagnosing pressure.
For implementation details, read the eventd manual.
Changing Event Viewer Policy Settings
Peios / Using Peios / Reading Records
Event Viewer's Settings tab exposes eventd's configuration and read policy. Configuration controls the service; policy controls which names and fields accounts can read. Your personal dashboards are separate preferences.
Before you start #
You need write access for the selected configuration or policy entry. Record its current value or descriptor and read eventd's registry manual. Socket and storage paths are displayed but are not editable here.
Change and verify #
- Open Settings and select the relevant configuration group or read-policy pattern.
- Read the expected type, range, default, and application timing. Enter the value and save, or use the permissions editor for a pattern.
- Inspect the result. A value outside the accepted range is refused.
- Verify the service's active behavior at the stated time. For access policy, query as the affected account rather than only as an administrator.
Pattern scope #
A pattern can cover a name and its descendants. The most specific matching
pattern wins. Removing a specific pattern exposes the broader policy; it
is not necessarily a denial. The fallback * patterns cannot be removed
through this interface.
A new pattern starts from the permissions that already apply to its name and changes only when the descriptor is applied. Confirm the intended scope before adding a broad grant or deny. Use eventd's own documentation for the precise access model and configuration semantics.