projectcalico / calico

Cloud native networking and network security
https://docs.tigera.io/calico/latest/about/
Apache License 2.0
5.96k stars 1.32k forks source link

Is there any solution to address family redistributing routes for both ipv4 and ipv6 in calico-bird #9013

Open kavana-14 opened 3 months ago

kavana-14 commented 3 months ago

$ bird --version BIRD version v0.3.3+birdv1.6.8

$ k3s --version k3s version v1.29.6+k3s1 (83ae095a) go version go1.21.11

OS: ubuntu 22.04

With calico-bird we are also observing as below:

bird without enable-ipv6 is not distributing ipv6 routes through BGP and bird with enable-ipv6 is not distributing ipv4 routes through BGP Can one address family redistributing routes for both ipv4 and ipv6?

I'm working on kubernetes networking, with Calico cni plugin. I want to configure the BIRD that is available in the ProjectCalico repo. But both ipv4 and v6 are not supported. If I enable ipv6 it won't parse ipv4 address or vice versa.

https://github.com/projectcalico/bird.git //where the repo was cloned installation step: ./configure make make install

bird.conf: protocol static { route 10.0.0.0/24 via 55.55.55.44; route 10.10.0.0/16 blackhole; route 10.20.0.0/20 unreachable; route 10.30.50.0/28 prohibit; route 20.20.20.0/24 via 2001:1::2; }

protocol static { ipv6 { export all; }; route 2001:db8:1::/48 via 5555::6666; route 2001:db8:2::/48 blackhole; route 2001:db8:3::/48 prohibit; route 2001:db8:4::/48 unreachable; }

$ ./bird -d -c ./bird.conf bird: ./bird.conf:27:11 This is an IPv4 router, therefore IPv6 addresses are not supported

I'm expecting it should work fine for both ipv4 and v6 addresses.

MichalFupso commented 3 months ago

Hi @kavana-14, we expect to run one instance of bird per IPV family. Could you share more of what you are trying to achieve and your setup?

kavana-14 commented 3 months ago

@MichalFupso I'm trying to use feature RFC 5549

Setup: ubuntu 22.04 K3s clusters Calico and calicoctl installed BIRD

SarthakPALC commented 3 months ago

Hi @MichalFupso

Wanted to give you more information regarding what exactly we are trying to accomplish. We are trying to use Calico in a setup where ipv4 routes have ipv6 addresses as next-hop and calico-node isn't able to process the corresponding BGP config. The feature originally proposed in RFC 5549 and has been implemented in the original bird project in the following commits-

https://github.com/CZ-NIC/bird/commit/ef57b70fa51687865e5823c0af2df2c6de338215

https://github.com/CZ-NIC/bird/commit/d8022d26fc64121c3416abfdb4c38fcbaf81c12e

Calico's fork of bird doesn't seem to have that, though we could find the feature request a year ago without any information here.

Could you please help us by providing information about if there is a technical reason why it wasn't incorporated into calico? Even some background information would be helpful.

Thanks in advance.

caseydavenport commented 2 months ago

@SarthakPALC I am not aware of there being any fundamental technical reason this hasn't been incorporated. I believe I would characterize this as an enhancement request that needs an owner.