Journalctl Previous Boot: 5 Essential Checks After a Crash

To read journalctl previous boot logs, first run sudo journalctl --list-boots, then use sudo journalctl -b -1 -n 100 --no-pager to read the last 100 entries from the previous boot available in the journal. If the list shows only 0, jump to missing previous-boot logs. If the host rebooted several times, match the incident time to a boot ID first.

Journalctl previous boot illustration with Linux terminal logs on either side of a restart

Quick answer. The journalctl previous boot view shows the logs the host retained. A gap between its final entry and the first entry of the next boot gives you a time window to investigate. Use hypervisor events, a remote log collector, or an outside health check to narrow that window.

1. Use journalctl previous boot logs to identify the right restart

Use these commands on a Linux host or VM you administer. A user account may see only part of the journal. Run the investigation with an account that has the appropriate access, and include the host or VM name and time zone in your notes.

sudo journalctl --utc --list-boots --no-pager
sudo journalctl --utc -b -1 -n 100 --no-pager
Journalctl previous boot decision guide: read offset minus one, match older sessions by boot ID, or check retention when only zero appears
Choose your next check from the boot list.

When both -1 and 0 appear, use the recorded time range to choose the row. The excerpt below is adapted from the openSUSE Leap journal reference. Boot IDs are shortened, and column headings are added for readability.

Boot list excerpt adapted from the openSUSE documentation (EDT)
OffsetBoot ID prefixFirst retained entryLast retained entry
−1097ed2cd…May 26, 08:36:56May 30, 05:33:44
0156019a4…May 30, 05:34:09May 30, 06:15:01

In this example, the older boot’s last retained log and the newer boot’s first retained log are 25 seconds apart. If a monitor first reported trouble inside that gap, look for external evidence from the same interval. The last entry may precede the actual shutdown, and the first entry may follow the initial reset.

For a single query on the live host, -b selects the current boot and -b -1 selects the previous available boot. For repeated queries, copy the full 32-character ID from your own list and replace BOOT_ID below. The ID stays tied to that boot while the relative offset can change after another restart.

sudo journalctl --utc -b BOOT_ID -o short-iso-precise --no-pager

2. Compare previous and current boot logs

Begin with the end of the selected boot in the full journal. Look for a sequence of service stops and shutdown activity, changes in application health, storage timeouts, or a sudden end to ordinary traffic. Read the beginning of the next boot separately. Startup messages may explain why an outage persisted after the machine restarted.

sudo journalctl --utc -b BOOT_ID -n 100 -o short-iso-precise --no-pager
sudo journalctl --utc -b -o short-iso-precise --no-pager | head -n 80

The second command samples the current boot. If another boot sits between the incident and the current session, substitute its ID after -b so you compare adjacent boots. For a long journal, start with a small time window around the symptom. The example below uses an explicit UTC window. Substitute the actual incident date and time.

sudo journalctl -b BOOT_ID --utc -o short-iso-precise --no-pager \
  --since '2026-11-19 03:05:00 UTC' --until '2026-11-19 03:20:00 UTC'
sudo journalctl --utc -b BOOT_ID -k -n 150 --no-pager
sudo journalctl --utc -b BOOT_ID -u nginx.service -n 100 --no-pager

-k selects kernel records. -u nginx.service narrows the view to the unit and relevant systemd messages about it. Substitute the affected unit name on your machine. If the application writes directly to its own files or sends events to a collector, read that destination too. Record the time of the symptom from a source such as an HTTP monitor, then return to the full journal for the entries immediately before it.

If the guest clock changed during the incident, compare events within one boot using -o short-monotonic. Those timestamps represent elapsed time within that boot. For a timeline spanning two boots or multiple machines, use UTC from the wall-clock view and document any known clock drift.

How to read a normal shutdown, abrupt stop, or slow recovery

Look at the order of events in the journalctl previous boot view before narrowing to a component. A service may report an error every day while the machine is healthy. Check whether the same warning appears in another retained boot and whether anything changed just before the incident. A repeated warning can still matter if the timing, affected device, or volume of events changes.

Orderly shutdown. An orderly sequence may include the affected service stopping, filesystems unmounting, and systemd reaching shutdown or reboot targets. Match that sequence to a change ticket, deployment, provider action, or other independently recorded event. A clean shutdown sequence can confirm that teardown occurred even if the request that initiated it remains unknown.

Abrupt ending. Compare the final lines of the journalctl previous boot log with errors from the kernel and with the monitor’s last healthy check. An I/O error or watchdog warning near the end is a lead. It may also explain why later records never reached disk. If the guest journal ends with routine traffic, an external monitor or host event log may supply the only useful time anchor.

