nerdexam
CompTIA

LX0-103 · Question #196

Which of the following commands moves and resumes in the background the last stopped shell job?

The correct answer is B. bg. The bg command resumes the most recently stopped shell job by running it in the background, allowing the shell prompt to return immediately.

GNU and Unix Commands

Question

Which of the following commands moves and resumes in the background the last stopped shell job?

Options

  • Arun
  • Bbg
  • Cfg
  • Dback

How the community answered

(51 responses)
  • A
    4% (2)
  • B
    86% (44)
  • C
    2% (1)
  • D
    8% (4)

Why each option

The bg command resumes the most recently stopped shell job by running it in the background, allowing the shell prompt to return immediately.

Arun

run is not a valid shell built-in or standard Unix command for job control.

BbgCorrect

The bg built-in command takes the most recently stopped job (or a specified job number) and resumes its execution in the background, equivalent to having originally started it with '&'. It sends the job a SIGCONT signal and the shell continues accepting input while the job runs asynchronously.

Cfg

fg brings a background or stopped job to the foreground - the opposite of what is asked - making it the current active job in the terminal.

Dback

back is not a valid shell built-in or standard Unix command for job control.

Concept tested: Shell job control bg command background resumption

Source: https://www.gnu.org/software/bash/manual/html_node/Job-Control-Builtins.html

Topics

#job control#bg command#background processes

Community Discussion

No community discussion yet for this question.

Full LX0-103 Practice