I am having trouble with configuring parallel kernels. What I want to do is the following: run remote kernels on my home server to which I would like to connect from work using my laptop. Both machines are running Linux and Mathematica 10. I have a VPN set up and working so my laptop and home server can connect to each other without problems. I am following this guide under the section "Remote Kernels". I have enabled remote kernels in parallel kernel configuration (on laptop). When I try to launch the remote kernels, I get the error message

In[]:= LaunchKernels[RemoteMachine[""], "ssh -x -f math -mathlink -linkmode Connect `4` -linkname `2` -subkernel -noinit"]]
Command ssh -x -f math -mathlink -linkmode Connect -linkprotocol TCPIP -linkname [email protected],[email protected] -subkernel -noinit may have failed (exit code 32512).

where is the IP address of the server. I have ssh keys set up so that I can log in to the server simply by "ssh". If I issue the (failing) ssh command in the terminal, I don't get any error messages.

Any ideas about what I am doing wrong?

  • 1
    $\begingroup$ Just some thoughts: can you do "ssh math"? If you ssh to the machine can you do "math"? First step might be to figure out if the problem is with Mathematica on the remote side or the ssh connection itself. $\endgroup$
    – user1722
    Oct 14, 2014 at 16:46
  • $\begingroup$ As far as I can tell, ssh works fine. When I do "ssh math" everything works as expected, that is, it logs into with ssh keys and launches "math". Even when I copy the $RemoteCommand (that fails with error code 32512) from Mathematica into a terminal and execute it, I get no error messages. It seems as if the error occurs only when ssh is invoked by Mathematica. $\endgroup$
    – iexoa
    Oct 16, 2014 at 12:20
  • 2
    $\begingroup$ Two thoughts: mess around with -T and -t to see if it's a terminal issue. Also, when you login to the remote system, do you get any sort of "message of the day" or other text? This can sometimes confuse programs that expect a "pure" connection. Also try adding "1> /tmp/out.txt 2> /tmp/err.txt" to the command inside Mathematica to see what errors ssh is spewing out, if any. $\endgroup$
    – user1722
    Oct 16, 2014 at 15:56

1 Answer 1


Using barrycarter's advice I found that ssh was throwing the error message:

ssh: symbol lookup error: ssh: undefined symbol: EVP_aes_128_ctr

According to this excellent answer the problem is caused by Mathematica 10 having libraries incompatible with ssh. This problem could be averted by prepending


to the launch command in parallel kernel options. After this modification I got my parallel kernels working.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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