Skip to end of metadata
Go to start of metadata

"Yet another routing/forwarding network stack ... made by network engineers ..."

Overview

RARE (Router for Academia, Research & Education) is an ongoing effort under the GÉANT 3rd programme which focus on determining if a routing software platform solution can fit R&E use cases. The project aims to integrate different pieces of software related to these building blocks:

  • control plane: RARE uses FreeRouter under the hood used as the control plane component
  • data plane(not only P4) P4 behavioural language is used to describe the packet processing behaviour of RARE data plane
  • and communication interface between the control plane and data plane: Interface compliant to P4Runtime specification ensure this function

A key part of the work consists in enabling a control plane software to pilot a data plane via a programmatic interface.

Resulting work

  • Software interface that maps the forwarding state used by a an Open source control plane (FreeRouter)
  •  to programmable data plane running RARE software

P4 is an example of language proposing an interface that allows data plane programmability.

Note

P4 core language attempts to be as much as possible independent from the target or NPU processor architecture. However architecture dependance is still prominent. Code adjustments followed by a target specific compilation is necessary if you want to run your p4 program on a specific architecture.

RARE project includes the following partners under GÉANT GN4-3 programme

Getting started

Select and install a P4 data-plane target platform architecture

 BMv2
 ubuntu 18.04
sudo add-apt-repository ppa:frederic-loui/p4lang-3rd-party 
sudo apt-get update

sudo add-apt-repository ppa:frederic-loui/p4lang-master-bionic-nightly
sudo apt-get update
 ubuntu 20.04
sudo add-apt-repository ppa:frederic-loui/p4lang-3rd-party-focal 
sudo add-apt-repository ppa:frederic-loui/p4lang-master-focal-nightly 
sudo apt-get update
 debian 10
echo 'deb https://download.opensuse.org/repositories/home:/frederic-loui:/p4lang:/p4c/Debian_10/  ./" | sudo tee /etc/apt/source.list.d/p4lang.list
sudo apt-get update
 TOFINO

Software for TOFINO NPU is subject to a Software License and Confidentiality Agreement (SLACA)

If you are an R&E organization please submit an application via INTEL/BAREFOOT FASTER portal

From there you'll be able to install INTEL/BAREFOOT P4Studio also call BAREFOOT Software Development Environment (SDE)

Install FreeRouter control-plane

 ubuntu 18.04 & 20.04
sudo add-apt-repository ppa:frederic-loui/freerouter-nightly
sudo apt-get update
sudo apt-get install freerouter-native freerouter
 debian 10
echo 'deb https://download.opensuse.org/repositories/home:/frederic-loui:/freerouter/Debian_10/  ./" | sudo tee /etc/apt/source.list.d/p4lang.list
sudo apt-get update

Install RARE software

 BMv2
git clone https://github.com/frederic-loui/RARE.git
 TOFINO

Before anything, you'll have to install BAREFOOT SDE following BAREFOOT instruction. TOFINO code can be found here: (From GÉANT Bitbucket RARE repository)

https://bitbucket.software.geant.org/projects/RARE/repos/rare/browse

git clone https://bitbucket.software.geant.org/scm/rare/rare.git

(in compliance with INTEL/BAREFOOT announcement that grant the publication of the P4 code)

Build & Run RARE software

 BMv2 with P4Runtime (simple_swicth_grpc) 
cd 02-PE-labs/0001-vpn-over-bgp-isis-sr-operation
make

in order stop the whole setup:

cd 02-PE-labs/0001-vpn-over-bgp-isis-sr-operation
make clean
 TOFINO with BFRuntime (bf_switchd)
 On virtual TOFINO model

Compile P4 bf_router.p4 program

  • with MPLS profile
export RARE=/home/p4 
$SDE/tools/p4_build.sh -I$RARE/p4src/ -DHAVE_MPLS -DHAVE_BRIDGE $RARE/p4src/bf_router.p4
  • with SRv6 profile
export RARE=/home/p4 
$SDE/tools/p4_build.sh -I$RARE/p4src/ -DHAVE_SRV6 -DHAVE_BRIDGE -DHAVE_NAT $RARE/p4src/bf_router.p4

run TOFINO model

