Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 493912 - =net-libs/libtirpc-0.2.4 breaks kerberos nfs mounts - rpc.gssd: segfault at ? in libgssapi_krb5.so.2.2
Summary: =net-libs/libtirpc-0.2.4 breaks kerberos nfs mounts - rpc.gssd: segfault at ?...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Network Filesystems
URL:
Whiteboard:
Keywords:
: 499888 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-12-11 07:12 UTC by Torsten Kaiser
Modified: 2014-02-04 18:39 UTC (History)
4 users (show)

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 Torsten Kaiser 2013-12-11 07:12:32 UTC
After upgrade from 0.2.3 to 0.2.4 on the next boot I got this:
Dec 11 07:40:31 thoregon kernel: [   51.538495] rpc.gssd[3127]: segfault at f7 ip 00007f4c8f740532 sp 00007ffffbeaeab0 error 4 in libgssapi_krb5.so.2.2[7f4c8f72a000+4b000]

That meant the nfs share could not be mounted, which is especially bad, because my /usr/portage is there.

Because of bug #479982 I suspected nfs-utils first, but replacing its executables with older versions did not help. I then checked emerge.log and found that libtirpc was upgraded yesterday.

After restoring the newer nfs-utils, but replacing /lib64/libtirpc.so.1.0.10 with the version from 0.2.3 the share now mounts again.

