X-Recipient: archive-cygwin@delorie.com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:mime-version:in-reply-to:references:date
	:message-id:subject:from:to:content-type
	:content-transfer-encoding; q=dns; s=default; b=cKgzeAX/XTKdC3uq
	fqFhV/B3q2SiOPpf5fZo7Y2raBvz6wJaO/phUrkSWuy1VHBAdxI0HRCjnEajfyvL
	pVJX3qtq6dtXxsWOn5ra9dzT8YAbJeRsKo0Ml6OPiZwk1wm70mO4CHJHWNQ4bLAc
	D2MxFOxKz5d5DN7pUUMYQoP/Rfw=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
	:list-unsubscribe:list-subscribe:list-archive:list-post
	:list-help:sender:mime-version:in-reply-to:references:date
	:message-id:subject:from:to:content-type
	:content-transfer-encoding; s=default; bh=R/B5p5sbT5RtmNaRXlQuwr
	SpsOM=; b=D94IL0jxfun8Iyw70cwml1l2oWpH6X0VaPqNDnYOsiklE62HUuz1KN
	1MM/+oyNloRhl3wFUvQvJRKN66x0/3oubvMn0VkXCFRnFgFcvBXDZdgKZj7mYhVJ
	6cuvCN5ibT6Re+/XFDM5jAMSn/RQkuZ6PAJjmqspgE9BTFDRybBgA=
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=-1.7 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2
X-HELO: mail-la0-f53.google.com
MIME-Version: 1.0
X-Received: by 10.152.37.228 with SMTP id b4mr335971lak.111.1428654201560; Fri, 10 Apr 2015 01:23:21 -0700 (PDT)
In-Reply-To: <CAO2ddnbNTJ0SFVzvLYCZYJuG1BZYx-QNhMrhtweQuVU9MPkvmg@mail.gmail.com>
References: <CAO2ddnYogbgan+u7a_R23tBG_oVLgN0Yhxz6WAG5XkNjv1i9MA@mail.gmail.com>	<CAO2ddnYDX7EjCR_0VyZivW-nJwQHxLaLsvR5wFzBBSYOsk6TMQ@mail.gmail.com>	<loom.20150311T204216-575@post.gmane.org>	<CAO2ddnbNTJ0SFVzvLYCZYJuG1BZYx-QNhMrhtweQuVU9MPkvmg@mail.gmail.com>
Date: Fri, 10 Apr 2015 10:23:21 +0200
Message-ID: <CAO2ddna0Fjeppu9OBtTP=gBXMc7fHdR_2JqdP3tvburNM6EpuQ@mail.gmail.com>
Subject: Fwd: sshd PID changed
From: =?UTF-8?Q?Kizito_Porta_Balany=C3=A0?= <kfeina@gmail.com>
To: cygwin@cygwin.com
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id t3A8Nibt000864

2015-03-11 20:52 GMT+01:00 Mark Geisert <mark@maxrnd.com>:
> Kizito Porta Balanyà writes:
>> No one is interested in this commented behaviour ?
>> Or it is expected as designed ?
>>
>> Thanks a lot for your time.
>>
>> 2015-03-10 10:16 GMT+01:00 Kizito Porta Balanyà:
>> > I'm receiving some rare monit messages related to the sshd service.
>> >
>> > The service "cygrunsrv sshd" is not restarted (eventviewer is OK), but
>> > sometimes (not always) I get the following alerts:
>> >
>> >
>> > Alert 1:
>> > PID changed Service checkMatching_sshd
>> >                  Date:        Mon, 09 Mar 2015 16:14:26
>> >                  Description: process PID changed from 1968 to 1744
>> >
>> > PPID changed Service checkMatching_sshd
>> >                  Date:        Mon, 09 Mar 2015 16:14:26
>> >                  Description: process PPID changed from 5344 to 2860
>
> Are those Windows pids or Cygwin pids?  Was monit built under Cygwin?
>

Sorry, I missed your answer.

They are cygwin pids and monit was built under cygwin.


> Windows processes don't (and can't) change their own pid.  Cygwin processes
> don't have a need to do it and I don't know if it's even possible (by
> mucking around in the shared data segment).  I feel unclean even suggesting
> it might be possible.
>
> What's likely happening is monit is reporting two separate sshd processes as
> if it's talking about the same process.  When you login via sshd, another
> sshd process is created for your session.

Yes you are right.

Procmatch matches 3 sshd process. I should use PIDFILE instead.

Thanks a lot.

> Or perhaps monit is malfunctionally not checking the process startup times
> in addition to the process pids to distinguish between them.
> HTH,
>
> ..mark
>

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


