Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'd like to set up an ssh server with Cygwin on my Windows 7 desktop so that I can remotely access my computer in a more civilized way than using VNC. I would like to use zsh as my default shell. I would like to be able to use an existing keypair in both directions (i.e. remotely accessing the desktop and logging into other machines from the desktop). I would love to set this up once and never mess with it again.

Here's what I have so far:

  • Cygwin is installed with every possible package (I didn't realize at the time what I was getting into, but it's done)
  • I have run ssh-host-config based on one or more online guides.
  • I have changed my shell to zsh.
  • I have added various things to my .zshrc which are designed to launch ssh-agent on shell login, but they all leave multiple ssh-agent processes running after the shell is closed (I assume this is bad)
  • I would rather just have a "global" ssh-agent running
  • At one point, I was able to make outgoing ssh connections to other machines (incoming connections timed out), but this doesn't work anymore.

I would really love to know how to get sshd to start on startup (of my computer so I don't need to leave a terminal open), and how to get ssh-agent to start once and stay started so I don't need to type my key's passphrase all the time.

I have access to my router (for port forwarding).

I am not a shell configuration wizard (i.e. I don't know enough to write something to launch ssh-agent properly).

How do I coax cygwin and sshd into meeting my needs?

Thanks in advance.

share|improve this question
1  
Why don't you just install a ssh server for windows? Like Freesshd. Making it work through cygwin just seem like an unnecessary complication. –  m4573r Sep 21 '12 at 7:53
    
I'd really like having zsh on the other end of the connection. It's nice to have a *nix-style terminal with most or all of the associated commands. –  DanBlakemore Sep 21 '12 at 14:04
1  
well, if you put path/to/cygwin/bin in your path, you can just ssh and type zsh –  m4573r Sep 21 '12 at 14:08
    
I figured it would be better to have it all run through the same system rather than having different components talk to each other. I'll do freesshd for now, until somebody comes up with a better plan. –  DanBlakemore Sep 22 '12 at 4:30

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.