From the course: LPIC-1 Exam 101 (Version 5.0) Cert Prep

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Run jobs in the foreground and background

Run jobs in the foreground and background - Linux Tutorial

From the course: LPIC-1 Exam 101 (Version 5.0) Cert Prep

Start my 1-month free trial

Run jobs in the foreground and background

- [Instructor] When we start programs from the shell, they usually stay as interactive tasks in the foreground. This way we see the output on the screen and we can terminate them quickly by pressing control C. However there are times when putting a current task in the background would be advantageous. Whenever we want to check up on the task we could bring it to the foreground again. We can do this with a couple of commands. To set this up let's open two terminals. Go to applications, favorites, terminal, and drag this terminal to the right border. Bump the font size, and then open another terminal, applications, favorites, terminal. Drag this terminal to the left border and bump it's font size as well. We will use the PS command to keep an eye on any DD commands running. Normally we'd run top for real time tasks, but we're going to combine PS with a watch command. Watch executes a command every two seconds until…

Contents