cd $SDE 
./run_tofino_model.sh -p bf_router .

run TOFINO bf_switchd

cd $SDE 
./run_switchd.sh -p bf_router

run Freerouter control plane

cd $RARE/02-PE-labs/0001-vpn-over-bgp-isis-sr-operation 
./make

in order to stop FreeRouter

cd $RARE/02-PE-labs/0001-vpn-over-bgp-isis-sr-operation 
./make clean

run bf_forwarder.py interface

cd $RARE/bfrt_python 
./bf_forwarder.py
 On hardware WEDGEBF10032X

Compile P4 bf_router.p4 program

  • with MPLS profile
export RARE_PATH=/home/p4 
$SDE/tools/p4_build.sh -I$RARE/p4src/  -DHAVE_MPLS -DHAVE_BRIDGE -D_WEDGE100BF32X_ $RARE/p4src/bf_router.p4
  • with SRv6 profile
export RARE=/home/p4 
$SDE/tools/p4_build.sh -I$RARE/p4src/ -DHAVE_SRV6 -DHAVE_BRIDGE -DHAVE_NAT -D_WEDGE100BF32X_ $RARE/p4src/bf_router.p4

run TOFINO bf_switchd

cd $SDE 
./run_switchd.sh -p bf_router

run Freerouter control plane.   

cd $RARE/100-WEDGE-100BF-32X/0001-vpn-over-bgp-isis-sr-operation 
./make

in order to stop FreeRouter

cd $RARE/100-WEDGE-100BF-32X/0001-vpn-over-bgp-isis-sr-operation 
./make clean

run bf_forwarder.py interface

cd $RARE/bfrt_python 
./bf_forwarder.py

Documentation

Control plane

FreeRouter

FreeRouter is a free, open source router os process. It speaks routing protocols, and (re)encapsulates packets on interfaces (a huge list of encapsulation and routing test cases can be found under self-test page) since it handles packets itself, it is independent of underlaying os capabilities (optionally, it can export forwarding tables through openflow or p4 to external switch) since it is an unprivilegized process, it receives and sends packets through sockets there are external, privileged processes that place traffic to these sockets (it means that internet can be used as backplane for router processes) the command line tries to mimic the industry standards with one exception: no global routing table: every routed interface must be in a virtual routing table positive side effect: there are no vrf-awareness questions

This control plane supports a tremendous amount of features, in addition  FreeRouter lead developer is part of the RARE team, which dramatically increases development effort related to control Plane/data plane interface communication. 

Your own custom control plane

You can adapt your own control plane as soon as it is compliant to RARE dataplane P4 interface. It is recommended though to use FreeRouter as it was built and test against it. RARE P4 data plane interface will be published subsequently. For the brave one or people who are in a hurry, just look at bf_forwarder message loop.

Dataplane: P4 targets

  • BMv2

BMv2 is the open source P4 switch developed and maintained by the P4Lang p4.org group. It can be downloaded here. It uses the V1Model P4 Switch Architecture depicted below:

  • TOFINO target

Similar to BMv2, TOFINO uses the PSA - Portable Switch Architecture. However, while BMv2 is a P4 virtual software switch TOFINO (and his older brother TOFINO 2) is a network processor able to switch packet at tremendous line rate.

While BMv2 is an excellent alternative to learn and develop P4 algorithm, TOFINO & TOFINO 2 open the gate to exciting use cases in real production environment.

More information can be found here.

Software for TOFINO NPU is subject to a Software License and Confidentiality Agreement (SLACA)

If you are an R&E organization please submit an application via INTEL/BAREFOOT FASTER portal

  • FPGA target

Porting RARE on FPGA is an on-going effort, this target is perfect for enabling RARE/FreeRouter on FPGA card that are produced massively and thus present a very interesting TCO. 

  • DPDK target

P4 hardware target like TOFINO enable LSR/LER use cases. But in certain context, acquiring P4 hardware for SOHO use cases (primary/secondary schools, small R&E instituions) is financially not possible. In that context, we propose a solution that leverage existing kernel bypass machanism such as DPDK. The resulting work is the creation of p4dpdk which is inherently an emulation of RARE software running on P4 target but written entirely from scratch in C code.  



Current status

