BGP update only handled on the second keepalive

I have two mikrotik routers: one is hap ax^2, the other is map 2nd.

The map 2nd acts as a road-warrior router.

The map 2nd connects to the office hap through wireguard.

And there is ibgp established between them.

Both advertise several routes to each other.

The problem is: hap inserts the received routes immediately. Map inserts the received route only on next keepalive

I have sniffed the traffic and found out the difference: map 2nd sends two packets: keepalive, followed by update.

While hap ax2 sends one packet which contains both keepalive+update.

They both run the same firmware version - 7.15.3, and the only other difference is that map configured to connect, and hap only to listen.

hap:

3   name="to_ivan-portable"
remote.address=10.240.224.4/32 .as=65020
local.address=10.240.224.224 .role=ibgp
connect=no routing-table=main as=65020 nexthop-choice=force-self
output.default-originate=always
input.filter=to_ivan-portable

map:

0   name="to_vpn_hub_1"
remote.address=10.240.224.224/32 .as=65020
local.address=10.240.224.4 .role=ibgp
listen=no routing-table=wg as=65020
output.network=vpn-wg-bgp-out
input.filter=from_vpn_hub

And in the attachment is the packets: 16 is the one that I suspect which causes the problem, and 17 & 20 are the one that are handled properly.
And second screenshot - is just keepalives, with no updates.

That’s how it looks in logs on map:

08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4:36103, r_addr: 10.240.224.224:179}  Sent OPEN message (0x30190bfd)
08-25 11:31:54 route,bgp,debug,state to_vpn_hub_1-1 {l_addr: 10.240.224.4:36103, r_addr: 10.240.224.224:179}  Entering OpenSent state
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk: false} Received OPEN message
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk: false} OPEN message caps Length: 18
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk: false} OPEN Message cap {Code: route refresh, Length: 0}
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk: false} OPEN Message cap {Code: 4-octet AS, Length: 4}
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk: false} OPEN Message cap {Code: multiprotocol, Length: 4}
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk: false} OPEN Message cap {Code: graceful restart, Length: 2}
08-25 11:31:54 route,bgp,debug,state to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk: false} Entering OpenConfirm state
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk:  true} Sent KEEPALIVE message
08-25 11:31:54 route,bgp,debug,state to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk:  true} Entering Established state
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Starter {openOk:  true} Received KEEPALIVE message
08-25 11:31:54 route,bgp,info to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Established
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Sent KEEPALIVE message
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Recv KEEPALIVEmessage
08-25 11:31:54 route,bgp,debug,packet,update to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Output publish 10.240.224.4@*400
08-25 11:31:54 route,bgp,debug,packet,update to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Output publish 10.240.225.4@*400
08-25 11:31:54 route,bgp,debug,packet,update to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Output publish 10.240.4.0/24@*400
08-25 11:31:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Sent UPDATE message (Length=59)
08-25 11:31:54 route,bgp,debug,packet,update BgpOutput { sk: Socket{ 4 a } #buf:1 max: 64 } : flush UPDATE message (Length=59)
08-25 11:32:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Sent KEEPALIVE message
08-25 11:32:54 route,bgp,debug,packet to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Recv UPDATEmessage (Length =46) (passToInput)
08-25 11:32:54 route,bgp,debug,packet,update to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Input UPDATE message (Length=46)
08-25 11:32:54 route,bgp,debug,packet,update to_vpn_hub_1-1 {l_addr: 10.240.224.4, r_addr: 10.240.224.224} Update { 0.0.0.0/0@*400 }

Screenshot from 2024-08-25 11-35-32.png
Screenshot from 2024-08-25 11-35-23.png