# emerge --info libtirpc
Portage 2.2.7 (default/linux/amd64/13.0, gcc-4.8.2, glibc-2.17, 3.13.0-rc2 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-3.13.0-rc2-x86_64-AMD_Phenom-tm-_II_X6_1090T_Processor-with-gentoo-2.2
KiB Mem:    12281488 total,  10751256 free
KiB Swap:   25165756 total,  25165756 free
Timestamp of tree: Tue, 10 Dec 2013 18:00:01 +0000
ld GNU ld (GNU Binutils) 2.23.2
app-shells/bash:          4.2_p45
dev-java/java-config:     2.2.0::java
dev-lang/python:          2.7.6, 3.3.3
dev-util/cmake:           2.8.12.1-r1
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.12.4
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.11.6, 1.12.6, 1.14
sys-devel/binutils:       2.23.2
sys-devel/gcc:            4.7.3-r1, 4.8.2
sys-devel/gcc-config:     1.8
sys-devel/libtool:        2.4.2
sys-devel/make:           4.0
sys-kernel/linux-headers: 3.12 (virtual/os-headers)
sys-libs/glibc:           2.17
Repositories: gentoo x11 sunrise java mozilla local
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-pipe -march=amdfam10 -O3 -fomit-frame-pointer -flto -fivopts -fweb -frename-registers -ftracer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /var/bind /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.5/ext-active/ /etc/php/cgi-php5.5/ext-active/ /etc/php/cli-php5.5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-pipe -march=amdfam10 -O3 -fomit-frame-pointer -flto -fivopts -fweb -frename-registers -ftracer"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps y --jobs=6 --load-average=7 --keep-going"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs buildpkg config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_GB.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j6"
PKGDIR="/var/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage-local/layman/x11 /usr/portage-local/layman/sunrise /usr/portage-local/layman/java /usr/portage-local/layman/mozilla /root/ebuilds"
USE="3dnow 3dnowext 7zip S3TC X a52 aac aalib ace acl acpi ads aften aio alisp alsa altenburgcards amarok amd64 amr amrnb amrr amrwb animgif ao apache2 apng aqua_theme archive async audacious audiofile autoipd avahi bcel bcp bdf beagle berkdb bigpatch binfilter bittorrent bl blas blender-game bluetooth bonusscripts boost bzip2 c++ cairo calendar caps carbone_theme cblas-external cdda cdio cdparanoia cdr cgi chm chroot cifsupcall cisco clang cli clucene cmdctrl cmdsubmenu compress connectionstatus consolekit contactnotes corefonts cpio cpufreq cracklib crypt cryptsetup cscope css ctype cups curl cutterlimit cutterqueue cuttime cvs cvsgraph cxx dar64 dbase dbm dbus dbx dc1394 declarative demo device-mapper divx djvu dlz dmi dmx dnotify doc domainkeys dot double-precision dpmod dri dts dv dvb dvbplayer dvd dvdarchive dvdchapjump dvdr dvdread dvi ecc editor egl elf emoticon encode enscript equalizer excel exif exiv2 expat extensions extra extra-algorithms extra-cardsets extraengine extras fam fat fbcon fdt festival ffmpeg fftw file file-icons flac fluidsynth fmod font-server fontconfig fortran fping fpx ftp fts3 fuse g3dvl gbm gcj gd gdbm gecko geoip gflags gif gimp git gkrellm glade glamor gles gles1 gles2 glib glibc-omitfp glitz glsa glut gmedia gmp gnutls gopher gpac gpg gpgme gphoto2 graphics graphite graphviz gs gstreamer gtk gtk3 gudev gutenprint gzip hddtemp hdri highlight history html htmlhandbook http httpd hvm hwdb ical iceweasel iconv icq icu id3 id3tag ide idea ieee1394 image imagemagick imap infowidget inherit-graph inkjar innodb inotify ipfilter ipsec iptc ipv6 irc irrlicht ithreads jabber jack jad jadetex java java-external java6 jce jingle jit jni john jpeg jpeg2k juju jumpplay kde kdecards kdepim kerberos kexi kipi kmid kpathsea ktts kvm latex lcms ldap libcaca libkms libmpeg2 libmysqlclient libnotify libsamplerate libsexy libssh2 libvisual libwww liemikuutio lights lirc lircsettings livebuffer llvm llvm-shared-libs lm_sensors logrotate logviewer loop-playback lto lua lucene lyx lzma lzo mad magic mail mailwrapper mainmenuhooks maps masquerade math matroska maya-shaderlibrary mbox mbrola md5sum mdev mdnsresponder-compat meanwhile menu-plugin menubar menuorg metric mhash midi mikmod mime mimencode minizip mixer mjpeg mmap mmx mmxext mng mod modplug modules mounts-check mozdevelop mozdom mozilla mp2 mp3 mp4 mp4live mpd mpeg mpeg2 mpg123 mplayer mppe-mppc mpu401 mschap msn mtp mudflap multilib multiprocess musepack music mysql mysqli mythtv nagios-dns nagios-ntp nagios-ping nagios-ssh nat ncurses net netjack netmeeting network network-cron networkmanager nfs nfsidmap nfsv4 nfsv41 nls nntp normalize nova nptl nsplugin nspr nss ntfs ntfsprogs nuv offensive ogg ogg123 ole opcache opencl openexr opengl openmp openssh openssl openvg openvpn opus osmesa pam pango pascal pcap pcre pda pdf pdfimport perl php physfs pixmaps pkcs11 plasma player pmu png policykit portaudio posix postfix postscript povray pptp pth pulseaudio python qemu qt3support qt4 query-browser quicktime r600-llvm-compiler radio rar raw rc5 rdesktop readline realmedia remix replaygain restrict-javascript rle rpc rss rtc rtmp rtsp samba sasl sbig scanner screen script sdk sdl sdl-image sdl-sound sdlaudio seamonkey search secure-delete semantic-desktop sensord server session shared-dricore shorten shout sid signatures simplexml skins smime smp smtp sndfile sockets socks5 solver songs sortrecords sound soundex sounds sox speech speedo speex spell spice sql sqlite sqlite3 sse sse2 sse3 sse4a ssl stars stats stemmer stlport stream submenu subtitles subversion suhosin svg svgz swat sylpheed sysfs syslog system-cairo system-icu system-jpeg system-libvncserver system-sqlite systray sysvipc szip t1lib taglib tagwriting tb4 tcpd teletext tetex tex texteffect textures tftp tga themes theora thesaurus threads threadsafe tidy tiff timercmd timerinfo tk tls toolbar tools transcode trayicon truetype tta ttxtsubs twolame udev ui unicode unlock-notify upcall usb usbredir userfiles utils uudeview uuencode v4l v4l2 vaapi vamp vcd vcdx vdpau vdr video videos vim-syntax visualization vlm vnc vncviewer voice volctrl vorbis vorbis-psy vpx wav wavpack wayland web webdav webinterface webkit webm webp wifi winbind winpopup wireshark wma wmf wmp wxwidgets x264 xa xanim xcb xcf xcomposite xext xface xforms xfs xft xhtml xine xinerama xlib-xcb xml xmp xorg xosd xplanet xpm xrandr xrender xscreensaver xsl xslt xspice xv xvfb xvid xvmc xvnc yahoo yv12 zip zlib zrtp zvbi" ABI_X86="32 64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd 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 cgid 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" APACHE2_MPMS="worker" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CURL_SSL="nss" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="de en" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" QEMU_SOFTMMU_TARGETS="x86_64 alpha arm i386 m68k mips mips64 mips64el mipsel ppc ppc64 ppcemb s390x sparc sparc64" RUBY_TARGETS="ruby20" USERLAND="GNU" VIDEO_CARDS="dummy fbdev v4l vesa radeon r600" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, SYNC, USE_PYTHON

=================================================================
                        Package Settings
=================================================================

net-libs/libtirpc-0.2.4 was built with the following:
USE="ipv6 kerberos (multilib) -static-libs" ABI_X86="64" ELIBC="glibc" KERNEL="linux" USERLAND="GNU"
Comment 1 Torsten Kaiser 2013-12-11 20:35:26 UTC
Some experiments:
* recompiling net-fs/nfsutils after the upgrade did not help
* removing -flto from CFLAGS did not help
* dropping to CFLAGS="-O2 -pipe" and recompiling libtirpc and nfs-utils did not help
* downgrading to =libtirpc-0.2.3 even with -flto works. (Although nfs-utils fails to compile with -flto, but thats my own fault for playing with -flto...)

The following commits from the 0.2.4 changelog look like they might be related, because I saw a similar looking segfault because libgssglue problems in nfs-utils (see bug #479982):

commit b5209d95d362b4c66184463ec14b2d8a6f3bcd0b
Author: Steve Dickson <[spam snip]>
Date:   Mon Dec 9 14:57:13 2013 -0500

    configure.ac: Remove gssglue configuration knobs
    
    Its really not a good idea for libtirpc to link with
    libgssglue so this patch remove the ability to do that.
    
    Signed-off-by: Steve Dickson <[spam snip]>


commit 9151a39539145e1f62f8b30168d1cdeb19299dac
Author: Simo Sorce <[spam snip]>
Date:   Tue Mar 26 11:13:05 2013 -0400

    Switch to use standard GSSAPI by default
    
    Make libgssglue configurable still but disabled by default.
    There is no reason to use libgssglue anymore, and modern gssapi
    supports all needed features for libtirpc and its dependencies.
    
    Signed-off-by: Steve Dickson <[spam snip]>
Comment 2 Torsten Kaiser 2013-12-14 13:23:03 UTC
OK, the trouble seems to be that either both or none of nfs-utils and libtirpc needs to be build agains libgssglue.

Both with libgssglue:
nfs-utils-1.2.8-r2/1.2.9 and libtirpc-0.2.3 -> works

Only libtirpc:
nfs-utils-1.2.8-r1 broke rpc.gssd: See bug #479982 and bug #480382
(At that point I was using the then current libtirpc-0.2.3)

Only nfs-utils:
libtirpc-0.2.4 now broke rpc.gssd again: this bug.

Neither:
Using the new libgssglue-less libtirpc-0.2.4 and the older nfs-utils-1.2.8-r1 that do not include the fix für #479982 works for me.

Looking at the upstream commits in my last comment, it seems that upstream libtirpc has completely removed the option for libgssglue. So for me it looks like the best way would be to revert #479982 and adjust the dependency of nfs-utils: <nfs-utils-1.2.8 with libgssglue should DEPEND on <libtirpc-0.2.4 and the later libgssglue-less nfs-utils should DEPEND on >=libtirpc-0.2.4. (And both ebuilds then could drop the DEPEND on libgssglue...)
Comment 3 Torsten Kaiser 2014-01-01 19:38:50 UTC
Retesting with nfs-utils-1.2.9-r1:
kernel: [126983.733696] rpc.gssd[4525]: segfault at e1b000 ip 00007f79ed16550c sp 00007ffffdb7cb70 error 4 in libgssapi_krb5.so.2.2[7f79ed14f000+4b000]

Using the following change nfs-utils-1.2.9-r1 work for me:

--- a/net-fs/nfs-utils/nfs-utils-1.2.9-r1.ebuild 2013-12-22 10:50:02.000000000 +0100
+++ b/net-fs/nfs-utils/nfs-utils-1.2.9-r1.ebuild 2014-01-01 20:33:58.174738399 +0100
@@ -32,8 +32,7 @@
                >=net-libs/libnfsidmap-0.21-r1
                kerberos? (
                        net-libs/librpcsecgss
-                       >=net-libs/libgssglue-0.3
-                       net-libs/libtirpc[kerberos]
+                       >=net-libs/libtirpc-0.2.4[kerberos]
                        app-crypt/mit-krb5
                )
                nfsidmap? (
@@ -74,7 +73,7 @@
                $(use_enable caps) \
                $(use_enable uuid) \
                $(usex nfsv4 "$(use_enable kerberos gss)" "--disable-gss") \
-               $(usex nfsv4 "$(use_with kerberos gssglue)" "--without-gssglue")
+               --without-gssglue
 }
 
 src_compile(){

(I have removed libgssglue unconditionally, because libtirpc-upstream removed that option completely in 0.2.4)
Comment 4 Johan Ymerson 2014-01-30 11:42:26 UTC
Yes, libtirpc and nfs-utils must be built without the obsolete gssglue to work. Even with the currently stable libtirpc-0.2.2-r1 we experience svcgssd and gssd crashes (segfaults) caused by bugs in the old gssglue code.

Also, the dependency on net-libs/librpcsecgss should probably be removed from both libtirpc and nfs-utils, as they don't really seem to be using it.
Comment 5 SpanKY gentoo-dev 2014-02-02 07:58:59 UTC
*** Bug 499888 has been marked as a duplicate of this bug. ***
Comment 6 SpanKY gentoo-dev 2014-02-02 08:00:02 UTC
Commit message: Depend on virtual/krb5 for USE=kerberos rather than gssglue
http://sources.gentoo.org/net-libs/libtirpc/libtirpc-0.2.4-r1.ebuild?rev=1.1
Comment 7 SpanKY gentoo-dev 2014-02-02 08:12:05 UTC
should be all set now in the tree; thanks for the report!

Commit message: Drop gssglue support as libtirpc itself no longer supports it
http://sources.gentoo.org/net-fs/nfs-utils/nfs-utils-1.2.9-r3.ebuild?rev=1.1
Comment 8 Joakim Tjernlund 2014-02-02 12:29:29 UTC
nfs-utils still depends on net-libs/librpcsecgss. Is this really needed or
just forgotten?

We are using the git version of nfs-utils(http://git.linux-nfs.org/?p=steved/nfs-utils.git;a=summary) as current 1.2.9 has some bugs we experince.
The dependency for net-libs/librpcsecgss is not needed in this case
Comment 9 Torsten Kaiser 2014-02-02 21:37:51 UTC
net-fs/nfs-utils-1.2.9-r3 seem to work for me. Thanks!

Wrt. net-libs/librpcsecgss: nfs-utils is the only packages on my system that pulls this in. But when I use revdev-rebuild to search for users of librpcsecgss.so /.so.3 / .so.3.0.0 nothing was found. That looks like its no longer needed...

Hmmmh:
Feb  2 22:23:02 thoregon kernel: [187000.542878] rpcbind[7929]: segfault at 28 ip 00007fe052a04061 sp 00007fff946fa390 error 4 in libtirpc.so.1.0.10[7fe0529ea000+28000]

Now rpcbind segfaults, but everything seems to work. I'm using NFSv4 so the portmapper seems (partly?) optional.
If I find out, what happens there, I will file a new bug...
Comment 10 SpanKY gentoo-dev 2014-02-03 14:30:29 UTC
Commit message: Drop librpcsecgss dep as it is not used when libtirpc is utilized (which we do)
http://sources.gentoo.org/net-fs/nfs-utils/nfs-utils-1.2.9-r3.ebuild?r1=1.1&r2=1.2
Comment 11 Torsten Kaiser 2014-02-04 18:39:07 UTC
rpcbind segfaults disapeared after a reemerge of that package.
I don't know what fixed it, but -flto might be to blame. So I will put these segfaults under "user error". ;-)