Commands:
set vrf name <VRF_NAME> protocols bgp address-family <AFI-SAFI> rd vpn export set vrf name <VRF_NAME> protocols bgp address-family <AFI-SAFI> route-target vpn <both|import|export>
can't be used simulatansly with
set vrf name <VRF_NAME> protocols bgp address-family <AFI-SAFI> import vrf
FRR Documentation:
https://docs.frrouting.org/en/latest/bgp.html#clicmd-import-vrf-VRFNAME
Example:
Configuration:
set interfaces ethernet eth0 address '10.0.255.69/27' set interfaces ethernet eth0 vrf 'ROUTER' set interfaces ethernet eth1 address '10.0.40.3/28' set interfaces ethernet eth1 vrf 'CUSTOMER' set protocols bgp parameters router-id '10.0.255.33' set protocols bgp system-as '65011' set vrf name CUSTOMER protocols bgp address-family ipv4-unicast rd vpn export '65011:1050' set vrf name CUSTOMER protocols bgp address-family ipv4-unicast redistribute connected set vrf name CUSTOMER protocols bgp address-family ipv4-unicast route-target vpn both '65011:1050' set vrf name CUSTOMER protocols bgp system-as '65011' set vrf name CUSTOMER table '300' set vrf name ROUTER protocols bgp address-family ipv4-unicast rd vpn export '65011:1011' set vrf name ROUTER protocols bgp address-family ipv4-unicast redistribute connected set vrf name ROUTER protocols bgp address-family ipv4-unicast import vrf CUSTOMER set vrf name ROUTER protocols bgp address-family ipv4-unicast route-target vpn both '65011:1011' set vrf name ROUTER protocols bgp address-family ipv4-unicast route-target vpn import '65011:1050' set vrf name ROUTER protocols bgp system-as '65011' set vrf name ROUTER table '301'
After commit:
[email protected]# commit [ vrf name ROUTER protocols bgp ] VyOS had an issue completing a command. We are sorry that you encountered a problem while using VyOS. There are a few things you can do to help us (and yourself): - Contact us using the online help desk if you have a subscription: https://support.vyos.io/ - Make sure you are running the latest version of VyOS available at: https://vyos.net/get/ - Consult the community forum to see how to handle this issue: https://forum.vyos.io - Join us on Slack where our users exchange help and advice: https://vyos.slack.com When reporting problems, please include as much information as possible: - do not obfuscate any data (feel free to contact us privately if your business policy requires it) - and include all the information presented below Report time: 2022-12-14 13:18:22 Image version: VyOS 1.4-rolling-202212140319 Release train: current Built by: [email protected] Built on: Wed 14 Dec 2022 03:19 UTC Build UUID: e7e5e020-4c8c-4fbb-8759-abde5bc1d5c4 Build commit ID: f56f9f9d7bc169 Architecture: x86_64 Boot via: installed image System type: KVM guest Hardware vendor: QEMU Hardware model: Standard PC (i440FX + PIIX, 1996) Hardware S/N: Hardware UUID: c9f6d6c0-6735-4d1b-8f67-1c330fba19a1 Traceback (most recent call last): File "/usr/libexec/vyos/conf_mode/protocols_bgp.py", line 388, in <module> apply(c) File "/usr/libexec/vyos/conf_mode/protocols_bgp.py", line 379, in apply frr_cfg.commit_configuration(bgp_daemon) File "/usr/lib/python3/dist-packages/vyos/frr.py", line 480, in commit_configuration raise ConfigurationNotValid(f'Config commit retry counter ({count_max}) exceeded for {daemon} dameon!') vyos.frr.ConfigurationNotValid: Config commit retry counter (5) exceeded for bgpd dameon! [[vrf name ROUTER protocols bgp]] failed [ vrf name CUSTOMER protocols bgp ] VyOS had an issue completing a command. We are sorry that you encountered a problem while using VyOS. There are a few things you can do to help us (and yourself): - Contact us using the online help desk if you have a subscription: https://support.vyos.io/ - Make sure you are running the latest version of VyOS available at: https://vyos.net/get/ - Consult the community forum to see how to handle this issue: https://forum.vyos.io - Join us on Slack where our users exchange help and advice: https://vyos.slack.com When reporting problems, please include as much information as possible: - do not obfuscate any data (feel free to contact us privately if your business policy requires it) - and include all the information presented below Report time: 2022-12-14 13:18:26 Image version: VyOS 1.4-rolling-202212140319 Release train: current Built by: [email protected] Built on: Wed 14 Dec 2022 03:19 UTC Build UUID: e7e5e020-4c8c-4fbb-8759-abde5bc1d5c4 Build commit ID: f56f9f9d7bc169 Architecture: x86_64 Boot via: installed image System type: KVM guest Hardware vendor: QEMU Hardware model: Standard PC (i440FX + PIIX, 1996) Hardware S/N: Hardware UUID: c9f6d6c0-6735-4d1b-8f67-1c330fba19a1 Traceback (most recent call last): File "/usr/libexec/vyos/conf_mode/protocols_bgp.py", line 388, in <module> apply(c) File "/usr/libexec/vyos/conf_mode/protocols_bgp.py", line 379, in apply frr_cfg.commit_configuration(bgp_daemon) File "/usr/lib/python3/dist-packages/vyos/frr.py", line 480, in commit_configuration raise ConfigurationNotValid(f'Config commit retry counter ({count_max}) exceeded for {daemon} dameon!') vyos.frr.ConfigurationNotValid: Config commit retry counter (5) exceeded for bgpd dameon! [[vrf name CUSTOMER protocols bgp]] failed Commit failed [edit]