Bug 142774 - Problem with outgoing connections on interface with multiple aliases
Summary: Problem with outgoing connections on interface with multiple aliases
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 8.0-STABLE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-01-13 08:40 UTC by Sergey Chernikov
Modified: 2018-01-03 05:13 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sergey Chernikov 2010-01-13 08:40:02 UTC
(a side note: unfortunately there is no "net" category available on http://www.freebsd.org/send-pr.html)

I have network setup with 3 aliases on one of the interfaces. When trying to establish an outgoing connection to a host on other network, it fails (wait for connection until a timeout expires). Corresponding ipfw counter (rule 100 or 200 below) for policy route grows during this attempt. All incoming connections to addresses 10.12.12.0/24 can be established.

ifconfig:
bce0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 536
        options=1bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4>
        ether 18:a9:05:3b:3a:38
        inet 172.23.31.27 netmask 0xffffff00 broadcast 172.23.31.255
        media: Ethernet autoselect (1000baseT <full-duplex>)
        status: active
bce1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=1bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4>
        ether 18:a9:05:3b:3a:3a
        inet 10.12.12.1 netmask 0xffffff00 broadcast 10.12.12.255
        inet 10.12.12.4 netmask 0xffffffff broadcast 10.12.12.4
        inet 10.12.12.6 netmask 0xffffffff broadcast 10.12.12.6
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
        options=3<RXCSUM,TXCSUM>
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3
        inet6 ::1 prefixlen 128
        inet 127.0.0.1 netmask 0xff000000
        nd6 options=3<PERFORMNUD,ACCEPT_RTADV>

Relevant portion of ipfw:
00100   6725    430586 fwd 10.12.12.254 ip from 10.12.12.0/24 to 172.23.31.34
00200  16016   1037707 fwd 10.12.12.254 ip from 10.12.12.0/24 to 10.10.10.2
00300     42      8124 allow tcp from 10.12.12.6 to 172.23.31.27 dst-port 25
00400     40      2552 allow udp from 10.12.12.6 to 172.23.31.27 dst-port 53
00500     40      8122 allow tcp from 10.12.12.4 to 172.23.31.27 dst-port 25
00600     80      5192 allow udp from 10.12.12.4 to 172.23.31.27 dst-port 53
00700     56      8426 allow tcp from 10.12.12.1 to 172.23.31.27 dst-port 25
00800   8484    822360 allow udp from 10.12.12.1 to 172.23.31.27 dst-port 53
00900      0         0 nat 1 ip from 10.12.12.6 to 10.10.10.1
01000      0         0 nat 1 ip from 10.12.12.4 to 10.10.10.1
01100   3692    192157 nat 1 ip from 10.12.12.1 to 10.10.10.1
01200   6587   3008474 nat 1 ip from 10.10.10.1 to 172.23.31.27 in
01300      0         0 deny log ip from 10.12.12.6 to 172.23.31.0/24
01400      0         0 deny log ip from 10.12.12.4 to 172.23.31.0/24
01500      0         0 deny log ip from 10.12.12.1 to 172.23.31.0/24

netstat -rn:
Internet:
Destination        Gateway            Flags    Refs      Use  Netif Expire
default            10.12.12.254       UGS         6    15898   bce1
10.10.10.0/24      172.23.31.62       UGS         1    20994   bce0
10.12.12.0/24      link#2             U       23164   427546   bce1
10.12.12.1         link#2             UHS         0     4630    lo0
10.12.12.4         link#2             UHS         0      108    lo0 =>
10.12.12.6         link#2             UHS         0       56    lo0 =>
10.12.12.4/32      link#2             U           0        0   bce1
10.12.12.6/32      link#2             U           0       89   bce1
10.214.0.0/16      172.23.31.62       UGS         0   106841   bce0
127.0.0.1          link#3             UH          0      669    lo0
172.23.31.0/24     link#1             U           9  8946135   bce0
172.23.31.27       link#1             UHS         0     4517    lo0

Fix: 

When I remove routes for 10.12.12.6 ("route delete 10.12.12.6") everything starts to work, including outgoing connections from 10.12.12.6 to 172.23.31.34.
Comment 1 Gavin Atkinson freebsd_committer freebsd_triage 2010-01-13 21:09:15 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-net

Over to maintainer(s). 

To submitter: do you know if this configuration works on 7-STABLE?
Comment 2 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:01:01 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped