Linux for Developers Course
Linux for Developers
/
Intermediate

jobs

Definition

A command that lists the active jobs (background processes) that have been started by, and are attached to, your current terminal session.

Explain Like I'm New

Checking what tasks are running invisibly behind the scenes in your current window.

Real World Example

You start a massive database backup. It takes 30 minutes. You pause it with `Ctrl+Z`, then type `bg` to send it to the background so you can keep typing. You type `jobs` to see a numbered list verifying the backup is still running invisibly.

Common Use Cases

  • •Managing long-running terminal tasks
  • •Multitasking in a single window

Interview Questions

basic

  • Will the `jobs` command show a background process started by another user on the server?

intermediate

  • How do you bring a background job (like job number 2) back to the foreground so you can interact with it?

Flash Cards

Question

Show other users' jobs?

Click to reveal answer
Answer

No. `jobs` ONLY shows processes tied specifically to your exact current terminal window.

Question

Bring to foreground?

Click to reveal answer
Answer

Use the `fg` (foreground) command followed by the job number: `fg %2`.