z/OS UNIX System Services User's Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Exiting the shell with background jobs running

z/OS UNIX System Services User's Guide
SA23-2279-00

When you exit the shell, any stopped background jobs are terminated. But if you have a background job in the running state, you can exit the shell without terminating it.

In the z/OS® shell, the default setting set -m runs background jobs in a separate process group. Jobs in a separate process group are not sent a SIGHUP signal when you exit the shell. With the default -m setting, background jobs continue to run after you exit the shell.

In the tcsh shell, use NOHUP to exit the shell with background jobs running.

For the OMVS interface:

To exit with a background job running, use the quit subcommand. (Type quit and press the Subcommand function key or switch to subcommand mode and enter the quit command.) A background job that is running will continue running.

If you are using the OMVS interface and you use the exit command to exit the shell while you have a shell background job running, OMVS may send this message:
The shell process ended, but the session did not end automatically.
You may need to run the QUIT subcommand to end the session.

For the Asynchronous terminal interface:

To exit when a background job is running, type <Ctrl-D> or use the exit command. A background job that is running will continue running. You do not get any indication that a background job is running.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014