Opened 7 years ago

#11537 new Support Requests

named_recursive_mutex deadlock problem

Reported by: zzweng_2001@… Owned by: Ion Gaztañaga
Milestone: To Be Determined Component: interprocess
Version: Boost 1.49.0 Severity: Problem
Keywords: Cc:

Description

In my fastcgi application code, I tried to use managed_mapped_file to communicate between process, and use named_recursive_mutex to do synchronization. With fastcgi, I started 3 child process, after a few minutes, I found all these 3 process waiting for lock: Thread 1 (Thread 0x7f0e2b536820 (LWP 16593)): #0 0x0000003d9ee0e054 in lll_lock_wait () from /lib64/libpthread.so.0 #1 0x0000003d9ee093a3 in _L_lock_892 () from /lib64/libpthread.so.0 #2 0x0000003d9ee09287 in pthread_mutex_lock () from /lib64/libpthread.so.0 #3 0x000000000054a9cf in boost::interprocess::ipcdetail::posix_recursive_mutex::lock() () #4 0x000000000054aabc in boost::interprocess::interprocess_recursive_mutex::lock() () #5 0x000000000054b304 in boost::interprocess::ipcdetail::shm_named_recursive_mutex::lock() () #6 0x000000000054b390 in boost::interprocess::named_recursive_mutex::lock() () #7 0x000000000054bade in boost::interprocess::scoped_lock<boost::interprocess::named_recursive_mutex>::scoped_lock(boost::interprocess::named_recursive_mutex&) () #8 0x00000000005647ef in IPRateLimit::CIPLimit::incCount(unsigned int, IPRateLimit::iprate&) () #9 0x00000000004d8017 in (anonymous namespace)::TboProc::operator()() () #10 0x00000000004e40f9 in Goome::FCGI_Accepter<(anonymous namespace)::TboProc>::dispatch() () #11 0x00000000004e2f80 in fork_main(int) () #12 0x00000000004e346f in main ()

Attachments (2)

IPLimit.cpp (7.9 KB ) - added by zzweng_2001@… 7 years ago.
IPLimit.h (3.3 KB ) - added by zzweng_2001@… 7 years ago.

Download all attachments as: .zip

Change History (2)

by zzweng_2001@…, 7 years ago

Attachment: IPLimit.cpp added

by zzweng_2001@…, 7 years ago

Attachment: IPLimit.h added
Note: See TracTickets for help on using tickets.