[Pdns-users] Attempt to print an unset dnsname

Klaus Darilion klaus.mailinglists at pernau.at
Tue Nov 7 14:57:33 UTC 2017

Hi Remi!

Thanks for the clarification.

To debug this issue I want to generate a core dump instead of raising an
exception. Hence I did:

std::string DNSName::toString(const std::string& separator, const bool
trailing) const
  if (empty()) {
+    DLOG(L<<Logger::Error<<"Attempt to print an unset dnsname");
-    throw std::out_of_range("Attempt to print an unset dnsname");
+    abort();

But whatever I try I do not receive a core dump. I also disabled the
SIGABRT handler and started PowerDNS with --guardian=no, checked the
core pattern, disk space, write permissions, ulimit ... no core dump.

I do not even see the added log message, nor any kernel logging about
the aborted process.

Do you have any ideas what I am doing wrong?


Am 25.10.2017 um 10:53 schrieb Remi Gacogne:
> Hi Klaus,
> On 10/25/2017 10:29 AM, Klaus Darilion wrote:
>> May it be that the exception and stacktrace do not correlate, eg. the
>> exception causes some exit code, the exit is caught by the signal
>> handler, something goes wrong (signal 11=segfault), and then a stack
>> trace is generated of some other thread which does not correlate with
>> the origin exception?
> Yes, that's exactly what's happening. One thread call exit() while
> another one is working, and it looks the one still working is trying to
> access something that has already been destroyed by the exiting one,
> causing a memory violation. The resulting signal 11 is caught and we get
> the related trace, but unfortunately that doesn't tell us anything about
> the first exception.
> _______________________________________________
> Pdns-users mailing list
> Pdns-users at mailman.powerdns.com
> https://mailman.powerdns.com/mailman/listinfo/pdns-users

More information about the Pdns-users mailing list