Skip to content
MikroTik RouterOS Docs

VPLS - Virtual Private LAN Service

Create a Layer 2 tunnel over MPLS to bridge remote sites transparently.

Prerequisites: MPLS backbone with LDP already configured and running.

# Create VPLS tunnel to remote PE router
/interface vpls add name=vpls-site2 remote-peer=10.255.255.2 vpls-id=100:1 disabled=no
# Add to bridge with local LAN
/interface bridge port add interface=vpls-site2 bridge=bridge-lan

Verify with:

/interface vpls monitor vpls-site2

Look for local-label and remote-label values (indicates tunnel is established).

What this does: VPLS (Virtual Private LAN Service) creates Layer 2 tunnels over an MPLS backbone, enabling transparent Ethernet bridging between geographically separated sites. Remote sites appear to be on the same LAN segment.

When to use this:

  • Connecting multiple sites at Layer 2 over an MPLS network
  • Extending VLANs across WAN connections
  • Service provider Layer 2 VPN offerings
  • When you need better performance than EoIP (~60% faster)

How it works:

  1. VPLS uses two MPLS labels: tunnel label (identifies VPLS instance) and transport label (delivers to remote endpoint)
  2. LDP or BGP signals the pseudowire between PE routers
  3. Ethernet frames are encapsulated in MPLS and forwarded across the backbone
  4. Remote PE router decapsulates and delivers to local bridge

Prerequisites:

  • RouterOS Level 4+ license (MPLS features)
  • MPLS enabled globally on backbone routers
  • LDP (or RSVP-TE/static labels) configured and running
  • IGP routing protocol (OSPF/IS-IS) for label distribution
  • IP reachability to remote peer loopback addresses
Site A MPLS Backbone Site B
[LAN] --- [PE Router] -------- [P Routers] -------- [PE Router] --- [LAN]
10.255.255.1 10.255.255.2
<-------- VPLS Tunnel (vpls-id=100:1) -------->

Create a loopback for MPLS transport addressing:

/interface bridge add name=loopback
/ip address add address=10.255.255.1/32 interface=loopback

OSPF is required for LDP label distribution. Configure OSPF on backbone interfaces:

/routing ospf instance add name=default router-id=10.255.255.1
/routing ospf area add name=backbone area-id=0.0.0.0 instance=default
/routing ospf interface-template add area=backbone interfaces=ether1,loopback

Enable MPLS globally and on backbone interfaces:

/mpls settings set enabled=yes
/mpls interface add interface=ether1

Enable LDP with transport address set to loopback:

/mpls ldp set enabled=yes lsr-id=10.255.255.1 transport-addresses=10.255.255.1
/mpls ldp interface add interface=ether1 transport-addresses=10.255.255.1

Before creating VPLS, verify LDP sessions are established:

/mpls ldp neighbor print

Expected: Remote peer appears with transport address.

Create the VPLS tunnel to the remote PE router:

/interface vpls add name=vpls-site2 remote-peer=10.255.255.2 vpls-id=100:1 disabled=no

Key parameters:

  • remote-peer: Loopback IP of remote PE router
  • vpls-id: Must match on both ends (format: AS:number or IP:number)

Bridge the VPLS tunnel with local LAN interface:

/interface bridge add name=bridge-lan
/interface bridge port add interface=ether2 bridge=bridge-lan
/interface bridge port add interface=vpls-site2 bridge=bridge-lan

Monitor the VPLS interface:

/interface vpls monitor vpls-site2

Expected output:

local-label: 16
remote-label: 17
transport: 10.255.255.2
imposed-labels: 17,18
remote-status:

Connect multiple sites to a central hub:

Hub Router (10.255.255.1):

/interface vpls add name=vpls-spoke1 remote-peer=10.255.255.2 vpls-id=100:1 disabled=no
/interface vpls add name=vpls-spoke2 remote-peer=10.255.255.3 vpls-id=100:1 disabled=no
/interface vpls add name=vpls-spoke3 remote-peer=10.255.255.4 vpls-id=100:1 disabled=no
/interface bridge add name=bridge-vpls
/interface bridge port add interface=vpls-spoke1 bridge=bridge-vpls
/interface bridge port add interface=vpls-spoke2 bridge=bridge-vpls
/interface bridge port add interface=vpls-spoke3 bridge=bridge-vpls
/interface bridge port add interface=ether2 bridge=bridge-vpls

Connect MikroTik to Cisco using static pseudowire ID:

/interface vpls add name=vpls-cisco remote-peer=10.255.255.2 \
cisco-static-id=100 pw-type=vpls disabled=no

Scenario: BGP-Signaled VPLS (Large Networks)

Section titled “Scenario: BGP-Signaled VPLS (Large Networks)”

For autodiscovery in larger deployments:

# Configure BGP with L2VPN address family
/routing bgp connection add name=pe-ibgp remote.address=10.255.255.10 \
local.role=ibgp address-families=l2vpn as=65000
# Create VPLS with BGP signaling
/interface vpls add name=vpls-bgp vpls-id=100:1 \
import-route-targets=65000:100 export-route-targets=65000:100 \
use-bgp-signaling=yes disabled=no

