journalctl

Query the systemd journal

journalctl [options] [field=value]

Query the contents of the systemd journal.

Background

Without parameters, shows the full content , starting with the oldest entry (see -r).

Output is filtered based on field=value example: "_SYSTEMD_UNIT=httpd.service" . See systemd.journal-fields(7)
Multiple field=value are anded unless field is the same, then ored.

"+" between other terms causes all matches before OR after .

Filter the entries by specifying an absolute file path as an argument, a file or a symbolic link .
When file path refers to an executable , an "_EXE=" match for the canonicalized binary path is added .
When a file path refers to an script, a "_COMM=" match for the script name is added .
When a file path refers to a device node, "_KERNEL_DEVICE=" matches for the kernel name of the device and for each of its ancestor devices is added .

Constraints using --boot, --unit=, etc., limit entries output(logical AND).

Output is interleaved from all journal files, whether they are rotated or currently being written including user journals.

The journals to be used can be restricted using --user, --system, --directory, and --file .

All users are can access their per-user journals.
Only root and members of systemd-journal adm and wheel can read all journal files.
Groups are granted access to the system journal and the journals of other users. adm and wheel have additional privileges.

The output is paged through less by default, and long lines are "truncated" to screen width. The truncated part can be viewed by using the left-arrow and right-arrow keys.

When outputting to a tty, lines are colored according to priority: lines of level ERROR and higher are red; lines of level oputputing and higher are highlighted; other lines are displayed normally.

OPTIONS

