I stumbled upon this thread
http://forum.mikrotik.com/viewtopic.php?f=14&t=32935
and as it's a bit old, I've decided to start another one.
So the scenario is pretty simple:
I have a Cisco router on one end of the connection, on the other end, there's the MikroTik router.
The requirement is to use a VLAN and /31 subnet. i also have to run a BGP session over that connection.
I've build a sample topology in GNS3 and here's the configuration:
1. Cisco router
interface Loopback0
ip address 8.8.8.8 255.255.255.0
!
interface Loopback1
ip address 8.8.4.4 255.255.255.0
!
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.2958
description BGP session to client
encapsulation dot1Q 2958
ip address 212.6.82.0 255.255.255.254
!
!
router bgp 123
no synchronization
bgp router-id 212.6.82.0
bgp log-neighbor-changes
network 8.8.4.0 mask 255.255.255.0
network 8.8.8.0 mask 255.255.255.0
neighbor 212.6.82.1 remote-as 60483
no auto-summary
2. MikroTik router
/interface vlan
add interface=ether1 name=vlan-2958 vlan-id=2958
/ip address
add address=212.6.82.1/31 interface=vlan-2958 network=212.6.82.0
add address=149.13.0.1/25 interface=Loopback0 network=149.13.0.0
/routing bgp instance
set default as=60483 router-id=212.6.82.1
/routing bgp network
add network=149.13.0.0/25 synchronize=no
/routing bgp peer
add name=PE remote-address=212.6.82.0 remote-as=123
The result:
1. Both devices are reachable.
2. The BGP session establishes:
PE#show ip bgp summary
BGP router identifier 212.6.82.0, local AS number 123
BGP table version is 8, main routing table version 8
3 network entries using 351 bytes of memory
3 path entries using 156 bytes of memory
3/2 BGP path/bestpath attribute entries using 372 bytes of memory
1 BGP AS-PATH entries using 24 bytes of memory
0 BGP route-map cache entries using 0 bytes of memory
0 BGP filter-list cache entries using 0 bytes of memory
BGP using 903 total bytes of memory
BGP activity 5/2 prefixes, 5/2 paths, scan interval 60 secs
Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd
212.6.82.1 4 60483 56 51 8 0 0 00:44:24 1
[admin@KA-CE002] > routing bgp peer print
Flags: X - disabled, E - established
# INSTANCE REMOTE-ADDRESS REMOTE-AS
0 E default 212.6.82.0 123
But there's the funny part. Whatever I advertise from the Cisco IOS is listed in the routing table of my MikroTik router. But I cannot reach it, as it's inactive:
[admin@KA-CE002] > 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 Db 8.8.4.0/24 212.6.82.0 20
1 Db 8.8.8.0/24 212.6.82.0 20
2 ADC 149.13.0.0/25 149.13.0.1 Loopback0 0
3 ADC 212.6.82.0/31 212.6.82.1 vlan-2958 0
[admin@KA-CE002] > ping 8.8.8.8
HOST SIZE TTL TIME STATUS
no route to host
no route to host
no route to host
sent=3 received=0 packet-loss=100%
It does seem to work flawlessly on the Cisco end though:
PE#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route
Gateway of last resort is not set
8.0.0.0/24 is subnetted, 2 subnets
C 8.8.4.0 is directly connected, Loopback1
C 8.8.8.0 is directly connected, Loopback0
149.13.0.0/25 is subnetted, 1 subnets
B 149.13.0.0 [20/0] via 212.6.82.1, 00:25:50
212.6.82.0/31 is subnetted, 1 subnets
C 212.6.82.0 is directly connected, FastEthernet0/0.2958
PE#ping 149.13.0.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 149.13.0.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/8/16 ms
So the question is why the RouterOS does not want to make these BGP routes active and use them?