Use traffic-engineered paths instead of LDP:

# Create TE tunnel first
/mpls traffic-eng tunnel-path add name=to-site2 use-cspf=yes
# VPLS uses TE tunnel for transport
/interface vpls add name=vpls-te remote-peer=10.255.255.2 vpls-id=100:1 disabled=no

Transport specific VLAN over VPLS:

/interface vpls add name=vpls-vlan100 remote-peer=10.255.255.2 vpls-id=100:1 \
pw-type=tagged-ethernet disabled=no

MPLS adds overhead to packets. Configure MTU properly to avoid fragmentation:

# Interface MTU (L2 payload)
/interface ethernet set ether1 mtu=1500
# MPLS MTU (must exceed interface MTU + label overhead)
/mpls interface set [find interface=ether1] mpls-mtu=1522

Rule: MPLS MTU = Interface MTU + 22 bytes (for 2 labels + control word)

/interface vpls print

Expected: Shows R (running) flag for active tunnels.

/interface vpls monitor vpls-site2

Expected: Shows local-label, remote-label, and imposed-labels.

/mpls ldp neighbor print

Expected: Remote peer listed with transport address.

/mpls forwarding-table print

Expected: Labels for remote loopbacks.

/interface bridge port print where bridge=bridge-lan

Expected: VPLS interface listed with status=active.

From a host on Site A, ping a host on Site B (same subnet):

/tool ping 192.168.1.100

Expected: Successful replies indicating L2 connectivity.

SymptomCauseSolution
VPLS tunnel not coming upLDP not configured or no route to peerVerify LDP sessions with /mpls ldp neighbor print; check routing
Tunnel running but no trafficVPLS not added to bridgeAdd VPLS interface to bridge
Large packets droppedMTU mismatchSet MPLS MTU at least 22 bytes larger than interface MTU
LDP session won’t establishTransport address not specifiedAdd transport-addresses to LDP interface config
VPLS won’t establish with summary routeSome implementations need /32 routesEnsure specific /32 routes exist for peer loopbacks
v6 config doesn’t work in v7MPLS/routing syntax changedReview v7 documentation; update configuration
BGP-signaled VPLS issues (v7.16+)Known bug with L2VPNCheck MikroTik support; may need workaround

Common Mistakes

  • Missing LDP on loopback - LDP needs transport address on loopback interface
  • Summary routes insufficient - Use /32 routes to peer loopbacks for reliable VPLS
  • MTU not configured - MPLS MTU must exceed interface MTU + label overhead
  • Forgetting to add VPLS to bridge - VPLS interface alone doesn’t bridge traffic
  • Mismatched vpls-id - Both ends must use identical vpls-id value
FeatureVPLSEoIP
Performance~60% fasterSlower
OverheadLower (MPLS)Higher (GRE)
RequirementsMPLS backboneIP connectivity
ComplexityHigherLower
ScalabilityBetterLimited
FragmentationHandled by VPLSIP fragmentation
PropertyTypeDefaultDescription
namestring(required)Interface name
remote-peerIP(required)Remote PE router address (loopback)
vpls-idAS:num or IP:num(required)VPLS identifier (must match both ends)
pw-typeenumraw-ethernetPseudowire type: raw-ethernet, tagged-ethernet, vpls
mtuinteger1500Maximum transmission unit
disabledyes/noyesInterface state
pw-control-wordyes/novariesUse control word in pseudowire
cisco-static-idinteger-Cisco-style static pseudowire ID
use-bgp-signalingyes/nonoUse BGP for autodiscovery
import-route-targetsRT list-BGP route targets to import
export-route-targetsRT list-BGP route targets to export
CommandDescription
/interface vpls addCreate a VPLS tunnel interface
/interface vpls printList all VPLS interfaces with status
/interface vpls monitorReal-time monitoring of tunnel
/interface vpls setModify existing VPLS configuration
/interface vpls removeDelete a VPLS interface
/mpls settings setEnable/configure MPLS globally
/mpls interface addEnable MPLS on an interface
/mpls ldp setConfigure LDP globally
/mpls ldp interface addEnable LDP on an interface
/mpls ldp neighbor printShow LDP neighbor sessions
/mpls forwarding-table printShow MPLS label bindings

VPLS creates Layer 2 tunnels over MPLS for transparent site-to-site bridging:

  1. Configure loopback with /32 address for MPLS transport
  2. Enable OSPF (or other IGP) for label distribution
  3. Enable MPLS globally and on backbone interfaces
  4. Configure LDP with transport address on loopback
  5. Create VPLS interface with matching vpls-id on both ends
  6. Add to bridge to connect VPLS with local LAN

Key points:

  • Requires MPLS backbone with LDP (or BGP/RSVP-TE) for label distribution
  • ~60% faster than EoIP with lower overhead
  • Use /32 routes to peer loopbacks (summary routes may not work)
  • MPLS MTU must exceed interface MTU by at least 22 bytes
  • License Level 4+ required for MPLS features
  • For Cisco interop, use cisco-static-id parameter
  • BGP signaling available for larger networks (autodiscovery)