Package: nis
Version: 3.16-2
Severity: normal
Tags: patch
When our NIS server becomes unavailable, all of our NIS clients die a few
minutes later. I strace()d one on a deliberate outage and found that it died
with SIGPIPE. Here's an extract from the strace output and a suggestion for a
patch. Other programs in the nis package seem to ignore SIGPIPE (in different
ways). I haven't contacted upstream.
accept(5, {sa_family=AF_INET, sin_port=htons(879),
sin_addr=inet_addr("127.0.0.1")}, [16]) = 7
...
poll([{fd=4, events=POLLIN|POLLPRI|POLLRDNORM|POLLRDBAND}, {fd=5,
events=POLLIN|POLLPRI|POLLRDNORM|POLLRDBAND, revents=POLLIN|POLLRDNORM}, {fd=7,
events=POLLIN|POLLPRI|POLLRDNORM|POLLRDBAND, revents=POLLIN|POLLRDNORM}, {fd=8,
events=POLLIN|POLLPRI|POLLRDNORM|POLLRDBAND,
revents=POLLIN|POLLRDNORM|POLLERR|POLLHUP}, {fd=-1}], 5, -1) = 3
accept(5, {sa_family=AF_INET, sin_port=htons(880),
sin_addr=inet_addr("127.0.0.1")}, [16]) = 9
poll([{fd=7, events=POLLIN, revents=POLLIN}], 1, 35000) = 1
read(7, "\200\0\0000%2\347\336\0\0\0\0\0\0\0\2\0\1\206\247\0\0\0"..., 4000) = 52
...
write(7, "\200\0\0 %2\347\336\0\0\0\1\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 36) = -1
EPIPE (Broken pipe)
--- SIGPIPE (Broken pipe) @ 0 (0) ---
--- /tmp/ypbind-mt.c.orig 2006-09-08 18:01:28.000000000 -0700
+++ /tmp/ypbind-mt.c.new 2006-09-08 18:14:22.000000000 -0700
@@ -457,6 +457,10 @@
if (ping_interval < 1)
do_binding ();
break;
+ case SIGPIPE:
+ if (debug_flag)
+ log_msg (LOG_DEBUG, _("Ignoring SIGPIPE."));
+ break;
default:
log_msg (LOG_ERR, _("Unknown signal: %d"), caught);
break;
@@ -679,6 +683,7 @@
sigaddset (&sigs_to_block, SIGQUIT);
sigaddset (&sigs_to_block, SIGSEGV);
sigaddset (&sigs_to_block, SIGHUP);
+ sigaddset (&sigs_to_block, SIGPIPE);
if (pthread_sigmask (SIG_BLOCK, &sigs_to_block, NULL) != 0)
{
log_msg (LOG_ERR, _("Could not block signals."));
-- Package-specific info:
NIS domain: uk
-- System Information:
Debian Release: testing/unstable
APT prefers unstable
APT policy: (500, 'unstable'), (500, 'stable'), (1, 'experimental')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.17-2-686
Locale: LANG=C, LC_CTYPE=C (charmap=UTF-8) (ignored: LC_ALL set to en_US.UTF-8)
Versions of packages nis depends on:
ii debconf [debconf-2.0] 1.5.3 Debian configuration management sy
ii libc6 2.3.6.ds1-2 GNU C Library: Shared libraries
ii libgdbm3 1.8.3-3 GNU dbm database routines (runtime
ii libslp1 1.2.1-5 OpenSLP libraries
ii make 3.81-2 The GNU version of the "make" util
ii netbase 4.26 Basic TCP/IP networking system
ii portmap 5-20 The RPC portmapper
ii sysvinit 2.86.ds1-15 System-V-like init utilities
nis recommends no packages.
-- debconf information:
* nis/not-yet-configured:
* nis/domain: uk
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]