LX0-104 · Question #48
Which of the following parameters are used for journalctl to limit the time frame of the output? (Choose TWO correct answers.)
The correct answer is B. --since= C. --until=. The journalctl command uses the --since= and --until= parameters to filter log entries and limit the output to a specific time frame. These options allow users to view logs from a starting point up to an end point.
Question
Options
- A--from=
- B--since=
- C--until=
- D--upto=
- E--date=
How the community answered
(39 responses)- A3% (1)
- B90% (35)
- D3% (1)
- E5% (2)
Why each option
The `journalctl` command uses the `--since=` and `--until=` parameters to filter log entries and limit the output to a specific time frame. These options allow users to view logs from a starting point up to an end point.
`--from=` is not a standard `journalctl` parameter for specifying a start time. The correct parameter is `--since=`.
The `--since=` parameter in `journalctl` is used to display log entries that are newer than or equal to the specified date and time. This defines the start of the time frame.
The `--until=` parameter in `journalctl` is used to display log entries that are older than or equal to the specified date and time. This defines the end of the time frame.
`--upto=` is not a standard `journalctl` parameter for specifying an end time. The correct parameter is `--until=`.
`--date=` is not a standard `journalctl` parameter for limiting the time frame. It might be confused with date formatting in some other commands, but not for time frame filtering in `journalctl`.
Concept tested: journalctl time filtering
Source: https://www.freedesktop.org/software/systemd/man/journalctl.html
Topics
Community Discussion
No community discussion yet for this question.