From owner-freebsd-current@freebsd.org Sat Jun 25 14:04:34 2016 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9A492B81CE7 for ; Sat, 25 Jun 2016 14:04:34 +0000 (UTC) (envelope-from daniel.engberg.lists@pyret.net) Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [IPv6:2001:4b98:c:538::196]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 62D5F1CF0 for ; Sat, 25 Jun 2016 14:04:34 +0000 (UTC) (envelope-from daniel.engberg.lists@pyret.net) Received: from mfilter24-d.gandi.net (mfilter24-d.gandi.net [217.70.178.152]) by relay4-d.mail.gandi.net (Postfix) with ESMTP id 6E9FD17209D; Sat, 25 Jun 2016 16:04:31 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at mfilter24-d.gandi.net Received: from relay4-d.mail.gandi.net ([IPv6:::ffff:217.70.183.196]) by mfilter24-d.gandi.net (mfilter24-d.gandi.net [::ffff:10.0.15.180]) (amavisd-new, port 10024) with ESMTP id 7_I3SmEptIfB; Sat, 25 Jun 2016 16:04:30 +0200 (CEST) X-Originating-IP: 90.231.139.91 Received: from [192.168.1.249] (h91n1-gl-a-a31.ias.bredband.telia.com [90.231.139.91]) (Authenticated sender: daniel.engberg@pyret.net) by relay4-d.mail.gandi.net (Postfix) with ESMTPSA id 95718172095; Sat, 25 Jun 2016 16:04:29 +0200 (CEST) Subject: Re: Samba 4.3 and 4.4 crashes on FreeBSD 11-ALPHA4 To: Guy Yur , Konstantin Belousov References: <20160625084939.GI38613@kib.kiev.ua> <20160625092040.GL38613@kib.kiev.ua> Cc: freebsd-current From: Daniel Engberg Message-ID: <1a0a1d8e-f325-1ae7-3d85-7013726305a5@pyret.net> Date: Sat, 25 Jun 2016 16:03:27 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Jun 2016 14:04:34 -0000 On 2016-06-25 12:16, Guy Yur wrote: > Hi, > > On Sat, Jun 25, 2016 at 12:20 PM, Konstantin Belousov > wrote: >> On Sat, Jun 25, 2016 at 11:49:39AM +0300, Konstantin Belousov wrote: >>> On Sat, Jun 25, 2016 at 01:03:13AM +0300, Guy Yur wrote: >>>> libtdb.so.1`tdb_runtime_check_for_robust_mutexes + 1475 at mutex.c:957 >>>> ... >>> >>> The pointer to tdb_runtime_check_for_robust_mutexes() appeared to be >>> most useful, thanks. >>> >>> The two patches below should fix samba use of robustness. First, >>> kernel erronously reset robust lists locations on fork. Second, the >>> pthread_mutex_trylock() for owned errorcheck mutex must return EDEADLK >>> and not EBUSY. Try that. >> >> Correction, there was a reason why I initially put the rb list pointers >> into zeroed region. It still needs to be zeroed on new thread creation. >> Updated patch. >> > > With the patch to the 3 files applied, smbd, nmbd and smbclient > no longer crash on my machine. > > Tested with r302191+patch. > > Thanks, > Guy > Hi, Sorry for being late to the party :/ I've tested your patch (the latest one) and it also seems to do the trick. Thanks! FreeBSD 11.0-ALPHA5 (AMD64) - Samba 4.4 Best regards, Daniel