All the features mentioned below are IPv4/IPv6 compliant. As the project is an on-going work in-progress,  the documentation can not reflect all the supported features. The below list is not exhaustive. Please do not hesitate to contact us for more details.

 Interior Routing Protocol
Featurestatuscomment
IS-IS

COMPLETED

-
OSPF

COMPLETED

-
EIGRP

COMPLETED

-
LSRP

COMPLETED

Link State Routing Protocol (FreeRouter specific IGP)
PVRP

COMPLETED

Path Vector Routing Protocol (FreeRouter specific IGP)
 Dataplane forwarding
Featurestatuscomment
LDP

COMPLETED

Label Distribution Protocol label distribution control protocol 
IS-IS-SR

COMPLETED

IS-IS - Segment Routing extension
OSPF-SR

COMPLETED

OSPF - Segment Routing extension
LSRP-SR

COMPLETED

Link State Routing Protocol - Segment Routing extension

VPLS-LDP

COMPLETED

Virtual Private LAN Service (VPLS) - Using Label Distribution Protocol (LDP) Signaling

 External Routing Protocol
Featurestatuscomment
RFC4271

COMPLETED

BGP
RFC4456

COMPLETED

BGP Route reflection
RFC5065

COMPLETED

BGP Confederation
RFC7911

COMPLETED

BGP add-paths
RFC5364

COMPLETED

BGP/MPLS IP Virtual Private Networks

RFC4761

COMPLETED

Virtual Private LAN Service (VPLS) - Using BGP for Auto-Discovery and Signalling

RFC4762

COMPLETED

Virtual Private LAN Service (VPLS) - Using LDP for Auto-Discovery and Signalling

RFC6624

COMPLETED

Layer 2 Virtual Private Networks - Using BGP for Auto-Discovery and Signalling

 Link local protocol
Featurestatuscomment
LLDP

COMPLETED

Link Local Discovery protocol
LACP

COMPLETED

Link Aggregation Protocol
CDP

COMPLETED

Cisco Discovery Protocol
BFD

COMPLETED

Bidirectional Forwarding Detection

BFD off-load

FEASABILITY STUDY

BFP off-load to the hardware
 Network management
Featurestatuscomment
TACACS

COMPLETED

-
TELNET

COMPLETED

-
SSH

COMPLETED

-
Lightweight SNMP

ON-GOING

-

Packet postcard telemetry

FEASABILITY STUDY

-
INT

FEASABILITY STUDY

Inband Network Network Telemetry

Complete feature list

Type Test # Name

acl

01

copp

acl

02

ingress access list

acl

03

egress access list

acl

04

nat

acl

05

vlan ingress access list

acl

06

vlan egress access list

acl

07

bundle ingress access list

acl

08

bundle egress access list

acl

09

bundle vlan ingress access list

acl

10

bundle vlan egress access list

acl

11

bridge ingress access list

acl

12

bridge egress access list

acl

13

vlan bridge ingress access list

acl

14

vlan bridge egress access list

acl

15

ingress pppoe access list

acl

16

egress pppoe access list

acl

17

ingress vlan pppoe access list

acl

18

egress vlan pppoe access list

acl

19

hairpin ingress access list

acl

20

hairpin egress access list

acl

21

hairpin vlan ingress access list

acl

22

hairpin vlan egress access list

acl

23

hairpin pppoe ingress access list

acl

24

hairpin pppoe egress access list

acl

25

hairpin vlan pppoe ingress access list

acl

26

hairpin vlan pppoe egress access list

acl

27

ingress gre access list

acl

28

egress gre access list

acl

29

ingress vlan gre access list

acl

30

egress vlan gre access list

acl

31

ingress l2tp access list

acl

32

egress l2tp access list

acl

33

ingress vlan l2tp access list

acl

34

egress vlan l2tp access list

acl

35

ingress ipip access list

acl

36

egress ipip access list

acl

37

ingress vlan ipip access list

acl

38

egress vlan ipip access list

acl

39

ingress common access list

acl

40

egress common access list

acl

41

ingress hibryd access list

acl

42

egress hibryd access list

acl

43

ingress hierarchical access list

acl

44

egress hierarchical access list

crypt

01

macsec with des

