This is the mail archive of the cygwin 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]

Cygwin service fails to start because of duplicate dll


Dear All,

 

In case anyone else encounters problems starting services because of
duplicate cygwin1.dll on the path, here is how I found out that the
duplicate was the problem and the workaround I use:

 

After installing sshd (with ssh-host-config script), I could start the
service from the command line (/usr/sbin/sshd) but it failed to start
automatically at boot-up or from the Windows Services dialog box. By
looking in the Windows Event Viewer I found that the service was failing
with because:

 The following information is part of the event: sshd: PID 2564:
Possible duplicate cygwin1.dll:
/cygdrive/c/Merant/DIMENS~1/8.0/PROG/cygwin1.dll..

 

If I removed Merant/DIMENS~1/8.0/PROG from the Path environment variable
and rebooted, the service started properly (reboot needed to make sure
that the path used by the service is up to date). Unfortunately, I'm not
allowed to do this permanently on this work machine, so I instead I
changed the PATH environment

variable which the service sees when it runs, to stop it from seeing the
duplicate dll... to do this you have to first uninstall the original
service (installed by the ssh-host-config script), and re-install with
the new environment options. At the Cygwin prompt:

1. remove the isntalled service:
cygrunsrv -R sshd

2. re-install the service with the additional parameter -e PATH=''
appended:
cygrunsrv -I sshd -d "CYGWIN sshd" -p /usr/sbin/sshd -a "-D" -y tcpip -e
PATH=''                                                                
 

HTH,

Steve

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


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