On Sat, Jul 22, 2017 at 02:05:27PM -0000, Christian Weisgerber wrote:
> On 2017-07-22, Florian Obser <[email protected]> wrote:
> 
> > reenabling debug output on the ramdisk I see this:
> >
> > engine_dispatch_frontend: IMSG_PROPOSAL_ACK: 1 - 25467
> > configure_dfr: 1
> > engine_dispatch_frontend: IMSG_PROPOSAL_ACK: 2 - 25467
> > configure_address: 1
> > engine_dispatch_frontend: IMSG_PROPOSAL_ACK: 3 - 25467
> > configure_address: 1
> > configure_interface: vio0
> > configure_interface: vio0
> > fatal in main: SIOCAIFADDR_IN6: File exists
> > # RTM_NEWADDR: vio0[1]
> > RTM_NEWADDR: vio0[1]
> > RTM_DELADDR: vio0[1]
> > engine exiting
> > fatal in engine: msgbuf_write: Broken pipe
> >
> > Maybe you can only have one v6 address on the ramdisk?
> 
> Well, I can manually configure additional addresses:
> 
> ------------------->
> # ifconfig egress            
> em0: flags=208843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,AUTOCONF6> mtu 1500
>         lladdr 00:0d:b9:41:06:a4
>         llprio 3
>         groups: netboot egress
>         media: Ethernet autoselect (1000baseT full-duplex,rxpause,txpause)
>         status: active
>         inet 172.16.0.2 netmask 0xffffff00 broadcast 172.16.0.255
>         inet6 fe80::20d:b9ff:fe41:6a4%em0 prefixlen 64 scopeid 0x1
>         inet6 fddd:28ee:243:0:384d:91e7:fefc:b697 prefixlen 64 autoconf 
> autoconfprivacy pltime 2171 vltime 520983
>         inet6 fddd:28ee:243::2 prefixlen 64
>         inet6 2003:e5:cbc0:a01::2 prefixlen 64
> <-------------------
> 

This is a problem with the kernel routing table not being mpatch
capable, you can see this with v4, too:

# ifconfig vio0
vio0: 
flags=248843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,INET6_NOPRIVACY,AUTOCONF6> 
mtu 1500
        lladdr 52:54:00:c7:09:1b
        llprio 3
        groups: egress
        media: Ethernet autoselect
        status: active
        inet 192.168.178.178 netmask 0xffffff00 broadcast 192.168.178.255
        inet6 fe80::5054:ff:fec7:91b%vio0 prefixlen 64 scopeid 0x1
# route -n show -inet
Routing tables

Internet:
Destination        Gateway            Flags   Refs      Use   Mtu  Prio Iface
default            192.168.178.1      UGS        0        4     -     8 vio0
127/8              127.0.0.1          UGRS       0        0 32768     8 lo0
127.0.0.1          127.0.0.1          UHhPl      1        2 32768     1 lo0
192.168.178/24     192.168.178.178    UCPn       1        0     -     4 vio0
192.168.178.1      54:67:51:de:e7:ce  UHLchP     1        2     -     3 vio0
192.168.178.178    52:54:00:c7:09:1b  UHLPl      0       16     -     1 vio0
192.168.178.255    192.168.178.178    UHPb       0        0     -     1 vio0

# ifconfig vio0 inet alias 192.168.178.179/24
ifconfig: SIOCAIFADDR: File exists
# ifconfig vio0
vio0: 
flags=248843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,INET6_NOPRIVACY,AUTOCONF6> 
mtu 1500
        lladdr 52:54:00:c7:09:1b
        llprio 3
        groups: egress
        media: Ethernet autoselect
        status: active
        inet 192.168.178.178 netmask 0xffffff00 broadcast 192.168.178.255
        inet6 fe80::5054:ff:fec7:91b%vio0 prefixlen 64 scopeid 0x1
# route -n show -inet
Routing tables

