slimtoolkit/slim · error
saving reports failed: %w
Error message
saving reports failed: %w
What it means
After a successful monitor status, processMonitoringResults calls s.artifactor.Process(...) to persist the PE, fan and Pt reports. If artifactor.Process fails, the error is wrapped with 'saving reports failed'. Monitoring data was collected but could not be saved/processed.
Source
Thrown at pkg/app/sensor/controlled/controlled.go:256
}
log.Info("sensor: composite monitor is done, checking status...")
report, err := mon.Status()
if err != nil {
log.WithError(err).Error("sensor: composite monitor failed")
return fmt.Errorf("composite monitor failed: %w", err)
}
if err := s.artifactor.Process(
mon.StartCommand(),
s.mountPoint,
report.PeReport,
report.FanReport,
report.PtReport,
); err != nil {
log.WithError(err).Error("sensor: artifact.Process() failed")
return fmt.Errorf("saving reports failed: %w", err)
}
return nil // Clean exit
}
View on GitHub (pinned to 81940d17fa)
Solutions
- Check the wrapped error from artifactor.Process
- Verify the artifacts output directory is writable and has free space
- Validate report contents (PeReport/FanReport/PtReport) are not nil/corrupt before processing
Defensive patterns
Strategy: validation
Validate before calling
// pre-flight disk space check on artifacts volume
if st, err := os.Stat(artifactsDir); err == nil {
// ensure writable: attempt temp file create
f, err := os.CreateTemp(artifactsDir, "wtest")
if err != nil { log.Fatalf("artifacts dir not writable: %v", err) }
f.Close(); os.Remove(f.Name())
} Try / catch
if err != nil && strings.Contains(err.Error(), "saving reports failed") {
// check disk full / permissions; reports may be recoverable from monitor memory
} Prevention
- Enforce free-space thresholds on the artifacts volume
- Keep artifacts dir writable by the sensor user
- Validate sub-monitor reports are populated before Process
When it happens
Trigger: artifactor.Process returns an error while writing reports — disk full, unwritable artifact directory, failure processing report content.
Common situations: Disk exhaustion on the artifact volume, permission issues after env prep, malformed report data from a sub-monitor.
Related errors
- failed to prepare artifacts env: %w
- composite monitor failed: %w
- sensor shutdown before monitor stop
- ambiguous start command: cannot use [app_name,app_args] and
- run sensor without monitor failed: %w
AI-assisted analysis of slimtoolkit/slim@81940d17fa (2026-08-31).
Data as JSON: /api/errors/d5613646ddba0e2d.
Report an issue: GitHub.