You meant to edit your personal crontab but typed `crontab -r`. What happened?

LPIC-1 Exam 102-500, objective 107. Administrative tasks easy

Draft — not checked yet. This question was written from the published exam objectives and cites the clause it comes from, but nobody has yet read it against that clause and signed for it.

It is kept out of search results and out of mock exams until they have. Read the source below before you take the answer as settled.

The options

Not correct The crontab was reloaded from disk and nothing changed

Wrong. There is no reload option; cron notices changes to a crontab by itself. -r is not a reload.

Not correct The crontab was printed to standard output

Wrong. That is -l (list), which writes the current crontab to standard output without modifying it.

Correct Your entire crontab was deleted, without a confirmation prompt

Correct. -r removes the invoking user's crontab file outright. Standard cron asks nothing, which is why -r sits next to -e on the keyboard as a well-known hazard. Some implementations offer -i to prompt first.

Not correct The crontab was restored from the most recent backup copy

Wrong. cron keeps no backups or version history of crontabs at all. Recovering a deleted crontab means retyping it or restoring the spool file from a system backup.

Why

crontab's main options are -e to edit in $EDITOR or $VISUAL, -l to list, -r to remove, and -u USER to act on another user's crontab (root only). A common defensive habit is `crontab -l > ~/crontab.bak` before editing.

Where this comes from

Cited
LPI exam objective 107.2
What it says
Use the crontab command to create, list and remove cron jobs.

Practise this

Reading one question is not practice. The trainer will draw a set from objective 107 and space the ones you get wrong.

Practise LPIC-1 Exam 102-500