I just tried something similar under v2.3 pre3 (whose salloc is almost identical
with that of 2.2.3) and it worked. 

Looking at your output it seems that the allocation (#38) is revoked immediately
after it was granted, which could happen if the script '1grabslurm' exits very 
soon.

I can not see a problem with the script below, but there may well be something 
that
needs to be checked in the '1grabslurm' script -- please send more information, 
you
can also send this privately.

Alternatively, since it seems that salloc is used to generate an allocation, you
could consider the --no-shell mode.

On Fri, 4 Mar 2011 18:12:23 -0800 [email protected] wrote:
> I have a few shell scripts that are basically things like:
> #!/bin/bash
> salloc -N1 -n1 -p pubint 1grabslurm 1
> 
> At least under our ancient 1.3.x installation, salloc worked from a
> script in exactly the same way as from the command line.
> 
> Under 2.2.3, the salloc line works fine when typed directly, but when
> invoked from a script I instead see:
> 
> salloc: Granted job allocation 38
> salloc: Relinquishing job allocation 38
> salloc: Job allocation 38 has been revoked.
> /root # srun: forcing job termination
> srun: got SIGCONT
> srun: error: Task launch for 38.0 failed on node hyraxD01: Job
> credential revoked
> srun: error: Application launch failed: Job credential revoked
> srun: Job step aborted: Waiting up to 2 seconds for job step to finish.
> srun: error: Timed out waiting for job step to complete
> tcsetattr: Input/output error
> 
> Thanks in advance for any advice,
> Jeff Katcher

Reply via email to