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]

Re: sshd problems


Some of what you asked is in the cygcheck output, but here it is: (note,
changing the cygdrive prefix, by mount -c / made no difference)

dmonk@DIETPEPSI ~
$ mount
C:\cygwin\bin on /usr/bin type user (binmode)
C:\cygwin\lib on /usr/lib type user (binmode)
C:\cygwin on / type user (binmode)
c: on /cygdrive/c type user (binmode,noumount)
h: on /cygdrive/h type user (binmode,noumount)

dmonk@DIETPEPSI ~
$ mount -p
Prefix              Type         Flags
/cygdrive           user         binmode

dmonk@DIETPEPSI ~
$ mount -c /

dmonk@DIETPEPSI ~
$ mount -p
Prefix              Type         Flags
/cygdrive           user         binmode
/                   system       binmode

dmonk@DIETPEPSI ~
$ /usr/sbin/sshd -d -d -d
debug1: sshd version OpenSSH_3.4p1
Could not load host key: /etc/ssh_host_key
Could not load host key: /etc/ssh_host_rsa_key
Could not load host key: /etc/ssh_host_dsa_key
Disabling protocol version 1. Could not load host key
Disabling protocol version 2. Could not load host key
sshd: no hostkeys available -- exiting.

This is a pretty much default installation of cygwin, installed yesterday. I
did add a few packages, such as bzip2, ncftp, openssh, vim and wget, maybe a
few others. But, otherwise, this is a default installation with
ssh-host-config run to setup openssh as a service.

David

----- Original Message -----
From: "Harig, Mark A." <maharig@idirect.net>
To: "David Monk" <david@purplebear.net>; <cygwin@cygwin.com>
Sent: Thursday, October 10, 2002 11:41 AM
Subject: RE: sshd problems


What are your mount points?

  $ mount

What is your cygdrive prefix?

  $ mount -p

If your cygdrive prefix is not '/', then consider changing it to '/':

  $ mount -c /

