delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/09/30/07:02:00

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <20040930110137.76042.qmail@web60306.mail.yahoo.com>
Date: Thu, 30 Sep 2004 04:01:37 -0700 (PDT)
From: Patrick Samson <p_samson AT yahoo DOT com>
Subject: Re: Cygserver 100% CPU (was: References to both cygwin1.dll and msvcrt.dl
To: cygwin AT cygwin DOT com
In-Reply-To: <20040930071221.65095.qmail@web60304.mail.yahoo.com>
MIME-Version: 1.0
X-IsSubscribed: yes
Note-from-DJ: This may be spam

--- Patrick Samson wrote:
> 
> --- Patrick Samson wrote:
> > Since my post I found a way to reproduce on
> > development the problem I have on production.
> > At some point cygserver hits 100%CPU and Postgres
> > backends are no more able to serve requests.
> > Now I must narrow the number of components
> involved,
> > to prove that the culprit is really this DLL.
> > As you suggest, it may be a mess with mem alloc.
> 
> I built the DLL another way, and now have:
> $ cygcheck ./dp40.dll
> .\dp40.dll
>   D:\cygwin\bin\cygwin1.dll <----------------
>     C:\WINNT\System32\ADVAPI32.DLL
>       C:\WINNT\System32\ntdll.dll
>       C:\WINNT\System32\KERNEL32.dll
>       C:\WINNT\System32\USER32.dll
>         C:\WINNT\System32\GDI32.dll
>       C:\WINNT\System32\RPCRT4.dll
>   D:\cygwin\bin\tcl84.dll
>   C:\WINNT\System32\WS2_32.DLL
>     C:\WINNT\System32\MSVCRT.dll <-----------
>     C:\WINNT\System32\WS2HELP.dll
> Seems better, as msvcrt.dll is only there because
> of ws2_32 (winsock2).
> 
> But the problem is still there, so this may not be
> the primary cause.
> With cygserver debug, I found the same case as:
>
http://sources.redhat.com/ml/cygwin/2004-07/msg01058.html
> (cygserver - Postgres Multiple connection Load
> Testing
> - Inifinte Loop). But this post has no reply :(
> The log file is full (75M in a few seconds!) with:
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/bsd_mutex.cc,
> line 189: Unlocked    mutex semid
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/bsd_mutex.cc,
> line 227: Try locking mutex semid
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/bsd_mutex.cc,
> line 227: Locked      mutex semid
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/sysv_sem.cc,
> line 1112: semop:  good morning (error=0)!
> 
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/sysv_sem.cc,
> line 1121: semop:  good morning!
> 
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/sysv_sem.cc,
> line 1049: semop:  semaptr=A056AA0,
> sem_base=A05684C,
> semptr=A056870, sem[3]=0 : op=-1, flag=wait
> 
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/sysv_sem.cc,
> line 1053: semop:  can't do it now
> 
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/sysv_sem.cc,
> line 1086: semop:  rollback 0 through -1
> 
> cygserver:
>
/netrel/src/cygwin-1.5.10-3/winsup/cygserver/sysv_sem.cc,
> line 1109: semop:  good night!
> 
> Got to upgrade to 1.5.11 and check if it's better.
> 
> Meanwhile, Corinna, any obvious suggestion,
> looking at these above traces?

Special note for Postgresql users:
So far I can only reproduce this problem if these
3 conditions are met:
- many connections (20, 25, 27) doing a simple SELECT
- a script running SELECT, CREATE/DROP TABLE/INDEX ...
- a pgAdmin III connected (but without activity)
(Postgresql version 7.3.6)

Quite the same with 1.5.11-3, only the loop is slower
so the CPU is not 100% and the log file doesn't
grow wildly.
Just an extract of the log here (full file 263K on
request):

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/bsd_mutex.cc,
line 189: Unlocked    mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/bsd_mutex.cc,
line 232: Try locking mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/bsd_mutex.cc,
line 232: Locked      mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1112: semop:  good morning (error=0)!

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1121: semop:  good morning!

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1049: semop:  semaptr=A056718, sem_base=A056440,
semptr=A0564F4, sem[15]=0 : op=-1, flag=wait

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1053: semop:  can't do it now

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1086: semop:  rollback 0 through -1

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1109: semop:  good night!

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/bsd_mutex.cc,
line 189: Unlocked    mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/bsd_mutex.cc,
line 232: Try locking mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/bsd_mutex.cc,
line 232: Locked      mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1112: semop:  good morning (error=4)!

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1218: Unlocked    mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 968: call to semop(65537, 0x22E444, 1)

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 994: Try locking mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 994: Locked      mutex semid
cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1049: semop:  semaptr=A056760, sem_base=A05650C,
semptr=A056530, sem[3]=0 : op=-1, flag=wait

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1053: semop:  can't do it now

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1086: semop:  rollback 0 through -1

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/sysv_sem.cc,
line 1109: semop:  good night!

cygserver:
/netrel/src/cygwin-1.5.11-1/winsup/cygserver/bsd_mutex.cc,
line 189: Unlocked    mutex semid


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019