Internet:
Destination        Gateway            Flags   Refs      Use   Mtu  Prio Iface
127/8              127.0.0.1          UGRS       0        0 32768     8 lo0
127.0.0.1          127.0.0.1          UHhPl      1        2 32768     1 lo0
192.168.178.178    52:54:00:c7:09:1b  UHLPl      0       16     -     1 vio0

note how we lost a bunch of routes, including 192.168.178.0/24
now you can add 192.168.178.179/24:

# ifconfig vio0 inet alias 192.168.178.179/24
# route -n show -inet
Routing tables

Internet:
Destination        Gateway            Flags   Refs      Use   Mtu  Prio Iface
127/8              127.0.0.1          UGRS       0        0 32768     8 lo0
127.0.0.1          127.0.0.1          UHhPl      1        2 32768     1 lo0
192.168.178/24     192.168.178.179    UCPn       1        0     -     4 vio0
192.168.178.178    52:54:00:c7:09:1b  UHLPl      0       16     -     1 vio0
192.168.178.179    52:54:00:c7:09:1b  UHLPl      0        1     -     1 vio0
192.168.178.252    08:62:66:8b:84:20  UHLcP      0        1     -     3 vio0
192.168.178.255    192.168.178.179    UHPb       0        0     -     1 vio0

# ifconfig vio0
vio0: 
flags=248843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,INET6_NOPRIVACY,AUTOCONF6> 
mtu 1500
        lladdr 52:54:00:c7:09:1b
        llprio 3
        groups: egress
        media: Ethernet autoselect
        status: active
        inet 192.168.178.178 netmask 0xffffff00 broadcast 192.168.178.255
        inet6 fe80::5054:ff:fec7:91b%vio0 prefixlen 64 scopeid 0x1
        inet 192.168.178.179 netmask 0xffffff00 broadcast 192.168.178.255


------------------------------------------------------------------------
here is the same thing for IPv6:

# ifconfig vio0 inet6 2001:db8::1/64
# route -n show -inet6
Routing tables

Internet6:
Destination                        Gateway                        Flags   Refs  
    Use   Mtu  Prio Iface
::1                                ::1                            UHPl       0  
      0 32768     1 lo0
2001:db8::/64                      2001:db8::1                    UCPn       0  
      0     -     4 vio0
2001:db8::1                        52:54:00:c7:09:1b              UHLPl      0  
      0     -     1 vio0
fe80::%vio0/64                     fe80::5054:ff:fec7:91b%vio0    UCPn       0  
      0     -     4 vio0
fe80::5054:ff:fec7:91b%vio0        52:54:00:c7:09:1b              UHLPl      0  
      0     -     1 vio0
fe80::1%lo0                        fe80::1%lo0                    UHPl       0  
      0 32768     1 lo0
ff01::%vio0/32                     fe80::5054:ff:fec7:91b%vio0    Um         0  
      1     -     4 vio0
ff01::%lo0/32                      ::1                            Um         0  
      1 32768     4 lo0
ff02::%vio0/32                     fe80::5054:ff:fec7:91b%vio0    Um         0  
      1     -     4 vio0
ff02::%lo0/32                      ::1                            Um         0  
      1 32768     4 lo0
# ifconfig vio0
vio0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        lladdr 52:54:00:c7:09:1b
        llprio 3
        groups: egress
        media: Ethernet autoselect
        status: active
        inet 192.168.178.178 netmask 0xffffff00 broadcast 192.168.178.255
        inet6 fe80::5054:ff:fec7:91b%vio0 prefixlen 64 scopeid 0x1
        inet6 2001:db8::1 prefixlen 64
# ifconfig vio0 inet6 2001:db8::2/64
ifconfig: SIOCAIFADDR: File exists
# route -n show -inet6
Routing tables

Internet6:
Destination                        Gateway                        Flags   Refs  
    Use   Mtu  Prio Iface
::1                                ::1                            UHPl       0  
      0 32768     1 lo0
2001:db8::1                        52:54:00:c7:09:1b              UHLPl      0  
      0     -     1 vio0