crypt

02

macsec with 3des

crypt

03

macsec with aes128

crypt

04

macsec with aes192

crypt

05

macsec with aes256

crypt

06

macsec with md5

crypt

07

macsec with sha1

crypt

08

macsec with sha256

crypt

09

macsec with sha512

crypt

10

macsec over ethernet

crypt

11

macsec over vlan

crypt

12

macsec over bundle vlan

crypt

13

macsec over gre

crypt

14

macsec over pppoe

crypt

15

macsec over l2tp

crypt

16

macsec over hairpin

crypt

17

macsec ingress access list

crypt

18

macsec egress access list

crypt

19

macsec vlan ingress access list

crypt

20

macsec vlan egress access list

crypt

21

ipsec with des

crypt

22

ipsec with 3des

crypt

23

ipsec with aes128

crypt

24

ipsec with aes192

crypt

25

ipsec with aes256

crypt

26

ipsec with md5

crypt

27

ipsec with sha1

crypt

28

ipsec with sha256

crypt

29

ipsec with sha512

crypt

30

ipv4 over ipsec

crypt

31

ipv6 over ipsec

crypt

32

ipsec over ipv4

crypt

33

ipsec over ipv6

crypt

34

ipsec over ipv4 loopback

crypt

35

ipsec over ipv6 loopback

crypt

36

ipsec over vlan

crypt

37

ipv4 over ipsec with ingress access list

crypt

38

ipv4 over ipsec with egress access list

crypt

39

ipv6 over ipsec with ingress access list

crypt

40

ipv6 over ipsec with egress access list

crypt

41

ipsec with ike1

crypt

42

ipsec with ike2

crypt

43

openvpn with des

crypt

44

openvpn with 3des

crypt

45

openvpn with aes128

crypt

46

openvpn with aes192

crypt

47

openvpn with aes256

crypt

48

openvpn with md5

crypt

49

openvpn with sha1

crypt

50

openvpn with sha256

crypt

51

openvpn with sha512

crypt

52

openvpn over ipv4

crypt

53

openvpn over ipv6

crypt

54

openvpn over ipv4 loopback

crypt

55

openvpn over ipv6 loopback

crypt

56

openvpn over asymmetric ports

crypt

57

openvpn with ingress access list

crypt

58

openvpn with egress access list

crypt

59

wireguard over ipv4

crypt

60

wireguard over ipv6

crypt

61

wireguard over ipv4 loopback

crypt

62

wireguard over ipv6 loopback

crypt

63

wireguard over vlan

crypt

64

wireguard over asymmetric ports

crypt

65

wireguard with ingress access list

crypt

66

wireguard with egress access list

rout

01

routing

rout

02

bridging

rout

03

mpls core

rout

04

mpls edge

rout

05

vlan routing

rout

06

vlan bridging

rout

07

vlan mpls

rout

08

vpn with bgp

rout

09

vpls/ldp with bgp

rout

10

evpn/cmac with bgp

rout

11

eompls

rout

12

vpn with bgp over srv6

rout

13

evpn/cmac with bgp over srv6

rout

14

bundle routing

rout

15

bundle mpls

rout

16

bundle vlan routing

rout

17

bundle vlan mpls

rout

18

bundle vlan bridging

rout

19

bridge routing

rout

20

bridge mpls

rout

21

vlan bridge routing

rout

22

vlan bridge mpls

rout

23

vlan vpls/ldp with bgp

rout

24

vlan eompls

rout

25

bundle vlan vpls/ldp with bgp

rout

26

bundle vlan eompls

rout

27

pppoe routing

rout

28

vlan pppoe routing

rout

29

pppoe mpls

rout

30

vlan pppoe mpls

rout

31

hairpin routing

rout

32

hairpin bridging

rout

33

hairpin mpls

rout

34

hairpin vlan routing

rout

35

hairpin vlan bridging

rout

36

hairpin vlan mpls

rout

37

hairpin pppoe routing

rout

38

hairpin vlan pppoe routing

rout

39

hairpin pppoe mpls

rout

40

hairpin vlan pppoe mpls

rout

41

hairpin vpls/ldp with bgp

rout

42

hairpin vlan vpls/ldp with bgp