output specifications
-r
--reverse
Reverse output so newest entries are displayed first.
--no-full
--full
-l
Ellipsize fields when they do not fit. The default is to show full fields, allowing them to wrap or be truncated by the pager
-a
--all
Show all fields in full
-n
--lines=n|all
Output the most recent n events
all disables line limiting.
default : 10
-f
--follow
Do not exit, i.e. display new entries as they are appended .
Implies --lines=10
--no-tail Output all stored output lines, even in follow mode.
Negates --lines.
-e
--pager-end
Start at the end inside the pager, implies -n 1000 so the pager will not buffer logs of unbounded size.
May be overridden with -n ,
-n all disables this cap. only for less
-o
--output=
Controls the formatting of the entries that are shown. Takes one of the following options:
short default generates output similar to classic syslog
cat very terse output, showing the actual message of with no metadata,
short-full timestamps as --since= and --until= options accepted include weekday, year and timezone (locale-independent).
short-iso shows (ISO 8601) T[hh][mm][ss] timestamps.
short-precise shows timestamps with microseconds.
short-monotonic shows monotonic timestamps
short-unix shows seconds since epoch.
verbose shows the full-structured entry items with all fields.
export serializes the journal into a binary (but mostly text-based) stream suitable for backups and network transfer (see Journal Export Format[1]
json formats entries as JSON data structures, one per line (see Journal JSON Format[2]
json-pretty formats entries as JSON more readable by humans.
json-sse formats entries as JSON data structures, wraps in a format suitable for Server-Sent Events[3].
--no-hostname Supress hostname from the local host. only effects --output=short
--utc time UTC
-x
--catalog
Augment log lines with explanation texts explain the context of an error or log event, possible solutions, as well as pointers to support forums, developer documentation, and any other relevant manuals.
help is not available for all messages. Refer to the Message Catalog Developer Documentation[4].
-q
--quiet
Suppresses info messages (i.e. "-- Logs begin at ...", "-- Reboot --"), warnings regarding inaccessible system journals when run as a normal user.
-m
--merge
Output entries interleaved from all available journals, including remote ones.
--list-boots Output a list of boot numbers (relative to the current boot), IDs, and timestamps of the first and last message pertaining to the boot.
journalctl  --list-boots
 0 7672…ca7c Tue 2019-07-23 15:50:01 EDT - Sat 2019-07-27 21:30:01 EDT
Message selection
-b
--boot=[ID][+-offset]
Output messages from a specific boot, adds a match for "_BOOT_ID=".
With no argument logs since the current boot will be shown.
If the boot ID is omitted, a positive offset refers to boots starting from the beginning of the journal.
ID0 offset starts from the end of the journal.
1 refers to the first boot 2 the second; -0 is the last boot, -1 the boot before last, and so on.
An empty offset is equivalent to -0, except when the current boot is not the last boot (e.g. --directory was specified to look at logs from a different machine).

If the 32-character ID is specified, it may be followed by offset which identifies the boot relative to the one given by boot ID. Negative values mean earlier boots and positive values mean later boots.
If offset is not specified, a value of zero is assumed, and the logs for the boot given by ID are shown.

-t
--identifier=syslog_identifier
Output messages for the SYSLOG_IDENTIFIER.
May be specified multiple times.
-u
--unit=unit|pattern
Output messages for the systemd unit UNIT (such as a service unit), or
for units matching pattern. If a pattern is specified, a list of unit names is compared with the specified pattern and all that match are used.
For each unit name, a match is added for messages from the unit ("_SYSTEMD_UNIT=UNIT"), along with additional matches for messages from systemd and messages about coredumps for the specified unit.
May be specified multiple times.
--user-unit=user Output messages for the user session unit. adds a match for messages from the unit ("_SYSTEMD_USER_UNIT=" and "_UID=") and additional matches for messages from session systemd and messages about coredumps for the specified unit.
May be specified multiple times.
-p
--priority=n| emerg | alert | crit | err | warning | notice | debug
Filter output by priorities or ranges.
If a single level is specified, all messages with this level or a lower (more important) level are shown.
If a range is specified, messages with this level within the range, inclusive are shown. Adds PRIORITY="
-c
--cursor=location
show entries from the location
--show-cursor The cursor is shown after the last entry after two dashes: example:
 --cursor: s=0639…
--after-cursor= Show entries from the location after the location specified by the passed cursor.
-S
--since=ccyy-mm-dd [hh:mm:ss]
-U
--until= …
Start examining entries "on or newer then" or "on or older then" ccyy-mm-dd[ hh:mm:ss ]
hh:mm defaults to 00:00 and :ss :00 .
Date defaults to the current day.
yesterday, today, tomorrow are allowed, which refer to 00:00:00 of the day before the current day, the current day, or the day after the current day.
now refers to the current time.
Relative times may be specified, prefixed with "-" or "+", referring to times before or after the current time.

For time and date specification, see systemd.time(7).
--output=short-full displays timestamps that follow this format.

Field selection
-F
--field=f
output all possible data values the field can take in all entries .
-N
--fields
Display all field names used in all entries
PRIORITY
JOURNAL_NAME
JOURNAL_PATH
USER_ID
SYSLOG_FACILITY
CODE_FILE
MESSAGE
UNIT
USER_UNIT
CODE_LINE
RESULT
LEADER
USERSPACE_USEC
_SYSTEMD_SLICE
_SYSTEMD_CGROUP
_SYSTEMD_SESSION
_SYSTEMD_USER_UNIT
_SYSTEMD_INVOCATION_ID
_SYSTEMD_USER_SLICE
_SYSTEMD_UNIT
_SYSTEMD_OWNER_UID
MESSAGE_ID
CODE_FUNCTION
SESSION_ID
SYSLOG_PID
SYSLOG_IDENTIFIER
_EXE
_SOURCE_REALTIME_TIMESTAMP
_CAP_EFFECTIVE
_CMDLINE
_TRANSPORT
_COMM
_HOSTNAME
_GID
_PID
_MACHINE_ID

_UID
_BOOT_ID
_SOURCE_MONOTONIC_TIMESTAMP

LIMIT[_PRETTY]
MAX_USE[_PRETTY]
CURRENT_USE[_PRETTY]
AVAILABLE[_PRETTY]
DISK_AVAILABLE[_PRETTY]
DISK_KEEP_FREE[_PRETTY]
--system Show messages from system services and the kernel
--userShow messages from services of current user (default)
-M
--machine=container
Show messages from a running, local container.
-D dir
--directory=dir
operate on a journal directory DIR instead of the default runtime and system journal paths.
--file=glob operate on the journal files matching GLOB …
May be specified multiple times, in which case files will be interleaved.
--root=root operate on journal directories and catalog file hierarchy below root instead of the ROOT directory (e.g. --update-catalog will create root/var/lib/systemd/catalog/database , and journal files under root/run/journal or root/var/log/journal will be displayed).
--new-id128 Generate a unique 128-bit ID for identifying messages.
journalctl --no-host --new-id128
Archived and active journals take up 8.0M in the file system.
As string: 3b4cd38908d6483caf876751b0301616
As UUID: 3b4cd389-08d6-483c-af87-6751b0301616
As systemd-id128(1) macro: 
    #define XYZ SD_ID128_MAKE(3b,4c,d3,89,08,d6,48,3c,af,87,67,51,b0,30,16,16)

As Python constant:
>>> import uuid
>>> XYZ = uuid.UUID('3b4cd38908d6483caf876751b0301616') 
--header show internal header information of the journal fields accessed.
 > journalctl --header
Archived and active journals take up 8.0M in the file system.
File path: /var/log/journal/a22a2e2f9ece4798893de768a7e8e756/system.journal
File ID: d2ceeb6f71a347bca47e104aac20a2d9
Machine ID: a22a2e2f9ece4798893de768a7e8e756
Boot ID: 66702ad552784e5cbac6e286386f3da6
Sequential number ID: 1e25018865c44ceea4045562951f9ef6
State: ONLINE
Compatible flags:
Incompatible flags: COMPRESSED-ZSTD KEYED-HASH COMPACT
Header size: 264
Arena size: 8388344
Data hash table size: 156529
Field hash table size: 333
Rotate suggested: no
Head sequential number: 33873 (8451)
Tail sequential number: 36892 (901c)
Head realtime timestamp: Wed 2026-09-02 11:02:49 EDT (65a8154224360)
Tail realtime timestamp: Wed 2026-09-02 16:24:17 EDT (65a85d1cdb657)
Tail monotonic timestamp: 6d 22h 30min 1.972s (8b8f244319)
Objects: 7260
Entry objects: 3020
Data objects: 3521
Data hash table fill: 2.2%
Field objects: 58
Field hash table fill: 17.4%
Tag objects: 0
Entry array objects: 659
Deepest field hash chain: 1
Deepest data hash chain: 1
Disk usage: 8.0M
--disk-usage Shows disk usage of all journal files including archived and active journal files.
Archived and active journals take up 21.6M 
--list-catalog [ID …] List the contents of the message catalog as a table of message IDs, plus their short description strings.
If any 128-bit-IDs are specified, only those entries are shown.
> journalctl --list-catalog 
Archived and active journals take up 247.1M in the file system.
xx2e systemd: One or more messages could not be forwarded to syslog
xx73 systemd: Unit skipped
xx5d systemd: DNSSEC validation failed
xx93 systemd: Failed to generate valid unit name from path '@MOUNT_POINT@'.
xx33 systemd: systemd-udev-settle.service is deprecated.
xxe7 systemd: Mount point is not empty
xxf2 systemd: A virtual machine or container has been started 
--dump-catalog [ID…] the message catalog entries with IDs. Default all entries. Large example
 > journalctl --dump-catalog 

Archived and active journals take up 247.1M in the file system.
-- xx2e
Subject: One or more messages could not be forwarded to syslog
Defined-By: systemd
Support: https://www.debian.org/support

One or more messages could not be forwarded to the syslog service
running side-by-side with journald. This usually indicates that the
syslog implementation has not been able to keep up with the speed of
messages queued.

-- xx73
Subject: Unit skipped
Defined-By: systemd
Support: https://www.debian.org/support

The unit @UNIT@ was skipped due to an ExecCondition= command failure, and has
entered the 'dead' state with result '@UNIT_RESULT@'.

-- xx5d
Subject: DNSSEC validation failed
Defined-By: systemd
Support: https://www.debian.org/support
Documentation: man:systemd-resolved.service(8)

A DNS query or resource record set failed DNSSEC validation. This is usually
indication that the communication channel used was tampered with.
-k
--dmesg
Show only kernel messages. implies --boot and adds match "_TRANSPORT=kernel". Sample
--verify Check for internal consistency.
If FSS enabled and the FSS verification key has been specified with --verify-key=, authenticity of the journal file is verified.
> journalctl --verify    
>  journalctl --verify     
Archived and active journals take up 8.0M in the file system.
PASS: /var/log/journal/a22a2e2f9ece4798893de768a7e8e756/system.journal

+++

Archived and active journals take up 8.0M in the file system.
File corruption detected at /var/log/journal/a… /system.journal:2ab070 (of 8388608 bytes, 33%).
FAIL: /var/log/journal/a…/system.journal (Input/output error)  out of space
--vacuum-size=size
--vacuum-time=timespan
--vacuum-files=number
Remove archived files until:
  • the disk space used is below size K, M, G and T
  • no data older than the timespan s, m, h, days, months, weeks and years
  • no more than the number of files remain.
has an indirect effect on the output shown by --disk-usage which includes active files.
--vacuum-size, --vacuum-time and --vacuum-files may be combined
Does not remove active files.
> sudo journalctl --vacuum-size=160K |\
sed "s/[[:xdigit:]]\{30\}/x/; /s/[[:xdigit:]]\{16\}/x/;"
Vacuuming done, freed 0B of archived journals from /var/log/journal.
Vacuuming done, freed 0B of archived journals from /run/log/journal.
Deleted empty archived journal /run/log/journal/a22…756/system@xxbd-xx-xx.journal (8.0M).
Deleted archived journal /run/log/journal/a22…756/system@xxbd-xx-xx.journal (6.3M).

…
Deleted archived journal /run/log/journal/a22…756/system@xxbd-xx-xx.journal (560.0K).
Vacuuming done, freed 79.1M of archived journals from /run/log/journal/a22…756.
Deleted archived journal /var/log/journal/a22…756/system@xx5f-xx-xx.journal (7.9M).
Deleted archived journal /var/log/journal/a22…756/system@xx5f-xx-xx.journal (7.9M).

Deleted archived journal /var/log/journal/a22…756/system@xxf6-xx-xx.journal (7.9M).
Vacuuming done, freed 159.9M of archived journals from /var/log/journal/a22…756
--sync write all data to files and synchronize all journals.
Does not return until complete.
--update-catalog Update the message catalog index.
Needs to be executed each time new catalog files are installed, removed or updated to rebuild the binary catalog index.
--setup-keys Generate a new key pair for Forward Secure Sealing (FSS).
This will generate a sealing key and a verification key.
The sealing key is stored in the journal data directory and remains on the host.
The verification key should be stored externally.
Refer to Seal in journald.conf
--verify-key=kkk the FSS verification key to use for --verify.
--interval=minutes the change interval for the sealing key when generating an FSS key pair with --setup-keys.
Shorter intervals increase CPU consumption but shorten the time range of undetectable journal alterations.
Default 15min.
--force When --setup-keys is passed and Forward Secure Sealing (FSS) has been configured, recreate FSS keys.
--flush data in /run/log/journal is written to /var/log/journal if persistent storage is enabled.
Does not return until complete.
the data is flushed once during system runtime this command exits cleanly without executing any operation if this has already happened. Does not return until the rotation is complete.
--no-pager Do not pipe output to a pager.
-h
--help
output a short help text and exit.
--version output a short version string and exit.

Details

Symbolic links are dereferenced, kernel names are synthesized, and parent devices are identified from the environment at the time of the query. In general, a device node is the best proxy for an actual device, as log entries do not usually contain fields that identify an actual device. For the resulting log entries to be correct for the actual device, the relevant parts of the environment at the time the entry was logged, in particular the actual device corresponding to the device node, must have been the same as those at the time of the query. Because device nodes generally change their corresponding devices across reboots, specifying a device node path causes the resulting entries to be restricted to those from the current boot.

ENVIRONMENT

$SYSTEMD_PAGER Pager to use when --no-pager is not given; overrides $PAGER. If neither $SYSTEMD_PAGER nor $PAGER are set, a set of well-known pager implementations are tried in turn, including less(1) and more(1), until one is found. If no pager implementation is discovered no pager is invoked. Setting this environment variable to an empty string or the value "cat" is equivalent to passing --no-pager.
$SYSTEMD_LESS Override the options passed to less (by default "FRSXMK").
$SYSTEMD_LESSCHARSET Override the charset passed to less (by default "utf-8", if the invoking terminal is determined to be UTF-8 compatible).

EXAMPLES

Without arguments, all collected logs are shown unfiltered: journalctl With one match specified, all entries with a field matching the expression are shown: journalctl _SYSTEMD_UNIT=avahi-daemon.service If two different fields are matched, only entries matching both expressions at the same time are shown: journalctl _SYSTEMD_UNIT=avahi-daemon.service _PID=28097 If two matches refer to the same field, all entries matching either expression are shown: journalctl _SYSTEMD_UNIT=avahi-daemon.service _SYSTEMD_UNIT=dbus.service If the separator "+" is used, two expressions may be combined in a logical OR. The following will show all messages from the Avahi service process with the PID 28097 plus all messages from the D-Bus service (from any of its processes): journalctl _SYSTEMD_UNIT=avahi-daemon.service _PID=28097 + _SYSTEMD_UNIT=dbus.service Show all logs generated by the D-Bus executable: journalctl /usr/bin/dbus-daemon Show all kernel logs from previous boot: journalctl -k -b -1 Show a live log display from a system service apache.service: journalctl -f -u apache SEE ALSO systemd(1), systemd-journald.service(8), systemctl(1), coredumpctl(1), systemd.journal-fields(7), journald.conf(5), systemd.time(7)
systemctl  status systemd-journald
* systemd-journald.service - Journal Service
   Loaded: loaded (/lib/systemd/system/systemd-journald.service; static; vendor preset: enabled)
   Active: active (running) since Fri 2019-07-26 06:55:53 EDT; 1 day 13h ago
     Docs: man:systemd-journald.service(8)
           man:journald.conf(5)
 Main PID: 12704 (systemd-journal)
   Status: "Processing requests..."
   CGroup: /system.slice/systemd-journald.service
           `-12704 /lib/systemd/systemd-journald

Jul 26 06:55:48 pi93graf systemd-journald[12704]: Journal started
Jul 26 06:55:51 pi93graf systemd-journald[12704]: Runtime journal (/run/log/journal/xx6e) is 21.6M, max 21.6M, 0B f
Jul 26 06:54:47 pi93graf systemd[1]: systemd-journald.service: Watchdog timeout (limit 3min)!
Jul 26 06:54:48 pi93graf systemd[1]: systemd-journald.service: Killing process 94 (systemd-journal) with signal SIGABRT.

Config file

/etc/systemd/journald.conf

#  @ file small5 /etc/systemd/journald.conf     mmcblk0p2   7,042,704  7GB;   mmcblk0p1    522,230  
#  @ apply:    sudo systemctl restart systemd-journald
#  @ brief /var/journald fills up 
#  This file is part of systemd.
#
# the compile time defaults.
# Defaults can be restored by simply deleting this file.
#
# See journald.conf(5) 

[Journal]
SystemMaxUse=200M
SystemKeepFree=1G

#Storage=auto
#Compress=yes
#Seal=yes
#SplitMode=uid
#SyncIntervalSec=5m
#RateLimitIntervalSec=30s
#RateLimitBurst=10000
#SystemMaxFileSize=
#SystemMaxFiles=100
#RuntimeMaxUse=
#RuntimeKeepFree=
#RuntimeMaxFileSize=
#RuntimeMaxFiles=100
#MaxRetentionSec=
#MaxFileSec=1month
#ForwardToSyslog=yes
#ForwardToKMsg=no
#ForwardToConsole=no
#ForwardToWall=yes
#TTYPath=/dev/console
#MaxLevelStore=debug
#MaxLevelSyslog=debug
#MaxLevelKMsg=notice
#MaxLevelConsole=info
#MaxLevelWall=emerg
#LineMax=48K
#ReadKMsg=yes
#Audit=no
http://www.freedesktop.org/wiki/Software/systemd