Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 74555 - glibc-2.3.4.20041102 causes some apps to segfault when using NIS
Summary: glibc-2.3.4.20041102 causes some apps to segfault when using NIS
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High critical
Assignee: Gentoo Toolchain Maintainers
URL: http://forums.gentoo.org/viewtopic.ph...
Whiteboard:
Keywords:
: 81357 83318 86989 87112 89732 93708 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-12-15 14:34 UTC by A.J. Aranyosi
Modified: 2005-05-23 23:06 UTC (History)
8 users (show)

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


Attachments
strace of a segfaulting ls (ls.out,9.07 KB, text/plain)
2004-12-28 02:19 UTC, E. Papegaaij
Details
Last ebuild that still works (glibc-2.3.4.20041021.ebuild,26.17 KB, text/plain)
2005-02-05 11:51 UTC, A.J. Aranyosi
Details
hppa patches for glibc-2.3.4.20041021 ebuild (glibc-hppa-patches-2004-09-30.tar.gz,16.02 KB, application/octet-stream)
2005-02-05 11:52 UTC, A.J. Aranyosi
Details

Note You need to log in before you can comment on or make changes to this bug.
Description A.J. Aranyosi 2004-12-15 14:34:10 UTC
After upgrading to glibc-2.3.4.20041102, some apps (e.g. tar) started segfaulting, but not consistently (e.g., tar tf file.tar always works, while tar xf file.tar works sometimes but usually segfaults immediately).  I did an strace and found it was failing on libnss_nis lookups.  Edited /etc/nsswitch.conf and changed the passwd, shadow, and group entries from "files nis" to "compat", and tar worked again.  Then edited /etc/passwd, /etc/shadow, and /etc/group to add "+" at the end of each file (which causes compat to do NIS lookups), and tar segfaulted again.  Also, tar works if ypbind is not started for some reason (e.g., if /etc/conf.d/domainname is not configured properly).

Of course, having tar not work makes it a little difficult to emerge, so this bug is pretty unpleasant.


Reproducible: Always
Steps to Reproduce:
1. upgrade to glibc-2.3.4.20041102 (using gcc-3.4.3-r1).
2. edit /etc/nsswitch.conf to change "compat" to "files nis" for the passwd, shadow, and group entries.
3. set up an NIS server and add the proper entries in /etc/conf.d/domainname and /etc/conf.d/ypbind for it.
4. start ypbind.
5. try to untar something.

Actual Results:  
tar segfaulted.

Expected Results:  
untarred the file.

CFLAGS="-O2 -march=pentium4 -pipe -fomit-frame-pointer" when building glibc
(I've changed them somewhat for the rebuild, so emerge info gives different
information).

emerge info output:

Portage 2.0.51-r8 (default-linux/x86/2004.0, gcc-3.4.3, glibc-2.3.4.20041102-r0,
2.6.9-rc1-mm5 i686)
=================================================================
System uname: 2.6.9-rc1-mm5 i686 Intel(R) Pentium(R) 4 CPU 2.80GHz
Gentoo Base System version 1.6.7
Python:              dev-lang/python-2.2.3-r5,dev-lang/python-2.3.4 [2.3.4 (#1,
Sep 27 2004, 14:29:55)]
distcc 2.14 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
dev-lang/python:     2.2.3-r5, 2.3.4
sys-devel/autoconf:  2.59-r6, 2.13
sys-devel/automake:  1.8.5-r2, 1.5, 1.4_p6, 1.6.3, 1.7.9, 1.9.3
sys-devel/binutils:  2.15.92.0.2-r1
sys-devel/libtool:   1.5.2-r7
virtual/os-headers:  2.6.8.1-r1
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=pentium4 -mtune=pentium4 -fforce-addr
-momit-leaf-frame-pointer -fomit-frame-pointer -frename-registers -fweb -ftracer
-pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.1/share/config /usr/kde/3.2/share/config /usr/kde/3.3/env
/usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config
/usr/lib/mozilla/defaults/pref /usr/share/config
/usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/
/usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/
/usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=pentium4 -mtune=pentium4 -fforce-addr
-momit-leaf-frame-pointer -fomit-frame-pointer -frename-registers -fweb -ftracer
-pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="http://mirror.datapipe.net/gentoo ftp://gentoo.mirrors.pair.com/
http://gentoo.chem.wisc.edu/gentoo/ http://gentoo.seren.com/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="X aalib alsa apm arts avi berkdb bitmap-fonts bonobo cdr cjk crypt cscope
cups dga directfb dvd encode esd evo f77 fam fbcon flac flash foomaticdb fortran
gb gd gdbm ggi ggz gif gimpprint gnome gphoto2 gpm gstreamer gtk gtk2 gtkhtml
guileimagemagick imap imlib innodb ipv6 java jikes jpeg junit kde kerberos lcms
ldap leim libg++ libgda libwww mad mbox mikmodmmx motif mozilla mpeg mule mysql
nas ncurses nls nptl odbc oggvorbis opengl oss pam pda pdflib perl pic plotutils
png postgres python qt qtmt quicktime readline ruby samba sasl scanner sdl slang
slp snmp socks5 speex spell sse ssl svga tcltk tcpd tetex tiff truetype wmf x86
xml xml2 xmms xv zeo zlib"
Comment 1 E. Papegaaij 2004-12-19 12:52:48 UTC
I can confirm this bug, but on amd64, and here it's not just tar, but almost everything that has to do with users, that is affected. I can no longer login as a normal user, ls -la segfaults, and other apps also segfault. When I stop ypbind, apps no longer segfault.
Comment 2 rob holland (RETIRED) gentoo-dev 2004-12-23 07:38:42 UTC
please attached the output of an strace
Comment 3 E. Papegaaij 2004-12-28 02:19:24 UTC
Created attachment 47019 [details]
strace of a segfaulting ls

