nerdexam
CompTIA

LX0-104 · Question #559

Each entry in a crontab must end with which of the following characters?

The correct answer is D. newline. Each entry in a crontab file must conclude with a newline character for proper parsing and execution by the cron daemon.

Administrative Tasks

Question

Each entry in a crontab must end with which of the following characters?

Options

  • Atab
  • Bspace
  • Cbackslash
  • Dnewline

How the community answered

(20 responses)
  • A
    5% (1)
  • B
    5% (1)
  • D
    90% (18)

Why each option

Each entry in a `crontab` file must conclude with a newline character for proper parsing and execution by the cron daemon.

Atab

A tab character is used to separate fields within a crontab entry (e.g., minute, hour, day), but not to terminate the entire entry.

Bspace

A space character is used as a field separator, similar to a tab, but does not serve as an entry terminator.

Cbackslash

A backslash is typically used for line continuation or escaping special characters in shell commands, not for terminating crontab entries.

DnewlineCorrect

In `crontab` files, each command line defining a scheduled job must be terminated by a newline character. This ensures that the cron daemon correctly identifies and processes each distinct entry, as it uses the newline as a delimiter to separate individual cron jobs.

Concept tested: Crontab entry termination

Source: https://manpages.org/man/5/crontab

Topics

#crontab#scheduled tasks#cron syntax

Community Discussion

No community discussion yet for this question.

Full LX0-104 Practice