O'Reilly logo

Korn Shell: Unix and Linux Programming Manual, Third Edition, The by Anatole Olczak

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Job Control

Job control is a process manipulation feature found in the Korn shell. It allows programs to be stopped and restarted, moved between the foreground and background, their processing status to be displayed, and more. To enable job control, the monitor option must be enabled. By default, this is enabled on systems that support the job control feature. When a program is run in the background, a job number and process id are returned.

Job Control Commands

bg put current stopped job in the background
bg %n put stopped job n in the background
fg move current background job into the foreground
fg %n move background job n into the foreground
jobs display status of all jobs
jobs –l display status of all jobs along with process ids
jobs –p ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required