Here is a strace of ls segfaulting with glibc-2.3.4.20041102 and nis.
Comment 4 Scott Price 2005-02-03 14:08:54 UTC
I am getting the same thing with the same symptoms.  If you need anything from me let me know.

bash-2.05b# emerge --info
Portage 2.0.51-r15 (default-linux/amd64/2004.3, gcc-3.4.3, glibc-2.3.4.20041102-r0, 2.6.10 x86_64)
=================================================================
System uname: 2.6.10 x86_64 AMD Athlon(tm) 64 Processor 3500+
Gentoo Base System version 1.4.16
Python:              dev-lang/python-2.3.4 [2.3.4 (#1, Jan 28 2005, 18:39:19)]
dev-lang/python:     2.3.4
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.5, 1.6.3, 1.7.9-r1, 1.4_p6, 1.9.4, 1.8.5-r3
sys-devel/binutils:  2.15.92.0.2-r1
sys-devel/libtool:   1.5.10-r4
virtual/os-headers:  2.6.8.1-r2
ACCEPT_KEYWORDS="amd64"
AUTOCLEAN="yes"
CFLAGS="-march=athlon64 -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=x86-64 -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/packages/amd64"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="amd64 X acpi alsa avi berkdb bitmap-fonts bonobo bootsplash ccache cddb cdparanoia cdr clamav crypt cups curl dga directfb divx4linux dnd dvd dvdr dvdread esd exif f77 fam font-server fortran gif gimp gimpprint gnome gphoto2 gpm gtk gtk2 gtkhtml guile ieee1394 imagemagick imlib ipv6 java jp2 jpeg kde libclamav libwww lzw lzw-tiff mbox mhash mozilla mpeg multilib mysql ncurses nis nls nocardbus nocd nowin nvidia offensive opengl oss pam pcntl perl php png python qt quicktime readline samba scanner sdl session sockets ssl tcpd threads tiff truetype truetype-fonts type1-fonts usb userlocales v4l v4l2 xinerama xml xml2 xmms xosd xpm xrandr xv zlib"
Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS
Comment 5 E. Papegaaij 2005-02-03 14:26:45 UTC
I can confirm the bug is still present with the latest glibc version in portage (still 2.3.4.20041102, but the ebuild has changed substantially over time). This bug is also starting to prevent me from doing a normal system update. More and more packages do not compile with the old glibc.
Comment 6 A.J. Aranyosi 2005-02-05 11:51:17 UTC
Created attachment 50470 [details]
Last ebuild that still works

I've been using the glibc-2.3.4.20041021 ebuild, which seems to work fine with
the latest packages and still works with NIS.  It was in portage for a little
while, but for some reason was removed.  I've stuck it in /usr/local/portage as
an overlay, and added ">sys-libs/glibc-2.3.4.20041101" into package.mask. 
Here's the ebuild file for anyone who needs it.  It also requires the
glibc-hppa-patches-2004-09-30.tar.gz file, which for me did not download
automatically, so I'll add that as another attachment.
Comment 7 A.J. Aranyosi 2005-02-05 11:52:32 UTC
Created attachment 50471 [details]
hppa patches for glibc-2.3.4.20041021 ebuild

Here's the glibc-hppa-patches file that the glibc-2.3.4.20041021 ebuild
requires.
Comment 8 Jeremy Huddleston (RETIRED) gentoo-dev 2005-02-05 16:01:04 UTC
Ok, well that narrows down the window for when the bug was introduced, thanks...  but I'm HOPING it's fixed in cvs before the 2.3.4 release upstream.  I'm testing out the 2.3.4.20050125 version right now, and if you could help out, that'd be great (don't forget to quickpkg first)
Comment 9 Jeremy Huddleston (RETIRED) gentoo-dev 2005-02-06 04:41:24 UTC
Ok, this problem has gone away for me on sparc in 20050125, so marking fixed.
Comment 10 A.J. Aranyosi 2005-02-07 07:54:01 UTC
Seems to work for me on x86 as well.
Comment 11 E. Papegaaij 2005-02-07 10:06:40 UTC
Also fixed for the amd64
Comment 12 Jeremy Huddleston (RETIRED) gentoo-dev 2005-02-09 16:36:06 UTC
*** Bug 81357 has been marked as a duplicate of this bug. ***
Comment 13 Jeremy Huddleston (RETIRED) gentoo-dev 2005-03-10 04:53:20 UTC
*** Bug 83318 has been marked as a duplicate of this bug. ***
Comment 14 SpanKY gentoo-dev 2005-03-28 17:10:57 UTC
*** Bug 86989 has been marked as a duplicate of this bug. ***
Comment 15 SpanKY gentoo-dev 2005-03-30 06:18:35 UTC
*** Bug 87112 has been marked as a duplicate of this bug. ***
Comment 16 Jeremy Huddleston (RETIRED) gentoo-dev 2005-04-21 02:52:02 UTC
*** Bug 89732 has been marked as a duplicate of this bug. ***
Comment 17 Andreas Vinsander 2005-04-21 08:32:54 UTC
Which version of glibc works for stable amd64 (not ~amd64!) concerning NIS.
The latest stable one (glibc-2.3.4.20041102-r1, merged 20050329) is still showing this on multilib gentoo amd64 with NIS.
Comment 18 Jeremy Huddleston (RETIRED) gentoo-dev 2005-04-21 11:42:34 UTC
use 2.3.4.2005* or 2.3.5
Comment 19 SpanKY gentoo-dev 2005-05-23 16:14:56 UTC
*** Bug 93708 has been marked as a duplicate of this bug. ***