[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Condor-users] Behaviour of Windows "copy" command?

On Mon, 27 Jun 2005, Rob Fletcher wrote:

echo Testing 0 > %CONDOR_SCRATCH_DIR%test0.txt

(And from a private post from Rob to me in which I asked for the environment variables set in the job's environment on the execute host):

Well, one thing that is wrong is that you are using the environment variable "CONDOR_SCRATCH_DIR" instead of "_CONDOR_SCRATCH_DIR". In the 6.6. series (which you are using), for the Vanilla universe, Condor sets the _CONDOR_SCRATCH_DIR environment variable instead of the CONDOR_SCRATCH_DIR variable - I don't know about the 6.7 series. For reasons known only to themselves, the Condor Team have neither corrected this obvious bug, nor documented it, although it has been pointed out on this mailing list before.

So Windows will replace %CONDOR_SCRATCH_DIR% with the null string. You should use %_CONDOR_SCRATCH_DIR% if you actually want the path of the job's execute directory under Windows. In addition, note that that environment variable does NOT have a trailing slash, so you should be using "%_CONDOR_SCRATCH_DIR%\", e.g.

	 echo Testing 0 > %_CONDOR_SCRATCH_DIR%\test0.txt

As you've also discovered, you have permission problems as well, but the above also needs to be corrected if you want to do this sort of thing in general.

	-- Bruce

Bruce Beckles,
e-Science Specialist,
University of Cambridge Computing Service.