VRF create weird default route + incorrect syntax


I’m trying to setup VRF for my management interface to introduce specific routing scheme.

set vrf name mgmt table 1000
set interfaces eth0 vrf mgmt
set interfaces eth0 address x.x.x.x

Then, documentation says that to add a route inside my VRF, I should use this syntax :

 set protocols vrf <name> static route <subnet> next-hop <address> 

But this does not exist (anymore?). Here is the syntax I found out :

set vrf name mgmt protocols static route  <subnet> next-hop <address>


set vrf name mgmt protocols static route next-hop x.x.x.254

After I add this route, it’s not displayed within routing table (sh ip route vrf mgmt) :

 K>* [255/8192] unreachable...
 C>* is directory connected

Problems :

  • My specific route is not displayed
  • A dummy default route appears in my routing table after VRF create
  • Syntax does not match the doc

Here is generated routing config :

Screenshot 2021-03-24 065657


Will be fixed in the next rolling

Upgraded to latest build (VyOS 1.4-rolling-202103251004). Route is now correctly displayed inside VRF (syntax still does not match doc btw).

But VRF routing still showing unreachable default route :

vyos@vyos:~$ sh ip route vrf mgmt
Codes: K - kernel route, C - connected, S - static, R - RIP,
       O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP,
       T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP,
       F - PBR, f - OpenFabric,
       > - selected route, * - FIB route, q - queued, r - rejected, b - backup

VRF mgmt:
K>* [255/8192] unreachable (ICMP unreachable), 00:05:29
S>* [1/0] via, eth0, weight 1, 00:00:18
C>* is directly connected, eth0, 00:00:18

I have the feeling that this default route is inherited from outside VRF.


 This high metric value ensures that the default unreachable route can
   be overridden by a routing protocol suite.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.