Slow recovery. Locate the next boot and use the same service filter you used in the older one. Compare the first service start attempt, the first successful start, and the first successful outside health check. If the service reports that it started before clients can connect, check its dependencies and the path the monitor actually uses.

sudo journalctl --utc -b OLD_BOOT_ID -u nginx.service --no-pager
sudo journalctl --utc -b NEXT_BOOT_ID -u nginx.service --no-pager

Use the smallest useful time window and widen it if the return is empty. Keep at least one copy of the unfiltered interval. A priority-only query can hide routine shutdown or startup messages that explain the sequence.

3. Diagnose missing journalctl previous boot logs

Check from an authorized account first. Run sudo journalctl --list-boots and sudo journalctl --disk-usage. Confirm you are on the intended VM. If it was rebuilt, the console name or IP address may have stayed the same while the guest filesystem changed.

What to check when the previous boot is missing
ObservationWhat to verify next
Boot list differs between usersConfirm journal read access and collect under the approved account.
Only current boot is present with authorized accessReview the effective storage configuration, journal directories, retention limits, and any evidence of disk replacement.
The old boot exists but ends earlyCompare remote logs, the VM console and monitoring timestamps. Check the storage health of the guest and host if available.
The boot exists but the service query is emptyCheck the unit name, application log destination, and the unfiltered journal for the same time window.
systemd-analyze cat-config systemd/journald.conf
ls -ld /var/log/journal /run/log/journal
sudo journalctl --disk-usage

When journalctl --list-boots shows only 0 under an authorized account, the oldest boot visible in the selected journal is also the newest one. If the VM was rebuilt or rolled back, confirm the guest disk and machine identity. If it is the same installation, check the effective storage settings and the age of the journal files. A missing -1 can reflect volatile storage, deletion or rotation, a failed write, or access to a different journal.

Under Storage=auto, journald uses persistent storage when /var/log/journal exists. Storage=volatile keeps journal files under /run/log/journal, so those records are lost at reboot. Persistent storage still has size and retention limits. Read the journald storage and retention reference alongside the configuration installed on your distribution.

Verify that the next reboot retains logs

Use an expendable systemd VM first. Confirm that persistent storage is active and has enough disk space. If your environment needs a storage change, follow its change procedure and the distribution’s instructions for applying it. On a system configured for persistent logging, sudo journalctl --flush asks journald to move available runtime journal data to disk. That operation acts on data still present in the current session.

Before a planned test reboot, record the current boot ID and write a unique marker using logger. Check that the marker appears in the current journal before rebooting. If journald is reading from a different namespace, verify the marker in the same namespace you intend to inspect after reboot.

cat /proc/sys/kernel/random/boot_id
logger -t journal-retention-test 'Pre-reboot marker: retention-check-01'
sudo journalctl -b -t journal-retention-test -n 10 --no-pager

After the reboot, rerun the boot list and substitute your recorded ID for BOOT_ID. Seeing the same ID and the marker after restart confirms that this test entry survived. Using the ID is especially useful if the test environment restarted twice.

sudo journalctl --utc --list-boots --no-pager
sudo journalctl --utc -b BOOT_ID -t journal-retention-test -n 10 --no-pager

If the journalctl previous boot view is still empty, check a collection host, VM console, archived journal, or backup for previous boot records. If you have a directory of copied binary journal files, query it separately with journalctl --directory=/path/to/journal-copy --list-boots and use the ID from that list. Keep the incident record explicit about which source produced each timestamp.

Journalctl previous boot retention test: record the boot ID, reboot, and retrieve the same log marker
A successful retention test retrieves the same marker from the same boot ID after restart.

Inspect a copied journal without mixing it with the live host

When a Linux host has been replaced, administrators sometimes open the replacement’s journal and find a familiar hostname. Start by identifying the saved journal source and its collection time. Use --directory for a directory of binary journal files, and run --list-boots against that directory before reading an individual boot. Offsets in a copy are relative to the boots that copy contains.

sudo journalctl --directory=/path/to/journal-copy --utc --list-boots
sudo journalctl --directory=/path/to/journal-copy --utc \
  -b BOOT_ID -n 100 --no-pager

If all you have is a plain-text export, use its timestamp and boot ID annotations to place it on the timeline. Query the original binary journal or ask the person who collected it for a boot list if the export omits those details. A text export can answer what an operator saw at the time, while its collector and capture window define how much evidence the export preserves.

