next up previous contents index
Next: condor_ stats Up: 9. Command Reference Manual Previous: condor_ rm   Contents   Index

Subsections


condor_ run

Submit a shell command-line as a Condor job.

Synopsis

condor_ run [-u universe] ``shell-cmd''

Description

condor_ run is a simple front-end to the condor_ submit command for submitting a shell command-line as a vanilla universe Condor job. The condor_ run command waits for the Condor job to complete, writes the job's output to the terminal, and exits with the exit status of the Condor job. No output will appear until the job completes. The shell command-line should be enclosed in quotes so it is passed directly to condor_ run without modification by the invoking shell.

condor_ run will not read any input from the terminal while the job executes. If the shell command-line requires input, you must explicitly redirect the input from a file to the command, as illustrated in the example.

You can specify where condor_ run should execute the shell command-line with three environment variables:

CONDOR_ARCH
Specifies the architecture of the execution machine (from the ``Arch'' field in the output of condor_ status).
CONDOR_OPSYS
Specifies the operating system of the execution machine (from the ``OpSys'' field in the output of condor_ status).
CONDOR_REQUIREMENTS
Specifies any additional requirements for the Condor job (as described in manual page for condor_ submit on page [*]). It is recommended that CONDOR_REQUIREMENTS always be enclosed in parenthesis.

If one or more of these environment variables is specified, the job is submitted with:

  requirements = $CONDOR_REQUIREMENTS && Arch == $CONDOR_ARCH && \
                 OpSys == $CONDOR_OPSYS

Otherwise, the job receives the default requirements expression, which requests a machine of the same architecture and operating system of the machine on which condor_ run is executed.

All environment variables set when condor_ run is executed will be included in the environment of the Condor job.

condor_ run will remove the Condor job from the Condor queue and delete its temporary files if it is killed before the Condor job finishes.

Examples

condor_ run can be used to compile jobs on architectures and operating systems to which the user doesn't have login access. For example:

$ setenv CONDOR_ARCH "SUN4u"
$ setenv CONDOR_OPSYS "SOLARIS28"
$ condor_run "f77 -O -o myprog myprog.f"
$ condor_run "make"
$ condor_run "condor_compile cc -o myprog.condor myprog.c"

Since condor_ run does not read input from the terminal, you must explicitly redirect input from a file to the shell command. For example:

$ condor_run "myprog < input.dat > output.dat"

Files

condor_ run creates the following temporary files in the user's working directory (replacing ``pid'' with condor_ run's process id):

.condor_run.pid
This is the shell script containing the shell command-line which is submitted to Condor.
.condor_submit.pid
This is the submit file passed to condor_ submit.
.condor_log.pid
This is the Condor log file monitored by condor_ run to determine when the job exits.
.condor_out.pid
This file contains the output of the Condor job (before it is copied to the terminal).
.condor_error.pid
This file contains any error messages for the Condor job (before they are copied to the terminal).
The script removes these files when the job completes. However, if the script fails, it is possible that these files will remain in the user's working directory and the Condor job will remain in the queue.

General Remarks

condor_ run is intended for submitting simple shell command-lines to Condor. It does not provide the full functionality of condor_ submit. We have attempted to make condor_ run as robust as possible, but it is possible that it will not correctly handle some possible condor_ submit errors or system failures.

condor_ run jobs have the same restrictions as other vanilla universe jobs. Specifically, the current working directory of the job must be accessible on the machine where the job runs. This typically means that the job must be submitted from a network file system such as NFS or AFS. Also, since Condor does not manage AFS credentials, permissions must be set to allow unauthenticated processes to access any AFS directories used by the Condor job.

All processes on the command-line will be executed on the machine where Condor runs the job. Condor will not distribute multiple processes of a command-line pipe across multiple machines.

condor_ run will use the shell specified in the SHELL environment variable, if one exists. Otherwise, it will use /bin/sh(t)o execute the shell command-line.

By default, condor_ run expects perl to be installed in /usr/bin/perl. If perl is installed in another path, you can ask your Condor administrator to edit the path in the condor_ run script or explicitly call perl from the command line:

$ perl [path-to-condor]/bin/condor_run "shell-cmd"

Options

-u universe
Submit the job in the specified universe. The default is `vanilla'. `scheduler' and `local' also work.

Exit Status

condor_ run exits with a status value of 0 (zero) upon complete success. The exit status of condor_ run will be non-zero upon failure. The exit status in the case of a single error due to a system call will be the error number (errno) of the failed call.

Author

Condor Team, University of Wisconsin-Madison

Copyright

Copyright © 1990-2006 Condor Team, Computer Sciences Department, University of Wisconsin-Madison, Madison, WI. All Rights Reserved. No use of the Condor Software Program is authorized without the express consent of the Condor Team. For more information contact: Condor Team, Attention: Professor Miron Livny, 7367 Computer Sciences, 1210 W. Dayton St., Madison, WI 53706-1685, (608) 262-0856 or miron@cs.wisc.edu.

U.S. Government Rights Restrictions: Use, duplication, or disclosure by the U.S. Government is subject to restrictions as set forth in subparagraph (c)(1)(ii) of The Rights in Technical Data and Computer Software clause at DFARS 252.227-7013 or subparagraphs (c)(1) and (2) of Commercial Computer Software-Restricted Rights at 48 CFR 52.227-19, as applicable, Condor Team, Attention: Professor Miron Livny, 7367 Computer Sciences, 1210 W. Dayton St., Madison, WI 53706-1685, (608) 262-0856 or miron@cs.wisc.edu.

See the Condor Version 6.8.3 Manual for additional notices.


next up previous contents index
Next: condor_ stats Up: 9. Command Reference Manual Previous: condor_ rm   Contents   Index
condor-admin@cs.wisc.edu