msandbot
msandbot

Reputation: 221

call matlab in an ssh command from a perl script

Hi i have set up passwordless ssh set up and have perl call ssh -o "BatchMode yes" user@host "runMe.pl arg1 arg2"

runMe.pl calls matlab and the function run_online with the given args.

nohup matlab -nojvm -nodisplay -r "run_online('$imgfolder/$folder/', '$ARGV[0]$folder', '/homes/rbise/results/mitosis/$ARGV[0]/$folder/')" > out.txt < /dev/null &

for some reason matlab never starts running. why is this?

thanks

Upvotes: 0

Views: 410

Answers (1)

Ether
Ether

Reputation: 53966

This is substantially a duplicate of the [perl] question that was asked immediately previously to this one -- at least, the answer is the same. You have no controlling terminal when you connect with ssh. Try ssh -o "BatchMode yes" user@host "bash -c runMe.pl arg1 arg2".

Upvotes: 2

Related Questions