From nobody Wed Oct 6 09:37:55 2021 X-Original-To: freebsd-questions@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 73E0C17EFF0B for ; Wed, 6 Oct 2021 09:38:41 +0000 (UTC) (envelope-from odhiambo@gmail.com) Received: from mail-qk1-x732.google.com (mail-qk1-x732.google.com [IPv6:2607:f8b0:4864:20::732]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4HPTss2hS4z4h8d for ; Wed, 6 Oct 2021 09:38:41 +0000 (UTC) (envelope-from odhiambo@gmail.com) Received: by mail-qk1-x732.google.com with SMTP id x12so1780259qkf.9 for ; Wed, 06 Oct 2021 02:38:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=w/GFpKkWp15X0or11I5uM9cS8K4C2k5KUvETBWked+w=; b=LPq091XQxwlUXOw/NBMKs3o/6fRF0b2OJt/0oRel3jLqwF5ELQP888ivfpGz8n6twG og2bA+QfKVk0DomDemjnGczK04EmWBhoRtaH/+svC3vVVDZEjR1PvyV9A9uZlmtUEySH 4LuQHyEOHjY+sH6sGmlBFy94WsokpkWLxtVkaV5TUQnZ533rUW6q7YQ37FpgYIO3ah0k 7EVSMfYYPXFwWpOSOWq4Ectg6Hwep1nGdQ2XoOH/oEUehC5inVMpG7znBZ4pLioevjZk OUecEHCwt/OcmyDqqrNgnGg8Vvbvrkk8mXrnI6dsF0rE4E9BEJ4U8zmSxnKJpnqM4b8R dUMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=w/GFpKkWp15X0or11I5uM9cS8K4C2k5KUvETBWked+w=; b=jGcQ6KT6x/7k8AkadMX600TtASxzBjrZ6K4qtXVaAUIUn2cxrMSzMXuscSqnXWSLxH tFjHsnUhuaJnV5GkSnzhdyFWKRffQp5TctPiA3EV4fxLpJkMtisGEKktPe7nVCjT4ipT lgXvZVhzvhhsiiMZYhXZCDfXo+DCSwjhp5Ouso6iZTqnpJQ3e2Ddm81TJHFHL8jNQXER F+3+jMYIyHM+AajwJhEk42lxapw6poXFvkGTPd3Ea/3ed2jZISswPvaRl8vLM6gv2LhJ 7gxCHgt4BwOqdT5oQhYHPspXt4ftfrgmwoHYDoKEs6sWPKvHOoLYYbQPzqu3uRLHEeB/ M5Eg== X-Gm-Message-State: AOAM533PMxqqVicaMK6ztr72l9au+BmMXVPQ2YzZVd7k7N1XCtFKlAM1 3h/nqPTEnxOk7EN8eS3eTN4dRQvwue4x1kfbS80= X-Google-Smtp-Source: ABdhPJxKj3R23f/L/nwE8USSfddhP6NDNcc+Fu3p+xQUvnxsnqgP5nqzMxVmEuqw3PYVhWXInmVDNu3VagnbjhC0kp8= X-Received: by 2002:a37:a6d8:: with SMTP id p207mr18527128qke.257.1633513114588; Wed, 06 Oct 2021 02:38:34 -0700 (PDT) List-Id: User questions List-Archive: https://lists.freebsd.org/archives/freebsd-questions List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org MIME-Version: 1.0 References: In-Reply-To: From: Odhiambo Washington Date: Wed, 6 Oct 2021 12:37:55 +0300 Message-ID: Subject: Re: How do I get a coredump file from an application? To: Kurt Hackenberg Cc: User Questions Content-Type: multipart/alternative; boundary="000000000000ee5bf305cdabe8ea" X-Rspamd-Queue-Id: 4HPTss2hS4z4h8d X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-ThisMailContainsUnwantedMimeParts: N --000000000000ee5bf305cdabe8ea Content-Type: text/plain; charset="UTF-8" On Tue, Oct 5, 2021 at 10:56 PM Kurt Hackenberg wrote: > On 2021/10/04 03:44, Odhiambo Washington wrote: > > > I have my MTA (Exim) crushing, with the following message in its > panic.log: > > > > 2021-10-01 04:10:58 SIGSEGV (maybe attempt to write to immutable memory) > > 2021-10-01 04:11:26 SIGSEGV (maybe attempt to write to immutable memory) > > 2021-10-01 04:11:30 SIGSEGV (maybe attempt to write to immutable memory) > > 2021-10-01 04:11:35 SIGSEGV (maybe attempt to write to immutable memory) > > > > I need to obtain a coredump file from the crashing process for debugging > > purposes. > > Is that a file named "panic.log" that's written by Exim itself? > Yes > The default action for SIGSEGV is for the kernel to write the coredump > file and end the process. If Exim receives that signal, logs it, and > keeps running, Exim must handle the signal itself. > Okay. > Have you checked Exim's documentation about this? > Yes, I have. And an Exim developer has given me this task - to get Exim to create dump. I quote him below: *Arranging one is hard as Exim is setuid. I've not tried **on a BSD, but Linux requires some deliberate relaxation of security* *restrictions (setuid programs are carrying sensitive info; a **dump file has that info, leaving dump files with such info* *lying around is obviously a major risk...)* *Enable setuid coredumps (NOTE: not recommended for longterm **use. Core files will contain credentials and personally-identifying* *information. Leaving them lying around will eventually result in **a leak).* *Build exim without compiler optimisation ( -O0 ) and with debugger **symbols (for clang: -ggdb, -glldb, -gsce, -gdbx depending on your debugger ).* *clang docs: https://clang.llvm.org/docs/UsersManual.html * *Run until you get a coredump. Get the stacktrace from that.* And I was hoping that the actions I took with regard to sysctl.conf would help achieve that. -- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254 7 3200 0004/+254 7 2274 3223 "Oh, the cruft.", egrep -v '^$|^.*#' :-) --000000000000ee5bf305cdabe8ea--