Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 201954 - dev-libs/libgcrypt-1.4.0 makes things segfault
Summary: dev-libs/libgcrypt-1.4.0 makes things segfault
Status: RESOLVED DUPLICATE of bug 201917
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High major (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-12-11 16:08 UTC by Andrei Ivanov
Modified: 2007-12-15 09:05 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrei Ivanov 2007-12-11 16:08:21 UTC
After I've upgraded glibc to 2.7-r1 and samba to 3.0.28, smbd segfaults
I've downgraded samba to 3.0.27a, but it segfaults too...
I've re-emerged glibc using USE="debug -glibc-omitfp", to see if I can get a trace from the dumped core by smbd, but nothing:

gdb /usr/sbin/smbd core
GNU gdb 6.7.1
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu"...
(no debugging symbols found)
Using host libthread_db library "/lib/libthread_db.so.1".
(no debugging symbols found)
(no debugging symbols found)
Core was generated by `/usr/sbin/smbd -D'.
Program terminated with signal 6, Aborted.
#0  0xb7eee410 in ?? () from /lib/ld-linux.so.2
(gdb) bt
#0  0xb7eee410 in ?? () from /lib/ld-linux.so.2
#1  0xb7b88c55 in ?? ()
#2  0xb7c8fff4 in ?? ()
#3  0xbfb71a7c in ?? ()
#4  0xb79ca6c0 in ?? ()
#5  0xbfb71b08 in ?? ()
#6  0xb7b8a461 in ?? ()
#7  0x00000006 in ?? ()
#8  0xbfb71a7c in ?? ()
#9  0x00000000 in ?? ()

As far as I see, samba doesn't have a debug use flag...
So I tried to downgrade glibc back to 2.7, but I can't:

i686-pc-linux-gnu-gcc ../sysdeps/i386/i386-mcount.S -c  -I../include -I/var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon -I/var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl -I../sysdeps/i386/elf -I../nptl/sysdeps/unix/sysv/linux/i386/i686 -I../nptl/sysdeps/unix/sysv/linux/i386 -I../sysdeps/unix/sysv/linux/i386 -I../nptl/sysdeps/unix/sysv/linux -I../nptl/sysdeps/pthread -I../sysdeps/pthread -I../ports/sysdeps/unix/sysv/linux -I../sysdeps/unix/sysv/linux -I../sysdeps/gnu -I../sysdeps/unix/common -I../sysdeps/unix/mman -I../sysdeps/unix/inet -I../ports/sysdeps/unix/sysv/i386 -I../sysdeps/unix/sysv/i386 -I../nptl/sysdeps/unix/sysv -I../ports/sysdeps/unix/sysv -I../sysdeps/unix/sysv -I../sysdeps/unix/i386 -I../nptl/sysdeps/unix -I../ports/sysdeps/unix -I../sysdeps/unix -I../sysdeps/posix -I../sysdeps/i386/i686/fpu -I../nptl/sysdeps/i386/i686 -I../sysdeps/i386/i686 -I../sysdeps/i386/i486 -I../nptl/sysdeps/i386/i486 -I../sysdeps/i386/fpu -I../nptl/sysdeps/i386 -I../sysdeps/i386 -I../sysdeps/wordsize-32 -I../sysdeps/ieee754/ldbl-96 -I../sysdeps/ieee754/dbl-64 -I../sysdeps/ieee754/flt-32 -I../sysdeps/ieee754 -I../sysdeps/generic/elf -I../sysdeps/generic -I../nptl -I../ports  -I.. -I../libio -I. -nostdinc -isystem /usr/lib/gcc/i686-pc-linux-gnu/4.2.2/include -isystem /usr/lib/gcc/i686-pc-linux-gnu/4.2.2/include-fixed -isystem /usr/include -D_LIBC_REENTRANT -include ../include/libc-symbols.h        -DASSEMBLER  -DGAS_SYNTAX  -Wa,--noexecstack -Wa,--noexecstack  -o /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/i386-mcount.og -MD -MP -MF /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/i386-mcount.og.dt -MT /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/i386-mcount.og
.././scripts/mkinstalldirs /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon
echo 'gmon/gmon.og gmon/mcount.og gmon/profil.og gmon/sprofil.og gmon/bb_init_func.og gmon/bb_exit_func.og gmon/prof-freq.og gmon/i386-mcount.og' > /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/stamp.ogT
mv -f /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/stamp.ogT /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/stamp.og
.././scripts/mkinstalldirs /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon
echo '' > /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/stamp.oST
mv -f /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/stamp.oST /var/tmp/portage/sys-libs/glibc-2.7/work/build-default-i686-pc-linux-gnu-nptl/gmon/stamp.oS
make[2]: Leaving directory `/var/tmp/portage/sys-libs/glibc-2.7/work/glibc-2.7/gmon'
make  subdir=gnulib -C gnulib ..=../ subdir_lib
make[2]: Entering directory `/var/tmp/portage/sys-libs/glibc-2.7/work/glibc-2.7/gnulib'
make[1]: *** [gnulib/subdir_lib] Segmentation fault
make[1]: Leaving directory `/var/tmp/portage/sys-libs/glibc-2.7/work/glibc-2.7'
make: *** [all] Error 2
 *
 * ERROR: sys-libs/glibc-2.7 failed.
 * Call stack:
 *               ebuild.sh, line   46:  Called src_compile
 *             environment, line 3301:  Called eblit-run 'src_compile'
 *             environment, line 1058:  Called eblit-glibc-src_compile
 *       src_compile.eblit, line  179:  Called toolchain-glibc_src_compile
 *       src_compile.eblit, line  122:  Called die
 * The specific snippet of code:
 *              make PARALLELMFLAGS="${MAKEOPTS}" || die "make for ${ABI} failed"
 *  The die message:
 *   make for default failed
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/sys-libs/glibc-2.7/temp/
 * The ebuild environment file is located at '/var/tmp/portage/sys-libs/glibc-2.
 *

 * Messages for package sys-libs/glibc-2.7:

 *
 * ERROR: sys-libs/glibc-2.7 failed.
 * Call stack:
 *               ebuild.sh, line   46:  Called src_compile
 *             environment, line 3301:  Called eblit-run 'src_compile'
 *             environment, line 1058:  Called eblit-glibc-src_compile
 *       src_compile.eblit, line  179:  Called toolchain-glibc_src_compile
 *       src_compile.eblit, line  122:  Called die
 * The specific snippet of code:
 *              make PARALLELMFLAGS="${MAKEOPTS}" || die "make for ${ABI} failed
 *  The die message:
 *   make for default failed


emerge --info
Portage 2.1.4_rc9 (default-linux/x86/2007.0, gcc-4.2.2, glibc-2.7-r1, 2.6.23-gentoo-r3 i686)
=================================================================
System uname: 2.6.23-gentoo-r3 i686 Intel(R) Celeron(R) CPU 2.93GHz
Timestamp of tree: Tue, 11 Dec 2007 11:16:01 +0000
app-shells/bash:     3.2_p17-r1
dev-java/java-config: 1.3.7, 2.1.3
dev-lang/python:     2.4.4-r4, 2.5.1-r4
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.10-r5
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r1
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.24
virtual/os-headers:  2.6.23-r2
ACCEPT_KEYWORDS="x86 ~x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=prescott -O3 -pipe -fomit-frame-pointer -mfpmath=sse"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /opt/openjms/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=prescott -O3 -pipe -fomit-frame-pointer -mfpmath=sse"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps y"
FEATURES="autoconfig distlocks metadata-transfer parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="ftp://ftp.roedu.net/pub/mirrors/gentoo.org"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="aalib acl acpi adns alsa apache2 bitmap-fonts bzip2 cairo caps cli cracklib crypt cups curl curlwrappers dio exif expat flac fortran ftp gd gmp gpm iconv idn imagemagick imap isdnlog ldap mad maildir mailwrapper memlimit mhash midi mmap mmx mono mudflap ncurses network-cron nptl nptlonly offensive oggvorbis openmp pam pcntl pcre posix pppd readline reflection samba session shared sharedmem soap sockets speex spl sse sse2 ssl svg sysvipc tcpd theora tiff truetype-fonts type1-fonts unicode urandom usb vhosts vim-syntax wmf x86 xattr xml xmlrpc xorg zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="apm ark chips cirrus cyrix dummy fbdev glint i128 i740 i810 imstt mach64 mga neomagic nsc nv r128 radeon rendition s3 s3virge savage siliconmotion sis sisusb tdfx tga trident tseng v4l vesa vga via vmware voodoo"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, MAKEOPTS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-12-11 21:48:36 UTC
Reopen with a useful backtrace, thanks.

http://www.gentoo.org/proj/en/qa/backtraces.xml
Comment 2 Andrei Ivanov 2007-12-12 11:18:54 UTC
After reading the guide for obtaining backtraces, I've set the nostrip feature and recompiled glibc(it says that glibc doesn't like -ggdb) and samba(with -march=prescott -O2 -pipe -ggdb)... but I still don't see any more info than before.

