Documentation
¶
Overview ¶
Package pstore provides operations for Linux pstore, mainly to read the pstore log on reboot. ref. https://www.freedesktop.org/software/systemd/man/latest/systemd-pstore.service.html
Index ¶
Constants ¶
View Source
const DefaultPstoreDir = "/var/lib/systemd/pstore"
DefaultPstoreDir is the default directory for pstore logs. e.g., "/var/lib/systemd/pstore/7530486857247/dmesg.txt" The numeric subdirectory (e.g., "7530486857247") is a unique identifier generated by systemd-pstore, often based on the machine's DMI product UUID, to distinguish logs from different machines or boot instances.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store interface {
// Scan scans the pstore logs with the match function, and inserts
// the matching events into the database.
Scan(ctx context.Context, matchFunc func(line string) (eventName string, message string)) error
// Get returns the history events since the given timestamp.
Get(ctx context.Context, since time.Time) ([]History, error)
}
Click to show internal directories.
Click to hide internal directories.