Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 9 Jan 1997 10:28:29 +0100 (MET)
From:      grog@lemis.de
To:        peter@spinner.DIALix.COM (Peter Wemm)
Cc:        FreeBSD-current@FreeBSD.ORG (FreeBSD current users)
Subject:   Re: What's happened to nfsd and mountd?
Message-ID:  <199701090928.KAA29540@freebie.lemis.de>
In-Reply-To: <199701090327.LAA10608@spinner.DIALix.COM> from Peter Wemm at "Jan 9, 97 11:27:13 am"

next in thread | previous in thread | raw e-mail | index | archive | help
Peter Wemm writes:
> David Nugent wrote:
>>  We're suffering the same problem here. ifconfig -a shows:
> [..]
>
>>  The first interface is up and operational. Nothing funky with IP
>>  aliases on this box. Another one (with nothing but loopback and
>>  ethernet) which *does* have several IP aliases on ed0 is using
>>  the exact same build, but mountd/nfsd load and work fine there.
>>
>>  Regards,
>>  David
>
> OK, time to run a quick test..  What do you guys get from this quick hack..

A pointer to the problem, by the look of it:

=== grog@freebie (/dev/ttypa) ~/src 3 -> gma
get_myaddress() returns 0
sin_family = 0 (AF_INET = 2)
sin_len = 3 (16)
sin_port = 0
sin_addr = 0.32.0.0
SIOCFIGCONF used 1008 bytes of a buffer 1024 long

> One of my systems nearby uses 992 bytes of the SIOCGIFCONF 1024 byte buffer
> (as used in get_myaddress).  It would be interesting to know what happens
> if it is overflowing on the systems that are failing.

I'd guess it's probably the wrong family.

> Just to make things even more bizzare, the system that returns 992 bytes
> (struct ifreq = 32 bytes), which is 31 ifreq's, actually has 49 interfaces,
> and yet SIOCGIFCONF returned a "short" list with only 31 entries and no
> indication of error or overflow.  (the actual number of slots of
> SIOCGIFCONF data comes from  "netstat -in | grep -v Name | wc -l", don't
> forget that SIOCGIFCONF also returns AF_LINK entries)
>
> On my own system here, I have 5 interfaces, yet SIOCGIFCONF returns 9 ifreq
> structs.
>
> Garrett suggested redoing get_myaddress() to use sysctl(), which is
> starting to sound more appealing..
>
> Something to try on the machines that are failing..  In lib/libc/rpc/
> get_myaddress.c, change "char buf[BUFSIZ];" to something bigger,
> eg: "char buf[10240];"   If you got about "992 used" for the test program
> above, make the change there too.

Oh well, I suppose I could do that.  But do you really still think
this is the problem?

Greg



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199701090928.KAA29540>