Skip to content

Configuring Secure Shell on a Desktop for Use with MATLAB Parallel Computing Toolbox

MATLAB has unique setup requirements for users with a Parallel Computing Toolbox on their Windows desktop, compared with other desktop platforms. A secure shell is required to access the Gordon matlab server, and this must be installed if not already available. For Linux and Mac OS X, the default system shell will suffice.

When using the Gordon-based toolbox and client, this desktop configuration is not required.

Configuring MATLAB for Use with a Desktop Client

To access the Distributed Computing server on Gordon from a desktop system (in other words, to use the Parallel Computing Toolbox with a client not installed on Gordon), you must have a secure shell installed on the desktop. The setup process is different for Windows and Linux/Mac <#unix>.

Windows Procedure

  1. Download and install PuTTY for Windows. You can download it from the PuTTY Download Page.
  2. Set the Windows PATH environment variable to the directory where the PuTTY executables are installed:
    1. Using the secondary mouse button, click the My Computer icon on the Desktop or in Windows Explorer
    2. Select Properties from the Context Menu; this brings up the System Properties dialog
    3. Click the Advanced System Settings tab for Vista and Windows 7, or Windows 8 or the Advanced tab for XP
    4. Click the Environment Variables button
    5. In the User Variables field, click on PATH and select Edit
    6. Add the PuTTY path to the existing path information
    image of Windows environment variables dialog
  3. Generate an ssh key with puttygen
    1. Click the Start button, then Click the Run button
    2. In the Run window, type puttygen and click OK
    3. Click on Generate and move the cursor around the Key field
    4. Copy the public key to your .ssh directory on Gordon
    5. On Gordon, convert the public key to an openssh key by running:
      ssh-keygen -i -f public_key.in > public_key.out in your .ssh directory
    6. Add the converted public key to your ~/.ssh/authorized_keys file
    image of keygen dialog 
     image of putty configuration session dialog
  4. Create a PuTTY profile for Gordon
    1. Click the Start button, then Click the Run button
    2. In the Run window, type putty and click OK
    3. Enter <login>@gordon.sdsc.edu in the Host Name field where <login> is your Gordon login name
    4. Expand the Category tree on the left by clicking on the plus sign (+) next to SSH
    5. Click on Auth
    6. Click the Browse button and select the private key that you created
    7. Click on Session and enter <login>@Gordon-login.sdsc.edu in the Saved Sessions field
    8. Click Save
    image of putty configuration auth dialog

Linux and Mac OS X Procedure

UNIX systems (Linux, Mac OS X, etc.) have native implementations of ssh and scp, so when using a desktop MATLAB client, the only required step is to make sure that your Gordon account has the public key from the MATLAB client machine installed in ~/.ssh/authorized_keys.

If you do not have an ssh keypair, you can generate one as follows:

  1. From the Mac/Linux command line, run ssh-keygen -t rsa
  2. Press the Enter (Return) key at the passphrase prompt (creating a passwordless keypair)
  3. This will create a file named id_rsa.pub in your .ssh directory
  4. Copy this file to Gordon and insert its contents into the file ~/.ssh/authorized_keys

Did You Get
What You
Wanted?
Yes No
Comments