home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  


UNIX Power Tools

UNIX Power ToolsSearch this book
Previous: 12.7 Stop Background Output with stty tostop Chapter 12
Job Control
Next: 12.9 Running Multiple Shell Sessions with screen
 

12.8 Job Control in a Nutshell

Unless otherwise noted, these commands apply only to the C shell, Korn shell, and bash :

  • command  & ( 1.26 , 12.1 ) : Run command in the background. You can continue to execute jobs in the foreground. All shells.

  • CTRL-c ( 38.9 ) : Kill the current foreground job by sending the INTR signal ( 38.8 ) . All shells.

  • CTRL-z ( 12.1 , 12.4 ) : Suspend the current foreground job by sending the TSTP signal ( 38.8 ) .

  • Suspend a shell with the suspend command ( 22.22 ) .

  • Suspend a background job with the stop command or an alias that does the same thing ( 12.5 ) .

  • bg % num ( 12.1 ) : Let a stopped job (by job number num ) continue in the background.

  • fg % num ( 12.1 ) : Put a background job or a stopped job (by job number num ) into the foreground.

  • kill % num ( 12.1 ) : Kill an arbitrary background job (by job number num ).

  • kill  pid ( 38.10 ) : Kill an arbitrary job (by process ID number num ). All shells.

  • jobs ( 12.1 ) : List background and stopped jobs and their job numbers.

  • set notify ( 12.6 ) : Immediate job-state change notices.

  • stty tostop ( 12.7 ) : Automatically stop background processes if they try writing to the screen.

- ML


Previous: 12.7 Stop Background Output with stty tostop UNIX Power Tools Next: 12.9 Running Multiple Shell Sessions with screen
12.7 Stop Background Output with stty tostop Book Index 12.9 Running Multiple Shell Sessions with screen

The UNIX CD Bookshelf Navigation The UNIX CD BookshelfUNIX Power ToolsUNIX in a NutshellLearning the vi Editorsed & awkLearning the Korn ShellLearning the UNIX Operating System