Find the answer to your Linux question:
Results 1 to 3 of 3

Thread: Vrf

Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1


    1. for multiple intefaces in a VRF and regarding to performance v.s. resource usage, do i have to create a bridge per interface , or a single bridge for all interfaces in the VRF?
    2. is it possible to connect the VRF without any bridge ?
    Thanks. Avi

  2. #2

    I guess you mean network namespace??.


    You can add a network namespace by issuing:
    ip netns add myvrf

    (confirm by
    ip netns list

    add virtual interfaces to the namespace:
    ip link add veth0 type veth peer name veth1
    ifconfig veth0 up
    ip link set veth1 netns myvrf

    Add the virtual interface to a bridge:
    brctl addbr br0
    brctl addif br0 eth0 veth0

    add ip and route for the namespace virtual interface:
    ip netns exec myvrf ifconfig veth1 netmask up
    ip netns exec myvrf route add default gw

    e.g: run a rounting daemon in the namespace:
    ip netns exec myvrf /sbin/

    2. for network namespaces, no, bridge is required if you want to connect to the physical world.

  3. #3
    You can use macvlan or dot1Q-interfaces for netns

    macvlan usage:
    ip link add link eth0 macvlan1 type macvlan
    ip link add link eth0 macvlan2 type macvlan
    ip link set dev macvlan1 netns VRF1
    ip link set dev macvlan2 netns VRF1
    ip netns exec VRF1 ifconfig macvlan1 X.Y.Z.2/24 up
    ip netns exec VRF2 ifconfig macvlan2 X.Y.Z.3/24 up

  4. $spacer_open

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts