Subject: mountd weirdness
To: None <netbsd-help@NetBSD.ORG>
From: Brian C. Grayson <bgrayson@ece.utexas.edu>
List: netbsd-help
Date: 07/09/1998 00:26:19
  I have two machines at home, connected via Ethernet, both
running -current.  When I start up ``snowy'' and then do
rpcinfo -p snowy, it is missing one of the 4 registrations:
...
    100005    3   udp    971  mountd
    100005    3   tcp    980  mountd
    100005    1   udp  65437  mountd

  (At previous boot-ups, it was missing one of the udp
registrations, so it's not always the same one, and it seems
fairly repeatable).

  Then, when I try a showmount, which should return nothing as no
clients have mounted anything, showmount hangs for a few seconds,
and the console prints stuff like:
...
Jul  8 23:54:04 snowy mountd[208]: Can't register mount
Jul  8 23:54:04 snowy mountd[212]: Can't register mount
Jul  8 23:54:04 snowy mountd[218]: Can't register mount
...
Jul  8 23:54:05 snowy inetd[136]: mountd/rpc/udp server failing
(looping), service terminated

  The showmount times out:
showmount: Can't do Mountdump rpc: RPC: Timed out

  A ps -ax at this point shows around 20 mountd processes. (!)

  Now if I try running showmount again, it completes immediately.

  Questions (yes, I'm clueless!):
  0.  If I am starting mountd in /etc/rc, should mountd be
      enabled in /etc/inetd.conf?  I have it enabled, and am
      beginning to wonder if that's the problem.  If so, perhaps
      someone could add a comment in inetd.conf saying ``if you
      run mountd from /etc/rc, leave the mountd line commented
      out.'' for us clueless folk.

  1.  Why do only three of the four RPC registrations take place?
      The code looks like it should exit if it can't do all four
      registrations.

  2.  Why is inetd spawning a zillion mountd's when one was
      already running?  I have the wait option in my inetd.conf
      (it's pretty much a vanilla setup).  Even if my setup is
      Wrong (see question 0), shouldn't it have only spawned one?

  3.  Why do some of the spawned mountd's never exit?  It _appears_ that
      the mountd's that are still hung are the ones that never
      printed anything to syslog, i.e., the syslog messages are from
      ones that successfully exited.  Even if inetd.conf
      shouldn't be spawning mountd's, it seems like they should
      still die on their own.

  4.  Why does the second showmount work, when I have done
      nothing (i.e., no HUPs to anything)?

  Thanks in advance.  Disabling mountd in /etc/inetd.conf seems
to have made the machine usable, but the above things trouble me
even if my setup was Wrong.

  Brian
-- 
Brian Grayson (bgrayson@ece.utexas.edu)
PhD Candidate, Electrical and Computer Engineering, UT at Austin
Office:  ENS 406       (512) 471-8011
Finger bgrayson@orac.ece.utexas.edu for PGP key.