From owner-freebsd-threads@FreeBSD.ORG Tue Apr 20 04:39:24 2004 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BFF8E16A4CE for ; Tue, 20 Apr 2004 04:39:24 -0700 (PDT) Received: from mail.pcnet.com (mail.pcnet.com [204.213.232.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id 396C743D5A for ; Tue, 20 Apr 2004 04:39:24 -0700 (PDT) (envelope-from eischen@vigrid.com) Received: from mail.pcnet.com (mail.pcnet.com [204.213.232.4]) by mail.pcnet.com (8.12.10/8.12.1) with ESMTP id i3KBdNtf026104; Tue, 20 Apr 2004 07:39:23 -0400 (EDT) Date: Tue, 20 Apr 2004 07:39:23 -0400 (EDT) From: Daniel Eischen X-Sender: eischen@pcnet5.pcnet.com To: Mike Silbersack In-Reply-To: <20040420062033.S20848@odysseus.silby.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: threads@freebsd.org Subject: Re: MySQL and libpthread X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Apr 2004 11:39:24 -0000 On Tue, 20 Apr 2004, Mike Silbersack wrote: > > I haven't had time to fully track it down yet, but FYI I've found that > MySQL and libpthread don't seem to get along well for me; with sources > from april 12th and mysql 4.1 from ports, mysqld just seems to hang for > long periods of time, and is unkillable. When I libmap it to libthr or > libc_r, all is well. There are a lot of posts regarding mysql in the threads archives. Two things -- mysql with libwrap support doesn't work with default CFLAGS (-march), and mysql uses scope system threads which chew up more kernel resources and can hang when you hit kern.threads.* limits. To make mysql40 use scope process threads: http://people.freebsd.org/~deischen/mysql40-server.diffs > The test I was running was simply mysql's included benchmark suite, using > local socket connections to mysql. If one of the libpthread developers > can not reproduce this behavior, I'll try more tests later in the week to > see if I can pin it down more. I've got mysql40-server running here with the above patches and a test script that causes creation of 1800 mysql threads. -- Dan Eischen