/lib/libc-2.7.so: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), for GNU/Linux 2.6.9, not stripped
/usr/sbin/smbd: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), for GNU/Linux 2.6.9, not stripped
/lib/libthread_db-1.0.so: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), for GNU/Linux 2.6.9, not stripped

All of them are not stripped...

What should I do?
Comment 3 Andrei Ivanov 2007-12-13 08:38:16 UTC
Any ideeas, please?
Comment 4 Andrei Ivanov 2007-12-13 14:29:22 UTC
Additional info needed from devs...
Comment 5 Jakub Moc (RETIRED) gentoo-dev 2007-12-13 14:45:02 UTC
What info do you need? Read the howto, recompile samba and its deps and attach a useful backtrace. We can't do anything until then.
Comment 6 Andrei Ivanov 2007-12-13 15:18:43 UTC
Please, read comment #2
Comment 7 Andrei Ivanov 2007-12-14 12:00:23 UTC
I found this in log.smbd:

lib/util.c:log_stack_trace(1737)
  BACKTRACE: 11 stack frames:
   #0 /usr/sbin/smbd(log_stack_trace+0x2d) [0x8022546b]
   #1 /usr/sbin/smbd(smb_panic+0x57) [0x80225583]
   #2 /usr/sbin/smbd [0x8021155e]
   #3 [0xb7f3e420]
   #4 /usr/sbin/smbd(cups_cache_reload+0x38) [0x8020217d]
   #5 /usr/sbin/smbd(pcap_cache_reload+0x147) [0x801ff608]
   #6 /usr/sbin/smbd(reload_printers+0x31) [0x802dee10]
   #7 /usr/sbin/smbd(reload_services+0xc2) [0x802defed]
   #8 /usr/sbin/smbd(main+0x4d6) [0x802e0406]
   #9 /lib/libc.so.6(__libc_start_main+0xe0) [0xb7bc5400]
   #10 /usr/sbin/smbd [0x800516e1]

Also, please read comment #2
Comment 8 Andrei Ivanov 2007-12-14 12:01:20 UTC
downgrading glibc failed because of
make[5952]: segfault at 65200150 eip 080525c3 esp bfaade30 error 4
Comment 9 Jakub Moc (RETIRED) gentoo-dev 2007-12-14 12:03:24 UTC
Well
- you can't downgrade glibc. 
- if make and other things randomly segfault on your system, go check your HW.


*** This bug has been marked as a duplicate of bug 20600 ***
Comment 10 Andrei Ivanov 2007-12-14 12:07:53 UTC
So.. it's just a coincidence that everything started failing after upgrading glibc?
Comment 11 Andrei Ivanov 2007-12-15 08:58:07 UTC
The solution was provided here: http://forums.gentoo.org/viewtopic.php?p=4618757#4618757

Btw, I've ran memtest86+ for almost for hours and cpuburn for almost 12 hours and no errors were reported.

After re-emerging libgcrypt, everything was fine.
The question is, why were samba and cups segfaulting after upgrading glibc?
Comment 12 Jakub Moc (RETIRED) gentoo-dev 2007-12-15 09:05:48 UTC

*** This bug has been marked as a duplicate of bug 201917 ***