From nobody@FreeBSD.ORG  Sat Nov 25 04:32:03 2000
Return-Path: <nobody@FreeBSD.ORG>
Received: by hub.freebsd.org (Postfix, from userid 32767)
	id D06D937B479; Sat, 25 Nov 2000 04:32:03 -0800 (PST)
Message-Id: <20001125123203.D06D937B479@hub.freebsd.org>
Date: Sat, 25 Nov 2000 04:32:03 -0800 (PST)
From: nop@sendmail.ru
Sender: nobody@FreeBSD.ORG
To: freebsd-gnats-submit@FreeBSD.org
Subject: FreeBSD (all versions) sends ARP requests for MAC resolving of local aliases
X-Send-Pr-Version: www-1.0

>Number:         23090
>Category:       kern
>Synopsis:       FreeBSD (all versions) sends ARP requests for MAC resolving of local aliases
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    roam
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Nov 25 04:40:01 PST 2000
>Closed-Date:    Sat Nov 25 05:48:11 PST 2000
>Last-Modified:  Sat Nov 25 05:48:41 PST 2000
>Originator:     Nop
>Release:        4.2-RELEASE
>Organization:
VMTS
>Environment:
FreeBSD dialup375.primorye.ru 4.2-RELEASE FreeBSD 4.2-RELEASE #0: Tue Nov 21 17:43:34 VLAT 2000     root@dialup375.primorye.ru:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
FreeBSD of all 4.x versions sends ARP broadcast request for 
resolving MAC address of any local IP, which is _local_ alias 
on it's own ethernet interface. It can't find this MAC, because
it's not respond on it's own broadcast. This is problem when, for 
example we have mass WEB hosting (IP based) on same machine and 
indexing robot on the same machine, which create indexes of any 
site, that is hosted on any of aliases on the same machine. We get
"TIMEOUT" for such query.
>How-To-Repeat:
#ifconfig ep0 inet xx.xx.xx.xx alias - create an IP alias in the same network as main IP.
#ping xx.xx.xx.xx
ping: sendto: Host is down
ping: sendto: Host is down

>Fix:
Problem can be fixed by:
1) explict arp table change:
  arp -s xx.xx.xx.xx MA-CM-AC-MA-CM-AC pub
2) and of coz by kernel patching, I have no patch.

P.S. 1st method is rather anoying.


>Release-Note:
>Audit-Trail:

From: Peter Pentchev <roam@orbitel.bg>
To: nop@sendmail.ru
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: kern/23090: FreeBSD (all versions) sends ARP requests for MAC resolving of local aliases
Date: Sat, 25 Nov 2000 14:53:54 +0200

 On Sat, Nov 25, 2000 at 04:32:03AM -0800, nop@sendmail.ru wrote:
 > 
 > >Number:         23090
 > >Category:       kern
 > >Synopsis:       FreeBSD (all versions) sends ARP requests for MAC resolving of local aliases
 [snip]
 > >Description:
 > FreeBSD of all 4.x versions sends ARP broadcast request for 
 > resolving MAC address of any local IP, which is _local_ alias 
 > on it's own ethernet interface. It can't find this MAC, because
 > it's not respond on it's own broadcast. This is problem when, for 
 > example we have mass WEB hosting (IP based) on same machine and 
 > indexing robot on the same machine, which create indexes of any 
 > site, that is hosted on any of aliases on the same machine. We get
 > "TIMEOUT" for such query.
 > >How-To-Repeat:
 > #ifconfig ep0 inet xx.xx.xx.xx alias - create an IP alias in the same network as main IP.
 > #ping xx.xx.xx.xx
 > ping: sendto: Host is down
 > ping: sendto: Host is down
 > 
 > >Fix:
 > Problem can be fixed by:
 > 1) explict arp table change:
 >   arp -s xx.xx.xx.xx MA-CM-AC-MA-CM-AC pub
 > 2) and of coz by kernel patching, I have no patch.
 
 An even easier fix: read the FAQ, which is either installed locally on
 your system in /usr/share/doc/faq/, or, if you have chosen not to install
 documentation, on http://www.freebsd.org/FAQ/.  There is Chapter 9 there,
 named Networking, and question 9.8.  To quote:
 
    9.8. How can I setup Ethernet aliases?
    
    Add netmask 0xffffffff to your ifconfig command-line like the
    following:
     # ifconfig ed0 alias 204.141.95.2 netmask 0xffffffff
 
 Please try this, and if it does not solve your problem (sure works for me),
 ask again on the questions mailing list, freebsd-questions@freebsd.org.
 
 G'luck,
 Peter
 
 -- 
 This sentence is false.
 
State-Changed-From-To: open->feedback 
State-Changed-By: roam 
State-Changed-When: Sat Nov 25 05:02:18 PST 2000 
State-Changed-Why:  
I believe this problem can be solved by item 9.8 in the FAQ - using a /32 
netmask to configure aliases on an existing Ethernet interface. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=23090 
Responsible-Changed-From-To: freebsd-bugs->roam 
Responsible-Changed-By: roam 
Responsible-Changed-When: Sat Nov 25 05:05:25 PST 2000 
Responsible-Changed-Why:  
Let's see if I can handle a kern/ PR :) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=23090 
State-Changed-From-To: feedback->closed 
State-Changed-By: roam 
State-Changed-When: Sat Nov 25 05:48:11 PST 2000 
State-Changed-Why:  
Originator reports success. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=23090 
>Unformatted:
