OpenSSH as a service (Was: OpenSSH through inetd)

Corinna Vinschen vinschen@cygnus.com
Thu Aug 3 02:31:00 GMT 2000


norbert.bladt@www.usa.net wrote:
> The question is: How do I get the pid of the still running old sshd ?
> The PID is written in the "PidFile" given in the sshd_config.
> However, the problem in 2.1.0p3 is, again, the "CRLF" at the
> end of this file. So, I can't use it, at all to kill the sshd
> via
>         kill -9 `cat /var/run/sshd.pid`
> Neither "echo" nor "cat" work because of the CRLF.
> Is that fixed in 2.1.1p4 ?

No and it will remain that way for a while. I'm still hoping
to get Cygwin support merged in the portable OpenSSH sources
main tree. If that is the case, I'm able to get smaller patches
checked in easier. Let's name it political.

Personally I have a simple script which reads the pid's from
ps output and kills all sshd then:

====================================
#!/bin/sh
net stop sshd >/dev/null 2>&1
PID=`ps -e | awk '/sshd/{print $1}'`
if [ -n "${PID}" ]
then
  kill -9 $PID
fi
====================================

Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Developer                        mailto:cygwin@sources.redhat.com
Red Hat, Inc.
mailto:vinschen@cygnus.com

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com



More information about the Cygwin mailing list