From owner-freebsd-threads@freebsd.org Sun Apr 18 21:00:28 2021 Return-Path: Delivered-To: freebsd-threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 572305F51EE for ; Sun, 18 Apr 2021 21:00:28 +0000 (UTC) (envelope-from bugzilla-noreply@FreeBSD.org) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4FNj5S1BLbz4Xj0 for ; Sun, 18 Apr 2021 21:00:28 +0000 (UTC) (envelope-from bugzilla-noreply@FreeBSD.org) Received: by mailman.nyi.freebsd.org (Postfix) id E1B8C5F52D1; Sun, 18 Apr 2021 21:00:27 +0000 (UTC) Delivered-To: threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D0C4F5F541D for ; Sun, 18 Apr 2021 21:00:27 +0000 (UTC) (envelope-from bugzilla-noreply@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FNj5R4p6Kz4XVC for ; Sun, 18 Apr 2021 21:00:27 +0000 (UTC) (envelope-from bugzilla-noreply@FreeBSD.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 6503C12F20 for ; Sun, 18 Apr 2021 21:00:27 +0000 (UTC) (envelope-from bugzilla-noreply@FreeBSD.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 13IL0R3e009246 for ; Sun, 18 Apr 2021 21:00:27 GMT (envelope-from bugzilla-noreply@FreeBSD.org) Received: (from bugzilla@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 13IL0Rdt009245 for threads@FreeBSD.org; Sun, 18 Apr 2021 21:00:27 GMT (envelope-from bugzilla-noreply@FreeBSD.org) Message-Id: <202104182100.13IL0Rdt009245@kenobi.freebsd.org> X-Authentication-Warning: kenobi.freebsd.org: bugzilla set sender to bugzilla-noreply@FreeBSD.org using -f From: bugzilla-noreply@FreeBSD.org To: threads@FreeBSD.org Subject: Problem reports for threads@FreeBSD.org that need special attention Date: Sun, 18 Apr 2021 21:00:27 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.34 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Apr 2021 21:00:28 -0000 To view an individual PR, use: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=(Bug Id). The following is a listing of current problems submitted by FreeBSD users, which need special attention. These represent problem reports covering all versions including experimental development code and obsolete releases. Status | Bug Id | Description ------------+-----------+--------------------------------------------------- Open | 237195 | pthread_mutex_unlock crash as unlocked mutex dest 1 problems total for which you should take action. From owner-freebsd-threads@freebsd.org Mon Apr 19 07:24:39 2021 Return-Path: Delivered-To: freebsd-threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id B62285E549D for ; Mon, 19 Apr 2021 07:24:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4FNyxg4TbPz3JJw for ; Mon, 19 Apr 2021 07:24:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.nyi.freebsd.org (Postfix) id 99C925E4FE6; Mon, 19 Apr 2021 07:24:39 +0000 (UTC) Delivered-To: threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9990D5E5518 for ; Mon, 19 Apr 2021 07:24:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FNyxg2cldz3JMG for ; Mon, 19 Apr 2021 07:24:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4D0E41AD7A for ; Mon, 19 Apr 2021 07:24:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 13J7OdEA017186 for ; Mon, 19 Apr 2021 07:24:39 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 13J7OdJ8017185 for threads@FreeBSD.org; Mon, 19 Apr 2021 07:24:39 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: threads@FreeBSD.org Subject: [Bug 254995] pthread_cond_timedwait() returns EDEADLK Date: Mon, 19 Apr 2021 07:24:39 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: threads X-Bugzilla-Version: 12.1-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: nkoch@demig.de X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: threads@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Apr 2021 07:24:39 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D254995 --- Comment #2 from nkoch@demig.de --- Yes, that is the thread that dead locks. I do not stop the process (to my knowledge). I am having a simple producer-consumer queue with 2 conds not_empty and not_full and one mutex (process local, PTHREAD_MUTEX_ERRORCHECK, PTHREAD_PRIO_INHERIT). EDEADLK comes from the consumer waiting for anything with timeout. The timeout is 100ms only as there is a regular keep alive check of this thread. The producer never waits. So its basically this: consumer thread: for(;;) { pthread_mutex_lock() if queue_empty() phtread_cond_timedwait() // <-- EDEADLK once in a month if !queue_empty() { read from queue pthread_cond_signal(not_full) } pthread_mutex_unlock() signal_alive() do_something() } producer thread: ... pthread_mutex_lock() if !queue_full() { write to queue pthread_cond_signal(not_empty) } pthread_mutex_unlock() ... BTW, there are about 32 threads with different realtime priorities and the programs very often forks/execs other programs. I have never seen this under FreeBSD 10.3 and 9.1 with the same software, b= ut that may of course mean that there were other effects I did not see so far. --=20 You are receiving this mail because: You are the assignee for the bug.= From owner-freebsd-threads@freebsd.org Mon Apr 19 07:52:49 2021 Return-Path: Delivered-To: freebsd-threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id C57C95E6155 for ; Mon, 19 Apr 2021 07:52:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4FNzZ94tfSz3Ky8 for ; Mon, 19 Apr 2021 07:52:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.nyi.freebsd.org (Postfix) id A752B5E5FE7; Mon, 19 Apr 2021 07:52:49 +0000 (UTC) Delivered-To: threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id A71CB5E637A for ; Mon, 19 Apr 2021 07:52:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FNzZ94F92z3KhP for ; Mon, 19 Apr 2021 07:52:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 84A0B1B998 for ; Mon, 19 Apr 2021 07:52:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 13J7qnGn032030 for ; Mon, 19 Apr 2021 07:52:49 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 13J7qnPh032029 for threads@FreeBSD.org; Mon, 19 Apr 2021 07:52:49 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: threads@FreeBSD.org Subject: [Bug 254995] pthread_cond_timedwait() returns EDEADLK Date: Mon, 19 Apr 2021 07:52:49 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: threads X-Bugzilla-Version: 12.1-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: nkoch@demig.de X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: threads@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Apr 2021 07:52:49 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D254995 --- Comment #3 from nkoch@demig.de --- Do the cond und mutex memory regions look consistent? Could it be that due to a sw bug I somehow corrupt these regions? --=20 You are receiving this mail because: You are the assignee for the bug.= From owner-freebsd-threads@freebsd.org Fri Apr 23 15:14:39 2021 Return-Path: Delivered-To: freebsd-threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 24A745F5E56 for ; Fri, 23 Apr 2021 15:14:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 4FRdB70MZ7z4m7L for ; Fri, 23 Apr 2021 15:14:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.nyi.freebsd.org (Postfix) id 0C7DF5F5F32; Fri, 23 Apr 2021 15:14:39 +0000 (UTC) Delivered-To: threads@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 0C4745F6191 for ; Fri, 23 Apr 2021 15:14:39 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FRdB66sz7z4lgS for ; Fri, 23 Apr 2021 15:14:38 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id DF17D7735 for ; Fri, 23 Apr 2021 15:14:38 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 13NFEcqx086826 for ; Fri, 23 Apr 2021 15:14:38 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 13NFEclQ086825 for threads@FreeBSD.org; Fri, 23 Apr 2021 15:14:38 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: threads@FreeBSD.org Subject: [Bug 227826] [FUSEFS]: fuse_main() hangs in pthread_cleanup_pop() Date: Fri, 23 Apr 2021 15:14:39 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: threads X-Bugzilla-Version: 11.0-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: dubaiescortsgirls.me@gmail.com X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: threads@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Apr 2021 15:14:39 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D227826 LaneJane changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dubaiescortsgirls.me@gmail. | |com --- Comment #5 from LaneJane --- Hi, I'm facing an issue where, from time to time, unmounting a FUSE FS, threads hang in pthread_cleanup_pop(). For example with sysutils/fusefs-encfs. When it starts, it enters fuse_main(). And when FS is unmounted, sometimes, main thread hangs in fuse_main(), all threads being stuck in pthread_cleanup_pop(). Here is a backtrace : (gdb) thread apply all bt Thread 2 (Thread 802618000 (LWP 100408/encfs)): #0 0x0000000801da267c in pthread_cleanup_pop () from /lib/libthr.so.3 #1 0x00000008008c8b1b in fuse_session_loop_mt () from /usr/local/lib/libfuse.so.2 #2 0x00000008008cd8c2 in fuse_loop_mt () from /usr/local/lib/libfuse.so.2 #3 0x00000008008d0618 in fuse_main_real () from /usr/local/lib/libfuse.so.2 #4 0x000000000040a246 in ?? () #5 0x0000000000408a8f in ?? () #6 0x00000008006b4000 in ?? () #7 0x0000000000000000 in ?? () Thread 1 (Thread 802c69000 (LWP 101304/encfs)): #0 0x0000000801da267c in pthread_cleanup_pop () from /lib/libthr.so.3 #1 0x0000000801d9f9f3 in pthread_timedjoin_np () from /lib/libthr.so.3 #2 0x000000080069dc72 in _rtld_is_dlopened () from /libexec/ld-elf.so.1 #3 0x000000080069af21 in _rtld_is_dlopened () from /libexec/ld-elf.so.1 #4 0x0000000800698301 in dlopen () from /libexec/ld-elf.so.1 #5 0x0000000801da1f0f in pthread_exit () from /lib/libthr.so.3 #6 0x0000000801da1e3b in pthread_exit () from /lib/libthr.so.3 #7 0x0000000801d94b5d in pthread_create () from /lib/libthr.so.3 #8 0x0000000000000000 in ?? () Here are other similar backtraces : https://www.dubaiescortsgirls.me/ https://pastebin.com/raw/FXRy2u22 https://pastebin.com/raw/7CG9BuDq Process then hangs indefinitely, and only exits upon a SIGKILL. I also reported this in sysutils/fusefs-encfs, but does not seem to be a po= rt issue. https://github.com/vgough/encfs/issues/470 Thank you very much for your support ! Best regards, Ben -------------------------------------------------------- Hey, Do you still experience this problem? If you can provide a reliable reproduction case, I'll fix it. --=20 You are receiving this mail because: You are the assignee for the bug.=