NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: lib/49816: rtld internal lock vs fork



The following reply was made to PR lib/49816; it has been noted by GNATS.

From: yamt%netbsd.org@localhost (YAMAMOTO Takashi)
To: gnats-bugs%NetBSD.org@localhost
Cc: lib-bug-people%netbsd.org@localhost, gnats-admin%netbsd.org@localhost, netbsd-bugs%netbsd.org@localhost,
	yamt%NetBSD.org@localhost
Subject: Re: lib/49816: rtld internal lock vs fork
Date: Mon,  6 Apr 2015 16:23:38 +0000 (UTC)

 >  > 	when a thread does fork(2), some other thread might hold _rtld_mutex.
 >  > 	in that case, the child process will likely deadlock soon because
 >  > 	of non-zero _rtld_mutex.  i've observed the problem with open vswitch.
 >  
 >  Non-zero _rtld_mutex by itself should not be problem. The problem exists
 >  if another thread requires the exclusive lock. I do plan to rewrite rtld
 >  at some point to never require an exclusive lock for symbol look up, but
 >  that's far from trivial. In the old world before locking, you would just
 >  hit race conditions or not.
 
 i agree on all points.
 
 and, at least in my case, "another thread requires the exclusive lock"
 actually happens.
 
 YAMAMOTO Takashi
 


Home | Main Index | Thread Index | Old Index