FS#17043 - [glibc] ldconfig segmentation fault

Attached to Project: Arch Linux
Opened by Babets (Babets) - Saturday, 07 November 2009, 09:28 GMT
Last edited by Ionut Biru (wonder) - Saturday, 07 November 2009, 17:45 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To No-one
Architecture i686
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description: every time the system launch ldconfig, it crash with a segmentation fault.
This only happens if it is launched as root (obviously it does not make sense launching it as user but in this way it doesn't crash).
Related topic: http://bbs.archlinux.org/viewtopic.php?id=83944
Unfortunately I don't find someone else that notice this problem.


Additional info:
* package version(s): 2.10.1-5

* config and/or log files etc.:
cat /var/log/messages.log | grep -i ldconfig
(...)
Nov 7 10:13:27 osaka kernel: ldconfig[3196]: segfault at 2aacb9d4 ip 08062243 sp bf9984c4 error 4 in ldconfig[8048000+9f000]
Nov 7 10:16:19 osaka kernel: ldconfig[2101]: segfault at 2a8fa9d4 ip 08062243 sp bf85f7d4 error 4 in ldconfig[8048000+9f000]
Nov 7 10:20:14 osaka kernel: ldconfig[2303]: segfault at 2aa729d4 ip 08062243 sp bfcd1f34 error 4 in ldconfig[8048000+9f000]


Steps to reproduce:
Launch ldconfig as root.
This task depends upon

Closed by  Ionut Biru (wonder)
Saturday, 07 November 2009, 17:45 GMT
Reason for closing:  Not a bug
Comment by Jan de Groot (JGC) - Saturday, 07 November 2009, 11:36 GMT
Could this be a flaky binary on your system? Try to strace it to see where it crashes.
Comment by Babets (Babets) - Saturday, 07 November 2009, 13:35 GMT
This is the output. I'm not an expert of strace but it seems that the problem is not with others files in my system. Am I wrong?

root ~ # strace ldconfig
execve("/sbin/ldconfig", ["ldconfig"], [/* 38 vars */]) = 0
uname({sys="Linux", node="osaka", ...}) = 0
brk(0) = 0x85af000
brk(0x85afcd0) = 0x85afcd0
set_thread_area({entry_number:-1 -> 6, base_addr:0x85af830, limit:1048575, seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0, useable:1}) = 0
brk(0x85d0cd0) = 0x85d0cd0
brk(0x85d1000) = 0x85d1000
open("/usr/lib/locale/locale-archive", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=1821456, ...}) = 0
mmap2(NULL, 1821456, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb765e000
close(3) = 0
open("/etc/ld.so.conf", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=69, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb765d000
read(3, "#\n# /etc/ld.so.conf\n#\n# End of f"..., 4096) = 69
stat64("/usr/lib/libfakeroot", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
stat64("/opt/qt/lib", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
read(3, "", 4096) = 0
close(3) = 0
munmap(0xb765d000, 4096) = 0
stat64("/lib", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
stat64("/usr/lib", {st_mode=S_IFDIR|0755, st_size=139264, ...}) = 0
open("/var/cache/ldconfig/aux-cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0600, st_size=60726, ...}) = 0
mmap2(NULL, 60726, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb764f000
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++
Segmentation fault
Comment by Jan de Groot (JGC) - Saturday, 07 November 2009, 17:29 GMT
I think your /var/cache/ldconfig/aux-cache file is corrupted. ldconfig mmaps this cache file, so if it's corrupted, it's not unlikely segfaults will happen. Try to remove it.
Comment by Babets (Babets) - Saturday, 07 November 2009, 17:36 GMT
Ok, thank you, removing aux-cache solved the problem. You can close this bug report.

Loading...