Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 533966 - net-misc/ntp-4.2.8: - ntpd: ./../lib/isc/unix/ifiter_getifaddrs.c:99: unexpected error: // getting interface addresses: getifaddrs: Resource temporarily unavailable
Summary: net-misc/ntp-4.2.8: - ntpd: ./../lib/isc/unix/ifiter_getifaddrs.c:99: unexpec...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Assignee: Gentoo's Team for Core System packages
URL: http://bugs.ntp.org/show_bug.cgi?id=2646
Whiteboard:
Keywords:
: 534158 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-12-29 19:44 UTC by andcycle-gentoo.bugs
Modified: 2015-04-08 21:13 UTC (History)
1 user (show)

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


Attachments
Proposed patch from bugs.ntp.org (ntpd_cap.patch,409 bytes, patch)
2015-03-04 09:22 UTC, Wouter Smeltekop
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description andcycle-gentoo.bugs 2014-12-29 19:44:45 UTC
just upgrade from 4.2.6_p5-r10 to 4.2.8-r1,
ntpd always crash after start,

error log

30 Dec 03:37:55 ntpd[28617]: ./../lib/isc/unix/ifiter_getifaddrs.c:99: unexpected error:
30 Dec 03:37:55 ntpd[28617]: getting interface addresses: getifaddrs: Resource temporarily unavailable
30 Dec 03:37:56 ntpd[28617]: fatal out of memory (4048 bytes)

my system have mix network interface configuration,
include bridge, vnet for libvirt/qemu, pppoe dial up, etc

below is emerge info

Portage 2.2.14 (python 2.7.9-final-0, default/linux/amd64/13.0, gcc-4.8.3, glibc-2.19-r1, 3.16.5-gentoo x86_64)
=================================================================
System uname: Linux-3.16.5-gentoo-x86_64-AMD_FX-tm-8350_Eight-Core_Processor-with-gentoo-2.2
KiB Mem:    32365428 total,   3211612 free
KiB Swap:   25165816 total,  23184500 free
Timestamp of tree: Fri, 26 Dec 2014 20:00:01 +0000
ld GNU ld (Gentoo 2.24 p1.4) 2.24
ccache version 3.1.9 [disabled]
app-shells/bash:          4.2_p53
dev-java/java-config:     2.2.0
dev-lang/perl:            5.18.2-r2
dev-lang/python:          2.7.9-r1, 3.3.5-r1
dev-util/ccache:          3.1.9-r4
dev-util/cmake:           2.8.12.2-r1
dev-util/pkgconfig:       0.28-r1
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.12.4
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.69
sys-devel/automake:       1.11.6-r1, 1.13.4
sys-devel/binutils:       2.24-r3
sys-devel/gcc:            4.8.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2-r1
sys-devel/make:           4.0-r1
sys-kernel/linux-headers: 3.16 (virtual/os-headers)
sys-libs/glibc:           2.19-r1
Repositories: gentoo x-portage sunrise
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA Oracle-BCLA-JavaSE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt /var/spool/munin-async/.ssh"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /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="-march=native -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs buildpkg cgroup clean-logs config-protect-if-modified distlocks downgrade-backup ebuild-locks fixlafiles ipc-sandbox merge-sync network-sand
box news parallel-fetch parallel-install preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-backup unmerge-logs unmerge-orphans userfetch userpriv
usersandbox usersync"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j8"
PKGDIR="/usr/portage/packages"
PORTAGE_COMPRESS="xz"
PORTAGE_COMPRESS_FLAGS="--fast"
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/local/portage /var/lib/layman/sunrise"
USE="3dnow 3dnowext acl amd64 avx avx2 bash-completion berkdb bzip2 caps cjk cli cracklib crypt cxx dri fam fftw fortran gdbm iconv ipv6 mmx mmxext modules multilib ncurses nls
nptl openmp pam pcre readline session sse sse2 sse3 sse4_1 ssl ssse3 tcpd unicode vim-syntax zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmip
ci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="actions alias auth_basic a
uth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs
dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy pro
xy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias reqtimeout" APACHE2_MPMS="worker" CALLIGRA_FEATURES="ke
xi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTO
COLS="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="keyboard mouse evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREO
FFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 pyth
on3_3" RUBY_TARGETS="ruby19" USERLAND="GNU" VIDEO_CARDS="fbdev vesa nouveau intel" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy cond
ition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
USE_PYTHON="2.7 3.3"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_RSYNC_EXTRA_OPTS, SYNC
Comment 1 Wouter Smeltekop 2015-03-04 09:20:21 UTC
I am suffering from this issue too, I have applied the proposed patch here:

[url]http://bugs.ntp.org/show_bug.cgi?id=2646[/url]

Will report back if this remains stable now.
Comment 2 Wouter Smeltekop 2015-03-04 09:22:47 UTC
Created attachment 398012 [details, diff]
Proposed patch from bugs.ntp.org

http://bugs.ntp.org/attachment.cgi?id=1132&action=diff
Comment 3 Wouter Smeltekop 2015-03-06 07:24:56 UTC
This is still up and running with the patch applied. Errors have gone from the ntp log. This behaviour was very consistent, start ntpd and it would serve the time for about 24 hours and then crash with the repeating error messages:

4 Mar 05:10:28 ntpd[27369]: ./../lib/isc/unix/ifiter_getifaddrs.c:99: unexpected error:
4 Mar 05:10:28 ntpd[27369]: getting interface addresses: getifaddrs: Resource temporarily unavailable

And then eventually:

4 Mar 05:40:28 ntpd[27369]: Too many errors.  Shutting up.
4 Mar 06:00:02 ntpd[27369]: fatal out of memory (4048 bytes)
4 Mar 06:00:02 ntpd[27369]: 0.0.0.0 061d 0d kern kernel time sync disabled

After applying the patch I no longer see the error messages.
Comment 4 andcycle-gentoo.bugs 2015-03-06 16:34:36 UTC
(In reply to Wouter Smeltekop from comment #3)

thanks for the patch, looks like that works out, 
just patched and testing now
Comment 5 Wouter Smeltekop 2015-03-10 11:48:31 UTC
Still up and running here..
Comment 6 SpanKY gentoo-dev 2015-04-08 20:46:46 UTC
*** Bug 534158 has been marked as a duplicate of this bug. ***
Comment 7 SpanKY gentoo-dev 2015-04-08 21:13:31 UTC
should be all set now in the tree; thanks for the report!

Commit message: Add patch from upstream for crashes in ntpd
http://sources.gentoo.org/net-misc/ntp/files/ntp-4.2.8-ipc-caps.patch?rev=1.1
http://sources.gentoo.org/net-misc/ntp/ntp-4.2.8_p2.ebuild?rev=1.1