Community discussions

MikroTik App
 
mmc
newbie
Topic Author
Posts: 39
Joined: Wed Dec 29, 2004 1:44 am

ros7 bgp ipv6 advertisement doesn't work

Mon Aug 22, 2022 7:48 am

hi,
following the manual, i didn't found a working quick solution, how to proper advertise ipv6 prefixes via bgp.

https://help.mikrotik.com/docs/display/ ... s-Networks

ipv4 works like described in the manual, but ipv6 never gets advertised as it seems.

ros 7.4.1 box:
[admin@bgp1] > ip route print
Flags: D - DYNAMIC; A - ACTIVE; c, s, y - COPY
Columns: DST-ADDRESS, GATEWAY, DISTANCE
#     DST-ADDRESS     GATEWAY  DISTANCE
  DAc 10.230.0.0/24   ether1          0
0  As 47.11.0.0/19                  254
  DAc 192.168.1.0/24  ether5          0

[admin@bgp1] > ipv6 route print
Flags: A - ACTIVE; s, y - COPY
Columns: DST-ADDRESS, DISTANCE
#    DST-ADDRESS     DISTANCE
0 As 4700:1100::/29       254

[admin@bgp1] > ip firewall address-list pri
Columns: LIST, ADDRESS, CREATION-TIME
# LIST          ADDRESS       CREATION-TIME       
0 bgp-networks  47.11.0.0/19  jan/02/1970 00:53:33

[admin@bgp1] > ipv6 firewall address-list pri
Columns: LIST, ADDRESS
# LIST          ADDRESS       
0 bgp-networks  4700:1100::/29

[admin@bgp1] > routing bgp session print
Flags: E - established 
 0 E name="rr2-1" 
     remote.address=192.168.1.2 .as=4711 .id=192.168.1.2 .refused-cap-opt=no .capabilities=mp,rr,as4 .afi=ip,ipv6 .messages=4 
     .bytes=76 .eor="" 
     local.address=192.168.1.1 .as=65001 .id=192.168.1.1 .capabilities=mp,rr,gr,as4 .afi=ip,ipv6 .messages=6 .bytes=191 .eor="" 
     output.procid=21 .network=bgp-networks .keep-sent-attributes=yes 
     input.procid=21 ebgp 
     hold-time=3m keepalive-time=1m uptime=3m52s150ms 
with the above minimalisitic configuration, you would expect that this ros 7.4.1 box advertises following prefixes:
- ipv4 47.11.0.0/19
- ipv6 4700:1100::/29

