[systemd-devel] How to debug systemd services failing to start with 11/SEGV?

Alexander Dahl ada at thorsis.com
Wed Apr 10 13:49:49 UTC 2024


Hello Mantas,

Am Wed, Apr 10, 2024 at 04:45:58PM +0300 schrieb Mantas Mikulėnas:
> On Wed, Apr 10, 2024 at 4:08 PM Alexander Dahl <ada at thorsis.com> wrote:
> 
> > Note: platform here is 32 bit arm, namely v5te on Microchip SAM9X60
> > SoC.  Kernel is 6.6, maybe I did not get the kernelconfig right and
> > some options are not set correctly?  Or maybe those crashes are real?
> > Then I could need some help how to _really_ enable coredumps for
> > journald, udevd, and timesyncd.  Got a hint off-list to pass
> > 'systemd.dump_core=true' to kernel cmdline, but that had no effect on
> > coredump creation.
> >
> 
> I would just set kernel.core_pattern to a *file* path, e.g.
> "/var/log/core.%P". Then use the shell's ulimit command to raise the
> coredump size limit as it defaults to zero (ulimit -c unlimited), and
> manually start /usr/lib/systemd/systemd-timesyncd from the shell (timesyncd
> is the simplest one and doesn't do anything system-critical).

Tried that already.  The service does not crash in that case.

As a workaround for now I added this to
/etc/systemd/system/systemd-journald.service.d/override.conf but I'm
pretty sure it just hides the underlying issue?

    [Service]
    MemoryDenyWriteExecute=no

Greets
Alex

> 
> Alternatively, run the service under the debugger: `gdb /usr/.../timesyncd`.
> 
> -- 
> Mantas Mikulėnas


More information about the systemd-devel mailing list