I am running an executable in my slurm script on my cluster that requires ssh'ing to multiple nodes, however when I run the script, I get an error call "Couldn't find remote shell program: ssh". ssh is in my /usr/bin path and works well locally, how can I make it work in my sjob script in parallel.

Usually I would just create an environment module for the program and load the program within in my job script, but making a module for ssh does not make too much sense.

  • your slurm job needs to ssh to multiple nodes in the cluster? that's a very odd way of using a cluster - user scripts ssh-ing to other nodes and running processes/consuming resources defeats the point of a scheduling & resource manager like slurm and makes it impossible for it to do its job properly (it needs to know what resources are in use and which are still available for use). Are you sure you actually need to do that, or can you use a shared filesystem to transfer files, or MPI or similar for your computation task to communicate with other instances? – cas Feb 12 '18 at 2:33
  • by "resources", I mean node-specific things like CPU cores, RAM, GPUs, etc. I suggest you talk to your cluster admins and ask for advice on how to do whatever it is you're trying to do. Talk to them about your actual goal, not necessarily your proposed approach to solving it (see xyproblem.info for why that matters) – cas Feb 12 '18 at 2:39

It sounds like slurm doesn't have the same path. Either set the slurm path to include /usr/bin or call ssh as /usr/bin/ssh.

| improve this answer | |
  • hello, what file do I set my path? – airzinger1 Feb 11 '18 at 20:19
  • Put these in your script: echo "PATH=$PATH" which ssh ls -la /bin/ssh /usr/bin/ssh – Pedro Feb 25 '18 at 6:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.