LFCS · 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 within a specific time frame. These parameters allow users to retrieve logs starting from a particular point in time and ending at another, respectively.
Question
Options
- A--from=
- B--since=
- C--until=
- D--upto=
- E--date=
How the community answered
(22 responses)- A5% (1)
- B86% (19)
- D9% (2)
Why each option
The `journalctl` command uses the `--since=` and `--until=` parameters to filter log entries within a specific time frame. These parameters allow users to retrieve logs starting from a particular point in time and ending at another, respectively.
`--from=` is not a standard `journalctl` parameter for specifying a start time; `--since=` is used instead.
The `--since=` parameter in `journalctl` is used to display log entries from a specified date and time onwards (e.g., `--since="2023-01-01 10:00:00"` or `--since="yesterday"`).
The `--until=` parameter in `journalctl` is used to display log entries up to a specified date and time (e.g., `--until="2023-01-02 12:00:00"` or `--until="now"`).
`--upto=` is not a standard `journalctl` parameter for specifying an end time; `--until=` is used instead.
`--date=` is not a standard `journalctl` parameter for limiting the time frame of output.
Concept tested: `journalctl` time filtering parameters
Source: https://man7.org/linux/man-pages/man1/journalctl.1.html
Topics
Community Discussion
No community discussion yet for this question.