NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
bin/55278: inetd dies while starting Samba smbd
>Number: 55278
>Category: bin
>Synopsis: inetd dies while starting Samba smbd
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue May 19 07:25:00 +0000 2020
>Originator: Hauke Fath
>Release: NetBSD 9.0_STABLE
>Organization:
Falling Raindrops
>Environment:
System: NetBSD pizza.causeuse.org 9.0_STABLE NetBSD 9.0_STABLE (BLACKBOX-$Revision: 1.85 $) #0: Sat May 16 15:16:03 CEST 2020 hauke%pizza.causeuse.org@localhost:/var/obj/netbsd-builds/9/amd64/sys/arch/amd64/compile/BLACKBOX amd64
Architecture: x86_64
Machine: amd64
>Description:
On a machine that does not see windows clients often, I have
configured the Samba nmbd and smbd daemons to be started from
inetd:
netbios-ssn stream tcp nowait root /usr/pkg/sbin/smbd smbd
microsoft-ds stream tcp nowait root /usr/pkg/sbin/smbd smbd
netbios-ns dgram udp wait root /usr/pkg/sbin/nmbd nmbd
This works fine with a non-detaching inetd ('inetd -d -l'):
# ./inetd -l -d
[...]
ADD : netbios-ssn proto=tcp, wait.max=0.40, user:group=root:(null) builtin=0 server=/usr/pkg/sbin/smbd policy=
registered /usr/pkg/sbin/smbd on 20
ADD : microsoft-ds proto=tcp, wait.max=0.40, user:group=root:(null) builtin=0 server=/usr/pkg/sbin/smbd policy=
registered /usr/pkg/sbin/smbd on 21
ADD : netbios-ns proto=udp, wait.max=1.40, user:group=root:(null) builtin=0 server=/usr/pkg/sbin/nmbd policy=
registered /usr/pkg/sbin/nmbd on 22
someone wants microsoft-ds
accept, ctrl 5
someone wants microsoft-ds
accept, ctrl 5
8493 execl /usr/pkg/sbin/smbd
2551 execl /usr/pkg/sbin/smbd
8493 reaped, status 0xf
2551 reaped, status 0xf
But a daemonized inetd terminates while starting smbd:
[inetd built with -O -g3]
(gdb) attach 1525
Attaching to process 1525
Reading symbols from /u1/netbsd-9/src/usr.sbin/inetd/./inetd...
Reading symbols from /usr/lib/libwrap.so.1...
(No debugging symbols found in /usr/lib/libwrap.so.1)
Reading symbols from /usr/lib/libutil.so.7...
(No debugging symbols found in /usr/lib/libutil.so.7)
Reading symbols from /usr/lib/libipsec.so.3...
(No debugging symbols found in /usr/lib/libipsec.so.3)
Reading symbols from /usr/lib/libc.so.12...
(No debugging symbols found in /usr/lib/libc.so.12)
Reading symbols from /usr/libexec/ld.elf_so...
(No debugging symbols found in /usr/libexec/ld.elf_so)
[Switching to LWP 1 of process 1525]
0x000074691e042b3a in _sys___kevent50 () from /usr/lib/libc.so.12
(gdb) continue
Continuing.
[New process 1525]
[Detaching after fork from child process 2295]
[Detaching after fork from child process 8237]
Thread 2 "" received signal SIGTERM, Terminated.
[Switching to process 1525]
0x000074691e0427fa in _sys___sigprocmask14 () from /usr/lib/libc.so.12
(gdb) bt
#0 0x000074691e0427fa in _sys___sigprocmask14 () from /usr/lib/libc.so.12
#1 0x000074691e11d13f in clnt_vc_create () from /usr/lib/libc.so.12
#2 0x000074691e113ef2 in ?? () from /usr/lib/libc.so.12
#3 0x000074691e1142cb in rpcb_unset () from /usr/lib/libc.so.12
#4 0x0000000099603ad4 in unregister_rpc (sep=0x74691f1f5d00) at inetd.c:1211
#5 0x0000000099605d2c in goaway () at inetd.c:1028
#6 main (argc=<optimized out>, argv=<optimized out>) at inetd.c:515
(gdb)
% head -1 inetd.c
/* $NetBSD: inetd.c,v 1.125 2017/11/28 11:51:11 martin Exp $ */
%
>How-To-Repeat:
Run Samba 4 smbd from inetd: Connecting clients will error
out, and the server's inetd will vanish in thin air. No
related log entries anywhere.
>Fix:
No idea...
>Unformatted:
Home |
Main Index |
Thread Index |
Old Index