summaryrefslogtreecommitdiff
path: root/src/journal
diff options
context:
space:
mode:
Diffstat (limited to 'src/journal')
-rw-r--r--src/journal/journal-verify.c2
-rw-r--r--src/journal/journalctl.c17
2 files changed, 13 insertions, 6 deletions
diff --git a/src/journal/journal-verify.c b/src/journal/journal-verify.c
index 9156fd5dc0..24012931d4 100644
--- a/src/journal/journal-verify.c
+++ b/src/journal/journal-verify.c
@@ -1118,7 +1118,7 @@ int journal_file_verify(
close_nointr_nofail(entry_array_fd);
if (first_validated)
- *first_validated = last_tag_realtime ? le64toh(f->header->head_entry_realtime) : 0;
+ *first_validated = last_sealed_realtime > 0 ? le64toh(f->header->head_entry_realtime) : 0;
if (last_validated)
*last_validated = last_sealed_realtime;
if (last_contained)
diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c
index 36c3d2b688..bee26fd769 100644
--- a/src/journal/journalctl.c
+++ b/src/journal/journalctl.c
@@ -681,11 +681,18 @@ static int verify(sd_journal *j) {
char a[FORMAT_TIMESTAMP_MAX], b[FORMAT_TIMESTAMP_MAX], c[FORMAT_TIMESPAN_MAX];
log_info("PASS: %s", f->path);
- if (arg_verify_key && JOURNAL_HEADER_SEALED(f->header))
- log_info("=> Validated from %s to %s, %s missing",
- format_timestamp(a, sizeof(a), from),
- format_timestamp(b, sizeof(b), to),
- format_timespan(c, sizeof(c), total > to ? total - to : 0));
+ if (arg_verify_key && JOURNAL_HEADER_SEALED(f->header)) {
+ if (from > 0) {
+ log_info("=> Validated from %s to %s, final %s entries not sealed.",
+ format_timestamp(a, sizeof(a), from),
+ format_timestamp(b, sizeof(b), to),
+ format_timespan(c, sizeof(c), total > to ? total - to : 0));
+ } else if (total > 0)
+ log_info("=> No sealing yet, %s of entries not sealed.",
+ format_timespan(c, sizeof(c), total));
+ else
+ log_info("=> No sealing yet, no entries in file.");
+ }
}
}