rout

43

hairpin eompls

rout

44

hairpin vlan eompls

rout

45

vlan evpn/cmac with bgp

rout

46

bundle vlan evpn/cmac with bgp

rout

47

hairpin evpn/cmac with bgp

rout

48

hairpin vlan evpn/cmac with bgp

rout

49

gre routing over ipv4

rout

50

gre routing over ipv6

rout

51

gre routing over ipv4 loopback

rout

52

gre routing over ipv6 loopback

rout

53

gre routing over vlan

rout

54

gre routing over bundle

rout

55

gre routing over bundle vlan

rout

56

gre routing over hairpin

rout

57

gre routing over hairpin vlan

rout

58

gre routing over bridge

rout

59

gre routing over vlan bridge

rout

60

gre mpls over ipv4

rout

61

gre mpls over ipv6

rout

62

gre mpls over ipv4 loopback

rout

63

gre mpls over ipv6 loopback

rout

64

gre mpls over vlan

rout

65

gre mpls over bundle

rout

66

gre mpls over bundle vlan

rout

67

gre mpls over hairpin

rout

68

gre mpls over hairpin vlan

rout

69

gre mpls over bridge

rout

70

gre mpls over vlan bridge

rout

71

l2tp routing over ipv4

rout

72

l2tp routing over ipv6

rout

73

l2tp routing over ipv4 loopback

rout

74

l2tp routing over ipv6 loopback

rout

75

l2tp routing over vlan

rout

76

l2tp routing over bundle

rout

77

l2tp mpls over ipv4

rout

78

l2tp mpls over ipv6

rout

79

l2tp mpls over ipv4 loopback

rout

80

l2tp mpls over ipv6 loopback

rout

81

l2tp mpls over vlan

rout

82

l2tp mpls over bundle

rout

83

bridging over gre

rout

84

bridging over gre vlan

rout

85

bridging over pppoe

rout

86

bridging over pppoe vlan

rout

87

bridging over l2tp

rout

88

bridging over l2tp vlan

rout

89

vxlan over ipv4

rout

90

vxlan over ipv6

rout

91

vxlan over ipv4 loopback

rout

92

vxlan over ipv6 loopback

rout

93

vxlan over vlan

rout

94

vxlan over bundle

rout

95

evpn/vxlan with bgp

rout

96

vlan evpn/vxlan with bgp

rout

97

bundle vlan evpn/vxlan with bgp

rout

98

hairpin evpn/vxlan with bgp

rout

99

ipip routing over ipv4

rout

100

ipip routing over ipv6

rout

101

ipip routing over ipv4 loopback

rout

102

ipip routing over ipv6 loopback

rout

103

ipip routing over vlan

rout

104

ipip routing over bundle

rout

105

pckoudp over ipv4

rout

106

pckoudp over ipv6

rout

107

pckoudp over ipv4 loopback

rout

108

pckoudp over ipv6 loopback

rout

109

pckoudp over vlan

rout

110

pckoudp over bundle

rout

111

pckoudp server over ipv4

rout

112

pckoudp server over ipv6

rout

113

pckoudp server over ipv4 loopback

rout

114

pckoudp server over ipv6 loopback

rout

115

vxlan server over ipv4

rout

116

vxlan server over ipv6

rout

117

vxlan server over ipv4 loopback

rout

118

vxlan server over ipv6 loopback

rout

119

pppoe server routing

rout

120

vlan pppoe server routing

rout

121

pppoe server mpls

rout

122

vlan pppoe server mpls

rout

123

l2tp server routing

rout

124

vlan l2tp server routing

rout

125

l2tp server mpls

rout

126

vlan l2tp server mpls

rout

127

p2p ldp tail+head

rout

128

p2p ldp mid

rout

129

p2p te tail+head

rout

130

p2p te mid

rout

131

sr te over mpls tail+head

rout

132

sr te over mpls mid


Contact us

  • We can be reached here: 

rare@lists.geant.org

  • We have also a RARE users mailing list: 

rare-users@lists.geant.org

  • and RARE developers mailing list: 

rare-dev@lists.geant.org

  • RARE/freeRouter Twitter contact

@rare_freerouter

Feel free to suscribe !

  • No labels