Page MenuHomeVyOS Platform

DHCP default route issues with static routes in VRFs
Closed, ResolvedPublicBUG

Description

  1. When a VRF has a DHCP default route, adding a static route to the VRF removes the default route from the VRF.
  2. When the default VRF has a DHCP default route, adding a static route to a VRF duplicates the default route in the VRF.

Setup:

set vrf name MGMT table 100
set interfaces ethernet eth0 vrf MGMT
set interfaces ethernet eth0 address dhcp
commit
sleep 10
vtysh -c 'show running-config'
Building configuration...

Current configuration:
!
frr version 8.4.2
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
vrf MGMT
 ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
exit-vrf
!
rpki
exit
!
end

Note the presence of a default route in the VRF.


Bug #1:

set vrf name MGMT protocols static route 1.1.1.1/32 dhcp-interface eth0
commit
vtysh -c 'show running-config'
Building configuration...

Current configuration:
!
frr version 8.4.2
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
vrf MGMT
 ip route 1.1.1.1/32 192.168.128.1 eth0
exit-vrf
!
rpki
exit
!
end

Note the absence of a default route in the VRF.


Reset (avoiding T5103):

delete interfaces ethernet eth0 address
delete vrf name MGMT protocols
commit
delete interfaces ethernet eth0 vrf
commit
set interfaces ethernet eth0 address dhcp
commit
sleep 10
vtysh -c 'show running-config'
Building configuration...

Current configuration:
!
frr version 8.4.2
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
!
rpki
exit
!
end

Note the presence of a default route in the default VRF.


Bug #2:

set vrf name MGMT protocols static route 1.1.1.1/32 dhcp-interface eth0
commit
vtysh -c 'show running-config'
Building configuration...

Current configuration:
!
frr version 8.4.2
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
!
vrf MGMT
 ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
 ip route 1.1.1.1/32 192.168.128.1 eth0
exit-vrf
!
rpki
exit
!
end

Note the default route is duplicated in the VRF.

Details

Version
1.4-rolling-202303170317
Is it a breaking change?
Perfectly compatible
Issue type
Bug (incorrect behavior)

Event Timeline

stepler changed the task status from Open to In progress.
stepler claimed this task.
syncer triaged this task as Normal priority.Mar 21 2023, 6:50 PM
stepler edited a custom field.
stepler changed Is it a breaking change? from Unspecified (possibly destroys the router) to Perfectly compatible.
stepler changed Issue type from Unspecified (please specify) to Bug (incorrect behavior).
c-po changed the task status from In progress to Needs testing.Mar 21 2023, 7:55 PM

Looks good on 1.4-rolling-202303271007:

set vrf name MGMT table 100
set interfaces ethernet eth0 vrf MGMT
set interfaces ethernet eth0 address dhcp
commit
sleep 10
vtysh -c 'show running-config'

vtysh_pam: Failed in account validation: Success(0)Building configuration...

Current configuration:
!
frr version 8.5
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
vrf MGMT
 ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
exit-vrf
!
rpki
exit
!
end

set vrf name MGMT protocols static route 1.1.1.1/32 dhcp-interface eth0
commit
vtysh -c 'show running-config'
vtysh_pam: Failed in account validation: Success(0)Building configuration...

Current configuration:
!
frr version 8.5
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
vrf MGMT
 ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
 ip route 1.1.1.1/32 192.168.128.1 eth0
exit-vrf
!
rpki
exit
!
end

delete interfaces ethernet eth0 address
delete vrf name MGMT protocols
commit
delete interfaces ethernet eth0 vrf
commit
set interfaces ethernet eth0 address dhcp
commit
sleep 10
vtysh -c 'show running-config'
vtysh_pam: Failed in account validation: Success(0)Building configuration...

Current configuration:
!
frr version 8.5
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
!
rpki
exit
!
end

set vrf name MGMT protocols static route 1.1.1.1/32 dhcp-interface eth0
commit
vtysh -c 'show running-config'
vtysh_pam: Failed in account validation: Success(0)Building configuration...

Current configuration:
!
frr version 8.5
frr defaults traditional
hostname vyos
log syslog
log facility local7
service integrated-vtysh-config
!
ip route 0.0.0.0/0 192.168.128.1 eth0 tag 210 210
!
vrf MGMT
 ip route 1.1.1.1/32 192.168.128.1 eth0
exit-vrf
!
rpki
exit
!
end

vyos@vyos:~$ show version
Version:          VyOS 1.4-rolling-202303271007
Release train:    current

Built by:         autobuild@vyos.net
Built on:         Mon 27 Mar 2023 10:07 UTC
Build UUID:       71d83095-0dc3-4fa8-a23e-285b938552a0
Build commit ID:  d68bda6a295ba9

Architecture:     x86_64
Boot via:         livecd
System type:       guest

Hardware vendor:  QEMU
Hardware model:   Standard PC (Q35 + ICH9, 2009)
Hardware S/N:     
Hardware UUID:    cc81ba04-0592-527c-8fcb-3d8cc3cbdd5c

Copyright:        VyOS maintainers and contributors