unfortunate when you use ros7, there is no way to check what you are really advertising (see bug #[SUP-90372]), so i have taken a ros6 box as a bgp session partner for above setup, which has the ability to show everything.
[admin@rr2] > routing bgp peer print status
Flags: X - disabled, E - established 
 0 E name="bgp1" instance=rr remote-address=192.168.1.1 remote-as=65001 tcp-md5-key="" nexthop-choice=default 
     multihop=no route-reflect=yes hold-time=3m ttl=255 in-filter="" out-filter="" address-families=ip,ipv6 
     update-source=192.168.1.2 default-originate=never remove-private-as=no as-override=no passive=no use-bfd=no 
     remote-id=192.168.1.1 local-address=192.168.1.2 uptime=16m8s prefix-count=1 updates-sent=0 
     updates-received=1 withdrawn-sent=0 withdrawn-received=1 remote-hold-time=3m used-hold-time=3m 
     used-keepalive-time=1m refresh-capability=yes as4-capability=yes state=established 

[admin@rr2] > ip route print
Flags: X - disabled, A - active, D - dynamic, C - connect, S - static, r - rip, b - bgp, o - ospf, m - mme, 
B - blackhole, U - unreachable, P - prohibit 
 #      DST-ADDRESS        PREF-SRC        GATEWAY            DISTANCE
 0 ADC  10.230.0.0/24      10.230.0.112    ether1                    0
 1 ADb  47.11.0.0/19                       192.168.1.1              20
 2 ADC  192.168.1.0/24     192.168.1.2     ether5                    0

[admin@rr2] > ipv6 route print
Flags: X - disabled, A - active, D - dynamic, C - connect, S - static, r - rip, o - ospf, b - bgp, 
U - unreachable 
 #      DST-ADDRESS              GATEWAY                  DISTANCE
finally with the lack of reliability and features, using bgp in ros7 feels currently like driving a car blindfolded and hoping to crash nowhere :(

has someone found a way how to advertise ipv6 prefixes in a proper working way with ros7?
 
User avatar
IPANetEngineer
Trainer
Trainer
Posts: 1676
Joined: Fri Aug 10, 2012 6:46 am
Location: iparchitechs.com
Contact:

Re: ros7 bgp ipv6 advertisement doesn't work

Mon Aug 22, 2022 10:57 am

Try creating a peering over IPv6 instead of passing the AFI for IPv6 over an IPv4 peering and see if the behavior changes.
 
mmc
newbie
Topic Author
Posts: 39
Joined: Wed Dec 29, 2004 1:44 am

Re: ros7 bgp ipv6 advertisement doesn't work

Mon Aug 22, 2022 5:20 pm

yes, when you do it with afi ipv6 only with dst address in native ipv6 it works. but than you can't define the ipv6 source address of the bgp session, which is problematic in some setups.

ros7.4.1 to ros7.4.1with afi ipv6 with dst address in ipv6:
[admin@rr1] > routing bgp connection print where disabled=no
Flags: D - dynamic, X - disabled, I - inactive 
 1   name="bgp1-ros7-ipv6" 
     remote.address=2000::111/128 .as=65001 
     local.default-address=2000::113 .role=ebgp 
     routing-table=main router-id=10.230.0.113 templates=as4711-ros7 as=4711 
     address-families=ipv6 
     output.default-originate=never 

[admin@rr1] > ipv6 route print
Flags: D - DYNAMIC; A - ACTIVE; c, b, y - COPY
Columns: DST-ADDRESS, GATEWAY, DISTANCE
    DST-ADDRESS        GATEWAY    DISTANCE
DAc 2000::/64          bridge1           0
DAb 4700:1100::/29     2000::111        20
DAc fe80::%bridge1/64  bridge1           0
i tried a little more, because mikrotik support told me, that it only doesn't work ros7 to ros6, which is not true as it seems:

7.4.1 to 7.4.1 with afi ipv4 & ipv6 with src/dst address in ipv4:
[admin@rr1] > routing bgp connection print where disabled=no
Flags: D - dynamic, X - disabled, I - inactive 
 2   name="bgp1-ros7-afi" 
     remote.address=10.230.0.111/32 .as=65001 
     local.default-address=10.230.0.113 .role=ebgp 
     routing-table=main router-id=10.230.0.113 templates=as4711-ros7 as=4711 
     address-families=ip,ipv6 
     output.default-originate=never

[admin@rr1] > ipv6 route print
Flags: D - DYNAMIC; I, A - ACTIVE; c, b, y - COPY; H - HW-OFFLOADED
Columns: DST-ADDRESS, GATEWAY, DISTANCE
     DST-ADDRESS        GATEWAY              DISTANCE
DAc  2000::/64          bridge1                     0
DIbH 4700:1100::/29     ::ffff:10.230.0.111        20
DAc  fe80::%bridge1/64  bridge1                     0
so this is clearly a bug in ros7. i tried same from ros7 to a cisco asr, where i had same non working ipv6 prefixes results like with ros6. ros6 and cisco are just discarding the faulty received ipv6 advertisement from ros7.

ros6 to ros6 and ros6 to cisco etc, above setup works. only when you involve ros7, it just doesn't work.
 
User avatar
mrz
MikroTik Support
MikroTik Support
Posts: 6818
Joined: Wed Feb 07, 2007 12:45 pm
Location: Latvia
Contact:

Re: ros7 bgp ipv6 advertisement doesn't work

Mon Aug 22, 2022 6:23 pm

You can define the source address of the session by setting local.address

And what exactly is the bug in v7? DIbH 4700:1100::/29 ::ffff:10.230.0.111 ?
This route is not a bug, that is what you get when ipv6 prefix is sent over the ipv4 session, gateway is ipv4 mapped address. Exactly the same gateway you get also in ROSv6.
 
mmc
newbie
Topic Author
Posts: 39
Joined: Wed Dec 29, 2004 1:44 am

Re: ros7 bgp ipv6 advertisement doesn't work

Tue Aug 23, 2022 4:32 am

You can define the source address of the session by setting local.address

And what exactly is the bug in v7? DIbH 4700:1100::/29 ::ffff:10.230.0.111 ?
This route is not a bug, that is what you get when ipv6 prefix is sent over the ipv4 session, gateway is ipv4 mapped address. Exactly the same gateway you get also in ROSv6.
thanks for the local.address hint. :)

but for the ipv4 mapped address, there is something 'different' in the ros7 implementation. here is a sample output from a production bgp rr receiving an ipv6 prefix inside an afi ipv4 & ipv6 session over ipv4 from a cisco.
[admin@rr1-812.mynaru] > ipv6 route print where received-from=cdn00.mynaru 
Flags: X - disabled, A - active, D - dynamic, C - connect, S - static, r - rip, o - ospf, b - bgp, U - unreachable 
 #      DST-ADDRESS              GATEWAY                  DISTANCE
 0  Db  3b00:1316::/29           fe80::764d:28ff:fe9b:...       20
same result when the advertiser would be a ros6 box.
when the advertiser is ros7, just no ipv6 prefix shows up in ros6 ipv6 routing table.

dont tell me thats a feature ;)
 
User avatar
mrz
MikroTik Support
MikroTik Support
Posts: 6818
Joined: Wed Feb 07, 2007 12:45 pm
Location: Latvia
Contact:

Re: ros7 bgp ipv6 advertisement doesn't work

Tue Aug 23, 2022 10:42 am

ROSv6 had hacks to guess what ipv6 nexthop to set automatically.
In case of eBGP on a shared network it is easy and we can get and use link-local address, which we will add as a feature in the future.
But in other cases you would still need to adjust nexthop with routing filters according to your needs.
That is why it is recommended to use ipv4 session for ipv4 AFI and a separate ipv6 session for ipv6 afi.
 
wsftech
newbie
Posts: 31
Joined: Wed Jun 10, 2015 12:19 am

Re: ros7 bgp ipv6 advertisement doesn't work

Sat Sep 10, 2022 10:01 pm

ROSv6 had hacks to guess what ipv6 nexthop to set automatically.
In case of eBGP on a shared network it is easy and we can get and use link-local address, which we will add as a feature in the future.
But in other cases you would still need to adjust nexthop with routing filters according to your needs.
That is why it is recommended to use ipv4 session for ipv4 AFI and a separate ipv6 session for ipv6 afi.
If this is true, then why does https://help.mikrotik.com/docs/display/ ... l+Overview mention RFC5549? I'm not finding any guides for this feature in the documentation. If RFC5549 support is not present or broken, the documentation should be updated to reflect this fact.

Who is online

Users browsing this forum: No registered users and 4 guests