From owner-freebsd-net@freebsd.org Sun Mar 11 00:02:01 2018 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 187C0F42C12 for ; Sun, 11 Mar 2018 00:02:01 +0000 (UTC) (envelope-from list1@gjunka.com) Received: from msa1.earth.yoonka.com (yoonka.com [88.98.225.149]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "msa1.earth.yoonka.com", Issuer "msa1.earth.yoonka.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 974A86CFF9 for ; Sun, 11 Mar 2018 00:02:00 +0000 (UTC) (envelope-from list1@gjunka.com) Received: from crayon2.yoonka.com (crayon2.yoonka.com [10.70.7.20]) (authenticated bits=0) by msa1.earth.yoonka.com (8.15.2/8.15.2) with ESMTPSA id w2B01xVu033453 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO) for ; Sun, 11 Mar 2018 00:01:59 GMT (envelope-from list1@gjunka.com) Subject: Re: Incorrect route interface To: freebsd-net@freebsd.org References: <9dd657bc-ad58-f5cb-327a-572a561f1d6b@gjunka.com> <5AA45F89.7090800@grosbein.net> From: Grzegorz Junka Message-ID: <21e1b380-4d4a-cd26-5694-fac51cc0dfa2@gjunka.com> Date: Sun, 11 Mar 2018 00:01:59 +0000 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <5AA45F89.7090800@grosbein.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-GB-large X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 11 Mar 2018 00:02:01 -0000 On 10/03/2018 22:43, Eugene Grosbein wrote: > 11.03.2018 5:01, Grzegorz Junka wrote: > >> In rc.conf I have: >> >> hostname="some.server.com" >> ifconfig_em0="inet 10.20.2.14 netmask 255.255.0.0" >> ifconfig_em1="inet 10.20.2.15 netmask 255.255.0.0" >> ifconfig_igb0="inet 10.20.2.16 netmask 255.255.0.0" > Just do not assign addresses from same network 10.20.0.0/16 to different network interfaces > and you will be fine. Assign them all to right interface: > > ifconfig_em0="inet 10.20.2.14 netmask 255.255.0.0" > ifconfig_em0_alias0="inet 10.20.2.15/32" > ifconfig_igb0_alias0="inet 10.20.2.16/32" > > Do not try to use several physical network cards to connect hosts using just one IP network > as generally each card/interface needs distinct IP network to work flawlessly. > Did you mean: ifconfig_em1_alias0="inet 10.20.2.15/32" I don't quite understand how you can assign an alias to an interface (igb0 in this case) without configuring it with an IP first? According to the documentation an alias is an additional network address, not the only one?