Frage

I'm attempting to setup a new compute cluster, and currently experiencing errors when using the qsub command in the SGE. Here's a simple experiment that shows the problem:

test.sh

#!/usr/bin/zsh

test="hello"
echo "${test}"

test.sh.eXX

test=hello: Command not found.

test: Undefined variable.

test.sh.oXX

Warning: no access to tty (Bad file descriptor).

Thus no job control in this shell.

If I ran the script on the head node (sh test.sh), the output is correct. I submit the job to the SGE by typing "qsub test.sh".

If I submit the exact same script job in the same way on an established compute cluster like HPC, it works perfectly as expected. What setting could be causing this problem?

Thanks for any help on this matter.

War es hilfreich?

Lösung

Most likely the queues on your cluster are set to posix_compliant mode with a default shell of /bin/csh. The posix_compliant setting means your #! line is ignored. You can either change the queues to unix_behavior or specify the required shell using qsub's -S option.

#$ -S /bin/sh
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top