My question stems from wanting to have a "loopback" interface on my CCR + CRS devices. A loopback interface is created in RouterOS by creating a bridge interface without any "member" ports in the bridge itself. The documentation will usually call this loopback interface "lobridge".Creating multiple bridges
The devices support only one hardware bridge. If there are multiple bridges created, only one gets hardware offloading. While for L2 that means software forwarding for other bridges, in the case of L3HW, multiple bridges may lead to undefined behavior.
Code: Select all
/interface/bridge/add name=lobridge protocol-mode=none
Scripting example,
Code: Select all
# Disable hardware offloading before making changes on the switch chip
/interface/ethernet/switch/set switch1 l3-hw-offloading=no
# Disable full hardware routing on all ports
/interface/ethernet/switch/port set [ find ] l3-hw-offloading=no
# Enable full hardware routing on interfaces in bridge1
:foreach i in=[ /interface/bridge/port/find where bridge=bridge1 ] do={
/interface/ethernet/switch/port set [ /interface/bridge/port/get $i interface ] l3-hw-offloading=yes
}
# Enable hardware offloading after making changes on the switch chip
/interface/ethernet/switch/set switch1 l3-hw-offloading=no
Code: Select all
# Verify the ports with hardware offloading enabled
/interface/ethernet/switch/port/print where l3-hw-offloading=yes
# Verify the ports with hardware offloading disabled
/interface/ethernet/switch/port/print where l3-hw-offloading=no
# Verify hardware offloading was reenabled on the switch chip
/interface/ethernet/switch/print