> -----Original Message-----
> From: David Monk [mailto:david@purplebear.net]
> Sent: Thursday, October 10, 2002 10:29 AM
> To: cygwin@cygwin.com
> Subject: sshd problems
>
>
> Hello all,
>
> I hate to start yet another thread on this, but I am just
> joining the list.
> I see there have been many varied reports of problems with
> sshd recently. I
> just wanted to throw in my experience to hopefully give some
> additional
> insight.
> I have been running cygwin with sshd as a Win2k service for
> nearly a year on
> this machine. I upgraded to openssh-3.4p1 using privlege
> separation without
> any noticed errors or problems when it became available. I can not say
> exactly what circumstances brought about my problems, but I
> noticed it about
> two weeks ago. I fought with it the day after I discovered
> the service was
> no longer running. I tried upgrading my packages. I tried
> reconfiguring ssh
> via ssh-host-config. I ignored it for a few days as I had
> other work related
> issues to deal with. I began futzing with it again two days
> ago. No joy.
> Tried reinstalling cygwin, by just moving c:\cygwin and
> installing again.
> Yesterday, I set out to remove any and all references to
> cygwin from my
> system, in the registry and filesystem, to do an absolutely
> fresh install. I
> noticed an odd thing. A c:\var directory, with a log subdir
> and a sshd.log
> file. How on earth did that get outside c:\cygwin?? Anyway, I removed
> everything, including that. I rebooted to ensure everything
> was sane. I
> setup the needed environment variable CYGWIN as "ntsec glob
> tty notitle",
> which is what I had been using for the past year. I made a
> new c:\cygwin
> dir, removed all inheritability settings, for receiving and
> propogating
> permissions. I then did a completely fresh install. Once
> everything was
> installed, I rebooted, just to be safe. I then opened up bash and ran
> ssh-host-config, checked the permissions and ownership of
> /etc/ssh* and
> /var/empty, and ensured the sshd user had been created. Then
> I tried the
> service. No joy. I get the now common, I'm sure, error:
> $ cygrunsrv -S sshd
> cygrunsrv: Error starting a service: QueryServiceStatus:
> Win32 error 1062:
> The service has not been started.
>
> I get nothing in /var/log/sshd.log I now also noticed I have
> c:\var\log\sshd.log again, but it is as well empty. When I
> try to run sshd
> in debug, I get this:
> $ /usr/sbin/sshd -d -d -d
> debug1: sshd version OpenSSH_3.4p1
> Could not load host key: /etc/ssh_host_key
> Could not load host key: /etc/ssh_host_rsa_key
> Could not load host key: /etc/ssh_host_dsa_key
> Disabling protocol version 1. Could not load host key
> Disabling protocol version 2. Could not load host key
> sshd: no hostkeys available -- exiting.
>
> Seeing as how it somehow creates as c:\var\log\sshd.log, I
> decided to try a
> little something. I created a c:\etc:
> $ mkdir /cygdrive/c/etc
> I then decided to copy the key files there, and I get this
> weird problem:
> $ cp ssh_host_key ssh_host_key.pub ssh_host_dsa_key
> ssh_host_dsa_key.pub
> ssh_host_rsa_key ssh_host_rsa_key.pub /cygdrive/c/etc/
> cp: `ssh_host_key.exe' and `/cygdrive/c/etc/ssh_host_key' are
> the same file
> cp: `ssh_host_dsa_key.exe' and
> `/cygdrive/c/etc/ssh_host_dsa_key' are the
> same file
> cp: `ssh_host_rsa_key.exe' and
> `/cygdrive/c/etc/ssh_host_rsa_key' are the
> same file
>
> I have no clue where the .exe came from on those source file
> listings, but
> it most certainly did not copy the keys. It did copy the .pub
> files though.
> Of course, I am sure this is due to the permissions, since
> system owns them.
> So, I changed the owner to myself, copied the files and
> changed the owner
> back.
> Anyway, this didn't do any good either as /usr/sbin/sshd -d
> -d -d gives the
> same problems as before, but I am guessing that something has to have
> changed in the packaging of openssh or within the cygwin1.dll so that
> openssh is not properly respecting the cygwin paths.
>
> I hope this can somehow help track down this issue as I rely
> heavily on my
> workstations ssh server for my remote after hours work that I do.
> Pasting the output of cygcheck -svr below.
>
> ---
> David Monk CCNA, MCSE
> david@purplebear.net
>
>
> Cygwin Win95/NT Configuration Diagnostics
> Current System Time: Thu Oct 10 09:21:44 2002
>
> Windows 2000 Professional Ver 5.0 Build 2195 Service Pack 3
>
> Path:   C:\cygwin\usr\local\bin
>         C:\cygwin\bin
>         C:\cygwin\bin
>         C:\cygwin\bin
>         C:\cygwin\usr\local\bin
>         c:\WINNT\system32
>         c:\WINNT
>         c:\WINNT\System32\Wbem
>         c:\MSSQL7\BINN
>
> SysDir: C:\WINNT\System32
> WinDir: C:\WINNT
>
> CYGWIN = `ntsec ntea glob tty notitle'
> HOME = `C:\cygwin\home\dmonk'
> MAKE_MODE = `unix'
> PWD = `/home/dmonk'
> USER = `dmonk'
>
> ALLUSERSPROFILE = `C:\Documents and Settings\All Users'
> APPDATA = `C:\Documents and Settings\dmonk\Application Data'
> COMMONPROGRAMFILES = `C:\Program Files\Common Files'
> COMPUTERNAME = `DIETPEPSI'
> COMSPEC = `C:\WINNT\system32\cmd.exe'
> HOMEDRIVE = `C:'
> HOMEPATH = `\'
> LOGONSERVER = `\\JIMI'
> MANPATH = `:/usr/ssl/man'
> NUMBER_OF_PROCESSORS = `1'
> OLDPWD = `/cygdrive/c/etc'
> OS2LIBPATH = `C:\WINNT\system32\os2\dll;'
> PATHEXT = `.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH'
> PROCESSOR_ARCHITECTURE = `x86'
> PROCESSOR_IDENTIFIER = `x86 Family 6 Model 8 Stepping 3, GenuineIntel'
> PROCESSOR_LEVEL = `6'
> PROCESSOR_REVISION = `0803'
> PROGRAMFILES = `C:\Program Files'
> PROMPT = `$P$G'
> PS1 = `\[\033]0;\w\007
> \033[32m\]\u@\h \[\033[33m\w\033[0m\]
> $ '
> SHLVL = `1'
> SYSTEMDRIVE = `C:'
> SYSTEMROOT = `C:\WINNT'
> TEMP = `c:\DOCUME~1\dmonk\LOCALS~1\Temp'
> TERM = `cygwin'
> TMP = `c:\DOCUME~1\dmonk\LOCALS~1\Temp'
> USERDOMAIN = `CJDS_MEM'
> USERNAME = `dmonk'
> USERPROFILE = `C:\Documents and Settings\dmonk'
> WINDIR = `C:\WINNT'
> _ = `/usr/bin/cygcheck'
>
> HKEY_CURRENT_USER\Software\Cygnus Solutions
> HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin
> HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2
>   (default) = `/cygdrive'
>   cygdrive flags = 0x00000022
> HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2\/
>   (default) = `C:\cygwin'
>   flags = 0x00000002
> HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2\/usr/bin
>   (default) = `C:\cygwin/bin'
>   flags = 0x00000002
> HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2\/usr/lib
>   (default) = `C:\cygwin/lib'
>   flags = 0x00000002
> HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\Program Options
> HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions
> HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin
> HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2
> HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\Program Options
>
> a:  fd           N/A    N/A
> c:  hd  NTFS    6459Mb  54% CP CS UN PA FC
> d:  cd           N/A    N/A
> h:  hd  NTFS    6482Mb  11% CP CS UN PA FC
>
> C:\cygwin      /          user    binmode
> C:\cygwin/bin  /usr/bin   user    binmode
> C:\cygwin/lib  /usr/lib   user    binmode
> .              /cygdrive  user    binmode,cygdrive
>
> Found: C:\cygwin\bin\bash.exe
> Found: C:\cygwin\bin\cat.exe
> Not Found: cpp (good!)
> Found: C:\cygwin\bin\find.exe
> Not Found: gcc
> Not Found: gdb
> Not Found: ld
> Found: C:\cygwin\bin\ls.exe
> Not Found: make
> Found: C:\cygwin\bin\sh.exe
>
>    58k 2002/05/07 C:\cygwin\bin\cygbz2-1.dll - os=4.0 img=1.0 sys=4.0
>                   "cygbz2-1.dll" v0.0 ts=2002/5/7 1:33
>   625k 2002/08/09 C:\cygwin\bin\cygcrypto.dll - os=4.0 img=1.0 sys=4.0
>                   "cygcrypto.dll" v0.0 ts=2002/8/9 15:20
>    45k 2001/04/25 C:\cygwin\bin\cygform5.dll - os=4.0 img=1.0 sys=4.0
>                   "cygform5.dll" v0.0 ts=2001/4/25 0:28
>    35k 2002/01/09 C:\cygwin\bin\cygform6.dll - os=4.0 img=1.0 sys=4.0
>                   "cygform6.dll" v0.0 ts=2002/1/9 0:03
>    19k 2002/02/20 C:\cygwin\bin\cyggdbm.dll - os=4.0 img=1.0 sys=4.0
>                   "cyggdbm.dll" v0.0 ts=2002/2/19 21:05
>    17k 2001/06/28 C:\cygwin\bin\cyghistory4.dll - os=4.0
> img=1.0 sys=4.0
>                   "cyghistory4.dll" v0.0 ts=2001/1/6 22:34
>    20k 2002/07/17 C:\cygwin\bin\cyghistory5.dll - os=4.0
> img=1.0 sys=4.0
>                   "cyghistory5.dll" v0.0 ts=2002/7/17 16:18
>   929k 2002/06/24 C:\cygwin\bin\cygiconv-2.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygiconv-2.dll" v0.0 ts=2002/6/24 13:24
>    22k 2001/12/13 C:\cygwin\bin\cygintl-1.dll - os=4.0 img=1.0 sys=4.0
>                   "cygintl-1.dll" v0.0 ts=2001/12/13 3:28
>    28k 2002/09/20 C:\cygwin\bin\cygintl-2.dll - os=4.0 img=1.0 sys=4.0
>                   "cygintl-2.dll" v0.0 ts=2002/9/19 22:13
>    26k 2001/04/25 C:\cygwin\bin\cygmenu5.dll - os=4.0 img=1.0 sys=4.0
>                   "cygmenu5.dll" v0.0 ts=2001/4/25 0:27
>    20k 2002/01/09 C:\cygwin\bin\cygmenu6.dll - os=4.0 img=1.0 sys=4.0
>                   "cygmenu6.dll" v0.0 ts=2002/1/9 0:03
>   156k 2001/04/25 C:\cygwin\bin\cygncurses++5.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygncurses++5.dll" v0.0 ts=2001/4/25 0:29
>   175k 2002/01/09 C:\cygwin\bin\cygncurses++6.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygncurses++6.dll" v0.0 ts=2002/1/9 0:03
>   226k 2001/04/25 C:\cygwin\bin\cygncurses5.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygncurses5.dll" v0.0 ts=2001/4/25 0:17
>   202k 2002/01/09 C:\cygwin\bin\cygncurses6.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygncurses6.dll" v0.0 ts=2002/1/9 0:03
>    15k 2001/04/25 C:\cygwin\bin\cygpanel5.dll - os=4.0 img=1.0 sys=4.0
>                   "cygpanel5.dll" v0.0 ts=2001/4/25 0:27
>    12k 2002/01/09 C:\cygwin\bin\cygpanel6.dll - os=4.0 img=1.0 sys=4.0
>                   "cygpanel6.dll" v0.0 ts=2002/1/9 0:03
>    40k 2001/11/21 C:\cygwin\bin\cygpcre.dll - os=4.0 img=1.0 sys=4.0
>                   "cygpcre.dll" v0.0 ts=2001/11/21 16:15
>    39k 2001/11/21 C:\cygwin\bin\cygpcreposix.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygpcreposix.dll" v0.0 ts=2001/11/21 16:15
>    22k 2002/06/09 C:\cygwin\bin\cygpopt-0.dll - os=4.0 img=1.0 sys=4.0
>                   "cygpopt-0.dll" v0.0 ts=2002/6/9 0:45
>   108k 2001/06/28 C:\cygwin\bin\cygreadline4.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygreadline4.dll" v0.0 ts=2001/1/6 22:34
>   127k 2002/07/17 C:\cygwin\bin\cygreadline5.dll - os=4.0
> img=1.0 sys=4.0
>                   "cygreadline5.dll" v0.0 ts=2002/7/17 16:18
>   159k 2002/08/09 C:\cygwin\bin\cygssl.dll - os=4.0 img=1.0 sys=4.0
>                   "cygssl.dll" v0.0 ts=2002/8/9 15:20
>    50k 2002/03/12 C:\cygwin\bin\cygz.dll - os=4.0 img=1.0 sys=4.0
>                   "cygz.dll" v0.0 ts=2002/3/11 22:38
>   883k 2002/07/06 C:\cygwin\bin\cygwin1.dll - os=4.0 img=1.0 sys=4.0
>                   "cygwin1.dll" v0.0 ts=2002/7/6 1:16
>     Cygwin DLL version info:
>         DLL version: 1.3.12
>         DLL epoch: 19
>         DLL bad signal mask: 19005
>         DLL old termios: 5
>         DLL malloc env: 28
>         API major: 0
>         API minor: 54
>         Shared data: 3
>         DLL identifier: cygwin1
>         Mount registry: 2
>         Cygnus registry name: Cygnus Solutions
>         Cygwin registry name: Cygwin
>         Program options name: Program Options
>         Cygwin mount registry name: mounts v2
>         Cygdrive flags: cygdrive flags
>         Cygdrive prefix: cygdrive prefix
>         Cygdrive default prefix:
>         Build date: Sat Jul 6 02:16:58 EDT 2002
>         CVS tag: cygwin-1-3-12-1
>         Shared id: cygwin1S3
>
>
> Cygwin Package Information
> Last downloaded files to: @
> Last downloaded files from: @
>
> Package             Version
> _update-info-dir    00069-1
> ash                 20020731-1
> base-files          1.0-1
> base-passwd         1.0-1
> bash                2.05b-5
> bzip2               1.0.2-2
> cygrunsrv           0.95-1
> cygutils            1.1.2-1
> cygwin              1.3.12-4
> diff                1.0-1
> diffutils           2.8.1-1
> fileutils           4.1-1
> findutils           4.1.7-4
> gawk                3.1.1-3
> gdbm                1.8.0-4
> grep                2.5-1
> groff               1.17.2-1
> gzip                1.3.3-4
> less                374-1
> libbz2_1            1.0.2-2
> libiconv2           1.8-2
> libintl1            0.10.40-1
> libintl2            0.11.5-1
> libncurses5         5.2-1
> libncurses6         5.2-8
> libpopt0            1.6.4-4
> libreadline4        4.1-2
> libreadline5        4.3-1
> login               1.4-4
> man                 1.5g-2
> ncftp               3.1.4-1
> ncurses             5.2-8
> openssh             3.4p1-5
> openssl             0.9.6g-1
> pcre                3.7-1
> readline            4.3-1
> sed                 3.02-1
> sh-utils            2.0-2
> tar                 1.13.19-1
> termcap             20020930-1
> terminfo            5.2-3
> texinfo             4.2-3
> textutils           2.0.21-1
> vim                 6.1-2
> wget                1.8.2-1
> which               1.5-1
> whois               4.5.17-1
> zlib                1.1.4-1
>
>
> --
> 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/
>
>



--
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]