For hosts that retain fewer boots than intended, compare the journalctl previous boot list with monitoring or reboot records across several days. Record the oldest available entry, the journal’s disk use, and the applicable storage limits. This gives the system owner a concrete way to tell whether the retention policy meets the expected incident-response window. Repeat the marker test after material storage changes.

4. Reconstruct a crash timeline from multiple sources

In this illustrative case, a VM serves an internal application. Its previous boot ends with storage errors, and the application starts again after the reboot. Each source answers a different question.

Illustrative timeline in UTC
Time (UTC)SourceObservation
03:11:46Guest kernel journalFirst retained I/O error involving the application volume.
03:12:02External monitorFirst failed application health check.
03:12:08Previous guest bootLast retained message. No shutdown sequence appears in the captured interval.
03:13:19Hypervisor event logReset recorded for the same VM.
03:13:24Next guest bootFirst retained startup message.
03:14:01External monitorFirst successful application health check.

A defensible handoff would say: “The guest logged an I/O error before the first failed health check. The hypervisor recorded a reset about one minute later. The reset trigger is unconfirmed.” Ask the host or platform owner for the reset reason, datastore events and any automated recovery action around 03:13 UTC. That is the evidence that could tell you whether the reset was triggered by a person, a recovery policy or a separate host event.

Linux reboot evidence timeline comparing the guest journal, external health monitor, and hypervisor reset event
Use each log source for the event it can actually establish.

Check whether the timestamps agree

When a cloud console shows a reset at 03:13 UTC and the guest shows a kernel warning at 03:12 UTC, compare how both timestamps were produced. A console may display when an event was received, while the Linux journal may display when the guest logged it. A polling monitor reports the time of its first failed probe. A monitor checking once a minute can place the outage in an interval between probes, even if both clocks are accurate.

Start the investigation with a timeline that labels each source and each timestamp. If you have evidence that a guest clock was off, retain the original timestamps in the incident notes and explain any adjustment separately. Use the monotonic view for comparisons inside one boot when wall time jumps. Keep a separate row for any event whose timestamp is uncertain.

In the worked example, the strongest chain is the storage warning in the journalctl previous boot log, the independent health-check failure, and the subsequent hypervisor reset. If the host team later identifies an automated recovery policy, add that event and its timestamp to the record. The earlier observations remain useful, even when the explanation changes.

5. Save a record that someone else can verify

When exporting journalctl previous boot logs, record the boot ID, command, time window and log source together. Export only the relevant interval to an access-controlled location. The example creates a private directory and saves a short text view. Keep the original export separate from any redacted excerpt you share.

umask 077
evidence_dir=$(mktemp -d)
sudo journalctl -b BOOT_ID --utc -o short-iso-precise --no-pager \
  --since '2026-11-19 03:05:00 UTC' --until '2026-11-19 03:20:00 UTC' \
  > "$evidence_dir/previous-boot-utc.log"
printf '%s\n' "$evidence_dir"

Check the command completed successfully and inspect the first and last timestamps in the saved file. Logs can contain request paths, account names and infrastructure details. Review the excerpt before passing it to a vendor or adding it to a broadly visible ticket.

Host / VM:
Previous and next boot IDs:
Time window (UTC):
First observed symptom and source:
Last retained entry in old boot:
First retained entry in next boot:
Independent evidence and source:
Unanswered question / owner:
Restricted evidence location:
Quick check: does an abrupt journal ending prove a power failure?

An abrupt ending establishes the edge of the available record. Check the hypervisor, provider activity, UPS or physical console as appropriate to investigate the interruption. Keep the exact failure mode open until an independent source supports it.

Journalctl previous boot FAQ

Can I see only kernel messages from the previous boot? Use sudo journalctl -b -1 -k after confirming the offset. Use the actual boot ID if you are investigating an older incident. Query the application separately by unit or read its own logs.

Why do I see a service failure only in the new journal? The service might have broken during startup or lost a dependency while the host recovered. Compare both boots for the service, then check related units such as filesystems, network readiness, or the database. A failed health check after boot can identify a recovery problem even if the original failure remains unknown.

Can journalctl previous boot logs confirm a power loss? Look for a matching event from a UPS, hypervisor, cloud control plane, or physical console. The previous boot journal can narrow the time window. The outside source can establish what happened during a period where the guest could no longer record events.

For a related Kioptrix workflow, see Kioptrix Recovery Routine for recording the baseline and preserving evidence before changing VM state.

Command and storage references: systemd journalctl manual and journald.conf manual. For distribution-specific behavior, compare these with the manual pages installed on the host.

Stay Updated with Kioptrix

Get practical guides, useful resources, and new articles delivered to your inbox.

No spam. Unsubscribe anytime. Read our Privacy Policy.