You are not logged in.

#1 2018-10-15 13:38:28

vendion
Member
From: Tennessee, USA
Registered: 2010-03-10
Posts: 204
Website

[Solved] ldconfig.service fails with signal 6

I recently found myself in a situation where I had to restore my system due to a filesystem error, and now ldconfig is failing to start.

Looking at the logs for ldconfig.service I see that it is aborting (exiting due to a sigint 6)

Oct 15 09:08:21 Vili systemd[1]: Starting Rebuild Dynamic Linker Cache...
Oct 15 09:08:21 Vili systemd[1]: ldconfig.service: Main process exited, code=dumped, status=6/ABRT
Oct 15 09:08:21 Vili systemd[1]: ldconfig.service: Failed with result 'core-dump'.
Oct 15 09:08:21 Vili systemd[1]: Failed to start Rebuild Dynamic Linker Cache.

I'm able to successfully print out the ldconfig's cache

[~]─> sudo ldconfig -p | head
3224 libs found in cache `/etc/ld.so.cache'
	libzzipwrap-0.so.13 (libc6,x86-64) => /usr/lib/libzzipwrap-0.so.13
	libzzipmmapped-0.so.13 (libc6,x86-64) => /usr/lib/libzzipmmapped-0.so.13
	libzzipfseeko-0.so.13 (libc6,x86-64) => /usr/lib/libzzipfseeko-0.so.13
	libzzip-0.so.13 (libc6,x86-64) => /usr/lib/libzzip-0.so.13
	libzvbi.so.0 (libc6,x86-64) => /usr/lib/libzvbi.so.0
	libzvbi.so (libc6,x86-64) => /usr/lib/libzvbi.so
	libzvbi-chains.so.0 (libc6,x86-64) => /usr/lib/libzvbi-chains.so.0
	libzvbi-chains.so (libc6,x86-64) => /usr/lib/libzvbi-chains.so
	libzstd.so.1 (libc6,x86-64) => /usr/lib/libzstd.so.1
....

But running ldconfig with no arguments or ldconfig with the -X flag fails. Any way to force ldconfig to force update the lib to correct this issue (or any other possible solutions)?

Last edited by vendion (2018-10-15 16:34:02)

Offline

#2 2018-10-15 14:26:19

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: [Solved] ldconfig.service fails with signal 6

It aborts and leaves a coredump behind, so I'd look there first for *why* it fails.
If that's unspecific, stracing it might give you a hint where and why it fails.

Offline

#3 2018-10-15 16:09:40

vendion
Member
From: Tennessee, USA
Registered: 2010-03-10
Posts: 204
Website

Re: [Solved] ldconfig.service fails with signal 6

Yeah part of the problem is I don't see where it is writing the coredump at. I've checked in the root directory (/), roots home (/root) since I've tried running it as root  and I'm sure when the SystemD service runs it runs an root as well, and in my home when running it with sudo and don't see it.

Looking at the strace output though I just see two "no such file or directory" errors but that is all that sticks out to me

execve("/usr/bin/ldconfig", ["ldconfig"], 0x7ffd24b41aa0 /* 21 vars */) = 0
arch_prctl(0x3001 /* ARCH_??? */, 0x7fffdf3cdbe0) = -1 EINVAL (Invalid argument)
brk(NULL)                               = 0x7fb8b6dc8000
brk(0x7fb8b6dc91c0)                     = 0x7fb8b6dc91c0
arch_prctl(ARCH_SET_FS, 0x7fb8b6dc8880) = 0
uname({sysname="Linux", nodename="Vili", ...}) = 0
readlink("/proc/self/exe", "/usr/bin/ldconfig", 4096) = 17
brk(0x7fb8b6dea1c0)                     = 0x7fb8b6dea1c0
brk(0x7fb8b6deb000)                     = 0x7fb8b6deb000
openat(AT_FDCWD, "/usr/lib/locale/locale-archive", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=3346576, ...}) = 0
mmap(NULL, 3346576, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fb8b5b82000
close(3)                                = 0
openat(AT_FDCWD, "/etc/ld.so.conf", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=117, ...}) = 0
read(3, "# Dynamic linker/loader configur"..., 4096) = 117
openat(AT_FDCWD, "/etc/ld.so.conf.d", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 4
fstat(4, {st_mode=S_IFDIR|0755, st_size=64, ...}) = 0
getdents64(4, /* 4 entries */, 32768)   = 128
openat(AT_FDCWD, "/usr/lib/gconv/gconv-modules.cache", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/gconv/gconv-modules", O_RDONLY|O_CLOEXEC) = 5
fstat(5, {st_mode=S_IFREG|0644, st_size=56352, ...}) = 0
read(5, "# GNU libc iconv configuration.\n"..., 4096) = 4096
read(5, "1002//\tJUS_I.B1.002//\nmodule\tJUS"..., 4096) = 4096
read(5, "ISO-IR-110//\t\tISO-8859-4//\nalias"..., 4096) = 4096
read(5, "\t\tISO-8859-14//\nalias\tISO_8859-1"..., 4096) = 4096
read(5, "IC-ES//\nalias\tEBCDICES//\t\tEBCDIC"..., 4096) = 4096
read(5, "DIC-CP-ES//\t\tIBM284//\nalias\tCSIB"..., 4096) = 4096
read(5, "\tIBM863//\nalias\tOSF1002035F//\t\tI"..., 4096) = 4096
read(5, "37//\t\tIBM937//\nmodule\tIBM937//\t\t"..., 4096) = 4096
read(5, "JIS//\t\t\tEUC-JP//\nmodule\tEUC-JP//"..., 4096) = 4096
brk(0x7fb8b6e0c000)                     = 0x7fb8b6e0c000
read(5, "ias\tISO2022CN//\t\tISO-2022-CN//\nm"..., 4096) = 4096
read(5, "_5427-EXT//\nalias\tISO_5427EXT//\t"..., 4096) = 4096
read(5, "st\nmodule\tMAC-SAMI//\t\tINTERNAL\t\t"..., 4096) = 4096
read(5, "12//\t\tINTERNAL\t\tIBM1112\t\t1\nmodul"..., 4096) = 4096
read(5, "\tCP9448//\t\tIBM9448//\nalias\tCSIBM"..., 4096) = 3104
read(5, "", 4096)                       = 0
close(5)                                = 0
getdents64(4, /* 0 entries */, 32768)   = 0
close(4)                                = 0
openat(AT_FDCWD, "/etc/ld.so.conf.d/fakeroot.conf", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0644, st_size=21, ...}) = 0
read(4, "/usr/lib/libfakeroot\n", 4096) = 21
stat("/usr/lib/libfakeroot", {st_mode=S_IFDIR|0755, st_size=16, ...}) = 0
read(4, "", 4096)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "/etc/ld.so.conf.d/lib32-glibc.conf", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0644, st_size=11, ...}) = 0
read(4, "/usr/lib32\n", 4096)           = 11
stat("/usr/lib32", {st_mode=S_IFDIR|0755, st_size=12288, ...}) = 0
read(4, "", 4096)                       = 0
close(4)                                = 0
read(3, "", 4096)                       = 0
close(3)                                = 0
stat("/usr/lib", {st_mode=S_IFDIR|0755, st_size=90112, ...}) = 0
stat("/usr/lib64", {st_mode=S_IFDIR|0755, st_size=90112, ...}) = 0
stat("/usr/libx32", 0x7fffdf3cda10)     = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/var/cache/ldconfig/aux-cache", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0600, st_size=114096, ...}) = 0
mmap(NULL, 114096, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fb8b5b66000
rt_sigprocmask(SIG_UNBLOCK, [ABRT], NULL, 8) = 0
rt_sigprocmask(SIG_BLOCK, ~[RTMIN RT_1], [], 8) = 0
getpid()                                = 2736
gettid()                                = 2736
tgkill(2736, 2736, SIGABRT)             = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
--- SIGABRT {si_signo=SIGABRT, si_code=SI_TKILL, si_pid=2736, si_uid=0} ---
+++ killed by SIGABRT (core dumped) +++
Aborted (core dumped)

Offline

#4 2018-10-15 16:11:30

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: [Solved] ldconfig.service fails with signal 6

man coredumpctl

Offline

#5 2018-10-15 16:16:04

vendion
Member
From: Tennessee, USA
Registered: 2010-03-10
Posts: 204
Website

Re: [Solved] ldconfig.service fails with signal 6

Well that gives me even less information to go off of

           PID: 871 (ldconfig)
           UID: 0 (root)
           GID: 0 (root)
        Signal: 6 (ABRT)
     Timestamp: Mon 2018-10-15 09:08:21 EDT (3h 6min ago)
  Command Line: /sbin/ldconfig -X
    Executable: /usr/bin/ldconfig
 Control Group: /system.slice/ldconfig.service
          Unit: ldconfig.service
         Slice: system.slice
       Boot ID: 3e41dbad8f6f4496baae9329b24ef3b7
    Machine ID: 0c32eab6c31f45649e440455ed1f569c
      Hostname: Vili
       Storage: /var/lib/systemd/coredump/core.ldconfig.0.3e41dbad8f6f4496baae9329b24ef3b7.871.1539608901000000.lz4
       Message: Process 871 (ldconfig) of user 0 dumped core.
                
                Stack trace of thread 871:
                #0  0x00007f161894958f n/a (/usr/bin/ldconfig)
                #1  0x00007f161893b466 n/a (/usr/bin/ldconfig)
                #2  0x00007f161893b316 n/a (/usr/bin/ldconfig)
                #3  0x00007f161893fff0 n/a (/usr/bin/ldconfig)
                #4  0x00007f161893bcf3 n/a (/usr/bin/ldconfig)
                #5  0x00007f161894234c n/a (/usr/bin/ldconfig)
                #6  0x00007f161893c42e n/a (/usr/bin/ldconfig)

Offline

#6 2018-10-15 16:24:45

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: [Solved] ldconfig.service fails with signal 6

Just some private stack addresses in the binary.
The strace should be like

...
openat(AT_FDCWD, "/var/cache/ldconfig/aux-cache", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0600, st_size=101045, ...}) = 0
mmap(NULL, 101045, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f00096d6000
brk(0x7f000a4cb000)                     = 0x7f000a4cb000
munmap(0x7f00096d6000, 101045)          = 0
close(3)                                = 0
openat(AT_FDCWD, "/usr/lib/libfakeroot", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
...

So it's probably some garbage in aux-cache - just try to delete it.

Offline

#7 2018-10-15 16:26:35

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,466

Re: [Solved] ldconfig.service fails with signal 6

does running it with -v give you any extra clues?

Offline

#8 2018-10-15 16:33:43

vendion
Member
From: Tennessee, USA
Registered: 2010-03-10
Posts: 204
Website

Re: [Solved] ldconfig.service fails with signal 6

Removing /var/cache/ldconfig/aux-cache seems to have fixed the issue, thanks for the help!

Offline

Board footer

Powered by FluxBB