fe80::%vio0/64                     fe80::5054:ff:fec7:91b%vio0    UCPn       0  
      0     -     4 vio0
fe80::5054:ff:fec7:91b%vio0        52:54:00:c7:09:1b              UHLPl      0  
      0     -     1 vio0
fe80::1%lo0                        fe80::1%lo0                    UHPl       0  
      0 32768     1 lo0
ff01::%vio0/32                     fe80::5054:ff:fec7:91b%vio0    Um         0  
      2     -     4 vio0
ff01::%lo0/32                      ::1                            Um         0  
      1 32768     4 lo0
ff02::%vio0/32                     fe80::5054:ff:fec7:91b%vio0    Um         0  
      2     -     4 vio0
ff02::%lo0/32                      ::1                            Um         0  
      1 32768     4 lo0
# ifconfig vio0
vio0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        lladdr 52:54:00:c7:09:1b
        llprio 3
        groups: egress
        media: Ethernet autoselect
        status: active
        inet 192.168.178.178 netmask 0xffffff00 broadcast 192.168.178.255
        inet6 fe80::5054:ff:fec7:91b%vio0 prefixlen 64 scopeid 0x1
        inet6 2001:db8::1 prefixlen 64
# ifconfig vio0 inet6 2001:db8::2/64
# route -n show -inet6
Routing tables

Internet6:
Destination                        Gateway                        Flags   Refs  
    Use   Mtu  Prio Iface
::1                                ::1                            UHPl       0  
      0 32768     1 lo0
2001:db8::/64                      2001:db8::2                    UCPn       0  
      0     -     4 vio0
2001:db8::1                        52:54:00:c7:09:1b              UHLPl      0  
      0     -     1 vio0
2001:db8::2                        52:54:00:c7:09:1b              UHLPl      0  
      0     -     1 vio0
fe80::%vio0/64                     fe80::5054:ff:fec7:91b%vio0    UCPn       0  
      0     -     4 vio0
fe80::5054:ff:fec7:91b%vio0        52:54:00:c7:09:1b              UHLPl      0  
      0     -     1 vio0
fe80::1%lo0                        fe80::1%lo0                    UHPl       0  
      0 32768     1 lo0
ff01::%vio0/32                     fe80::5054:ff:fec7:91b%vio0    Um         0  
      3     -     4 vio0
ff01::%lo0/32                      ::1                            Um         0  
      1 32768     4 lo0
ff02::%vio0/32                     fe80::5054:ff:fec7:91b%vio0    Um         0  
      3     -     4 vio0
ff02::%lo0/32                      ::1                            Um         0  
      1 32768     4 lo0
# ifconfig vio0
vio0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        lladdr 52:54:00:c7:09:1b
        llprio 3
        groups: egress
        media: Ethernet autoselect
        status: active
        inet 192.168.178.178 netmask 0xffffff00 broadcast 192.168.178.255
        inet6 fe80::5054:ff:fec7:91b%vio0 prefixlen 64 scopeid 0x1
        inet6 2001:db8::1 prefixlen 64
        inet6 2001:db8::2 prefixlen 64

As a work around you could put in inet6 -autoconfprivacy into the
hostname.if since the privacy address is in the same /64

Btw. with kernel based slaac this used to work since the
kernel didn't go through the ioctl path but just fiddled directly with
the interface and skipped rt_ifa_add() which is failing here.

> And the corresponding /64s show up in the routing table, too.
> 
> However, I can't send packets beyond the local segment.  tcpdump
> on the gateway shows that it receives a steady stream of neighbor
> solicitations for its advertised default router address.  The replies
> don't seem to have any effect.

I haven't figured out what's going on here. If I delete the default
route and set the exact same one with route(8)it works. I suspect
another mpath issue, since that seems to be the main difference
between bsd.rd and bsd.

> 
> -- 
> Christian "naddy" Weisgerber                          [email protected]
> 

-- 
I'm not entirely sure you are real.

Reply via email to