Redirect Standard Input in UNIX Background Process
Redirect Standard Input in UNIX Background Process
If the command ucmd is executed as a background job (using the & operator), it will receive the SIGTTIN signal when ucmd tries to read from standard input. Background jobs cannot read their standard input from the terminal since the foreground job (or the shell) has it allocated. The ucmd job is stopped until it is brought to the foreground.
To run an ucmd job that does not require terminal input in the background, redirect its standard input from /dev/null.
ucmd -script myscript -host dallas -userid joe -pwd password < /dev/null &
The command is sent to a remote system named dallas for execution. The output of myscript is redirected back to the Universal Command process. Standard input is read from /dev/null. The process will authenticate and run under the authority of userid joe.
Command Line Options
The command line options used in this example are:
Components
Universal Command Manager for Windows