MathGroup Archive 2002

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: SSH and Remote Math Kernels

Eric Brown <ecbrown at> wrote:
>     Could someone enlighten me on how to link (start up) a remote kernel
> with the ssh protocol? I run into a problem in that my password is required
> to log in to the remote machine...

 You should create a public-private key pair on your machine with
ssh-keygen (I am assuming you are on some kind of Unix). Than you
should put public key in the file (usually) ${HOME}/.ssh/authorized_keys
on the kernel machine.
  At this point ssh should ask you not for your
password but for the passphrase you used to create keys. My passphrase
is usually same as my password but it need not be.
  Than you should start ssh-agent on your machine and ssh-add your
key to this agent. Both by just executing respective commands. At this
point you should be able to ssh to kernel machine without *any* passwords
or passphrases. Then the remote kernel thing will work as well.
  When you are done you might consider setting up your X session so that
ssh-agent is started and your key is added to it at the start of your
X session and than it works for all shells and programs. This is done
by adding something like this to .xsession (or .xinitrc):

# kill old ssh-agents
killall ssh-agent
# start ssh-agent
# must eval since ssh-agent will spit out some environment configuration
eval `ssh-agent -s`
# add ssh identity to agent
# inputting /dev/null to force X gui input panel
ssh-add </dev/null

You may need some experimenting to get everything working properly.
Reading man pages of ssh-* command will help a lot, and debug mode
is extremely useful: ssh -v


Kresimir Kumericki    kkumer at
"Fizika svemira" -

  • Prev by Date: Re: Simple integral problem
  • Next by Date: Re: Newbie Question
  • Previous by thread: Re: SSH and Remote Math Kernels
  • Next by thread: variational calculus