This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Triumph over cygrunsrv, sshd and error 1062


 After a half day of troubleshooting, reading mailing lists, and pulling
hair (mine that is), I finally figured out my problem with getting sshd
to run and wanted to share it since it took so long to find the
solution.

 I had installed cygwin, openssh, and various packages on Windows 2000
server without a hitch and was trying to get sshd to run as a service.
I'd done everything in all the cygwin/sshd/windows guides, and even
RTFM. The ssh-host-config script ran fine, however trying to run the
sshd service from the Services management console, using "net start
sshd", or from cygwin (cygrunsvr -S sshd) failed.

 Depending on the method of trying to start sshd, the errors included
"could not load host key", "Win32 error 1062", and various errors about
the host_key files not being valid files (the latter were probably
permissions errors). After chmoding and chowning everything to
perfection, making sure that SYSTEM was in the group file and hadn't
been munged, and triple checking my environment variables I was stumped.


 The problem turned out to be the mount points in the registry. I
finally ran across Igor Pechtchanski's post
(http://sources.redhat.com/ml/cygwin/2002-10/msg01885.html) which
essentially gave the fix. I had installed Cygwin "Just for me" instead
of for "Everyone" on the machine which put cygwin's mount points for
"/", "/usr/bin", and "/usr/lib" in the HKEY_CURRENT_USER portion of the
registry rather than the HKEY_LOCAL_MACHINE. Merely copying the entries
from HKCU to the corresponding section of HKLM magically allowed sshd to
start (since it's run as SYSTEM).

 Since it was so hard to find such a simple solution, I figured I'd post
this and get it into the mailing list archives.

  -Seren

ps. Other helpful resource for newbies setting up sshd under cygwin:
http://tech.erdelynet.com/cygwin-sshd.html



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]