Opened 7 years ago

Closed 5 years ago

#2423 closed defect (wontfix)

log4cplus threads and python Segmentation fault in notify_out_test.py

Reported by: jreed Owned by:
Priority: medium Milestone: Remaining BIND10 tickets
Component: Unclassified Version: bind10-old
Keywords: Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity: N/A
Sub-Project: Core Feature Depending on Ticket:
Estimated Difficulty: 5 Add Hours to Ticket: 0
Total Hours: 0 Internal?: no

Description

On three NetBSD 6.0 systems, when log4cplus-1.1.0 is built with threads (the default) it fails like:

Running test: notify_out_test.py
..............[1]   Segmentation fault (core dumped) PYTHONPATH=/home...
*** Error code 139

For example:
http://git.bind10.isc.org/~tester/builder/BIND10/20121030163907-NetBSD6-i386-GCC/logs/unittests.out

This happens with python31 and python32. Here is a backtrace:

Core was generated by `python3.2'.
Program terminated with signal 11, Segmentation fault.
#0  0xbae55082 in std::string::assign(char const*, unsigned int) ()
   from /usr/lib/libstdc++.so.7
(gdb) bt
#0  0xbae55082 in std::string::assign(char const*, unsigned int) ()
   from /usr/lib/libstdc++.so.7
#1  0xbb0721a1 in 
log4cplus::detail::clear_tostringstream(std::basic_ostringstream<char, 
std::char_traits<char>, std::allocator<char> >&) ()
   from /usr/pkg/lib/liblog4cplus-1.1.so.5
#2  0xbb072285 in log4cplus::detail::get_macro_body_oss() ()
   from /usr/pkg/lib/liblog4cplus-1.1.so.5
#3  0xbb242dfd in isc::log::LoggerImpl::outputRaw (this=0xba75b500, 
    severity=@0xba3ff444, message=...) at logger_impl.cc:141
#4  0xbb241854 in isc::log::Logger::output (this=0xbb5e5b20, 
    severity=@0xba3ff444, message=...) at logger.cc:129
#5  0xbb81b451 in ~Formatter (this=0xba3ff440, __in_chrg=<optimized 
out>)
    at ../../../../../src/lib/log/log_formatter.h:167
#6  (anonymous 
namespace)::Logger_performOutput<boost::_bi::bind_t<isc::log::Formatter<isc:
:log::Logger>, 
boost::_mfi::mf1<isc::log::Formatter<isc::log::Logger>, 
isc::log::Logger, char const* const&>, 
boost::_bi::list2<boost::_bi::value<isc::log::Logger*>, boost::arg<2> > 
> > (function=..., args=0xbb5ff22c, 
    dbgLevel=false) at log.cc:538
#7  0xbb81bd1f in (anonymous namespace)::Logger_info 
(po_self=0xba7941e0, 
    args=0xbb5ff22c) at log.cc:581
#8  0xbbabf054 in PyCFunction_Call () from 
/usr/pkg/lib/libpython3.2.so.1.0
#9  0xbbb121ed in PyEval_EvalFrameEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#10 0xbbb12066 in PyEval_EvalFrameEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#11 0xbbb13ba1 in PyEval_EvalCodeEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#12 0xbbaad599 in function_call () from /usr/pkg/lib/libpython3.2.so.1.0
#13 0xbba8a08c in PyObject_Call () from /usr/pkg/lib/libpython3.2.so.1.0
#14 0xbbb10e93 in PyEval_EvalFrameEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#15 0xbbb12066 in PyEval_EvalFrameEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#16 0xbbb12066 in PyEval_EvalFrameEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#17 0xbbb13ba1 in PyEval_EvalCodeEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#18 0xbbaad4b1 in function_call () from /usr/pkg/lib/libpython3.2.so.1.0
#19 0xbba8a08c in PyObject_Call () from /usr/pkg/lib/libpython3.2.so.1.0
#20 0xbba9d195 in method_call () from /usr/pkg/lib/libpython3.2.so.1.0
#21 0xbba8a08c in PyObject_Call () from /usr/pkg/lib/libpython3.2.so.1.0
#22 0xbbb0c381 in PyEval_CallObjectWithKeywords ()
   from /usr/pkg/lib/libpython3.2.so.1.0
#23 0xbbb445c8 in t_bootstrap () from /usr/pkg/lib/libpython3.2.so.1.0
#24 0xbba514ea in ?? () from /usr/lib/libpthread.so.1
#25 0xbb968ea0 in ___lwp_park50 () from /usr/lib/libc.so.12
#26 0xba200000 in ?? ()
#27 0xbbac0b2e in PyObject_GetAttr () from 
/usr/pkg/lib/libpython3.2.so.1.0
#28 0xbbb0dd30 in PyEval_EvalFrameEx () from 
/usr/pkg/lib/libpython3.2.so.1.0
#29 0xbb99487b in free () from /usr/lib/libc.so.12
#30 0xbbb44058 in PyObject_GC_Del () from 
/usr/pkg/lib/libpython3.2.so.1.0
#31 0xbbaac830 in PyFrame_BlockPop () from 
/usr/pkg/lib/libpython3.2.so.1.0
#32 0xbb9925b0 in ?? () from /usr/lib/libc.so.12
---Type <return> to continue, or q <return> to quit---
Backtrace stopped: previous frame inner to this frame (corrupt stack?)

This problem does not happen with log4cplus-1.0.4 nor when log4cplus-1.1.0 is built --without-threads.

I do not see the problem on a FreeBSD system.

I first brought this up on mailing list; here is the thread: https://lists.isc.org/pipermail/bind10-dev/2012-October/004011.html

Subtickets

Change History (4)

comment:1 Changed 7 years ago by jelte

  • Estimated Difficulty changed from undecided to 5

Setting this to 5; we do not know if this is easy or hard to fix. Please do not spend any more time on this than that limit; if it is not fixable within that time, spend the time of this ticket devising how to fix it (and we'll do that in another ticket)

comment:2 Changed 7 years ago by shane

  • Milestone New Tasks deleted

comment:3 Changed 6 years ago by tomek

  • Milestone set to Remaining BIND10 tickets

comment:4 Changed 5 years ago by tomek

  • Resolution set to wontfix
  • Status changed from new to closed
  • Version set to old-bind10

This issue is related to bind10 code that is no longer part of Kea.

If you are interested in BIND10/Bundy framework or its DNS components,
please check http://bundy-dns.de.

Closing ticket.

Note: See TracTickets for help on using tickets.