Ethernet Switching
Ethernet Switching

Vlan translation on MX

09.13.17   |  
‎09-13-2017 02:16 AM

Hi,

 

Not sure if this is possible. I want to acheive the following. On my MX104 I have several customer sites handed over to me on different vlans from my provider. These sites needs to share the same subnet with the default gateway on the MX104.  

 

"Vlan rewrite" option on the ge interface doesn't work as the MX won't allow me to translate two different vlans (vlan 100 and 200) to one (vlan 1000). Below is the basic configuration but it obviously doesn't work as there is no vlan translation/rewrite/swap in there. Anyone have any idea on how to acheive this? Please see the descibing picture attached.

 

irb {
     unit 1000 {
           family inet {
                  address 10.1.1.1/24;
           }
     }
}

bridge-domains {
      VLAN_1000 {
                vlan-id 1000;
                routing-interface irb.1000;
         }
}

interfaces {
ge-0/0/0 {
      description "To PROVIDER";
      flexible-vlan-tagging;
      mtu 9192;
      encapsulation flexible-ethernet-services;
      unit 100 {

             description "Customer ACME site 1";
             family bridge {
                    interface-mode trunk;
                    vlan-id-list 100;
             }
     }
     unit 200 {

           description "Customer ACME site 2";
           family bridge {
                  interface-mode trunk;
                  vlan-id-list 200;
          }
   }

Attachments

2 REPLIES
Highlighted
Ethernet Switching
Solution
Accepted by topic author ErAc
‎09-13-2017 11:56 AM

Re: Vlan translation on MX

09.13.17   |  
‎09-13-2017 03:10 AM

I have used bridge domains for this purpose.  

 

In the bridge domain you add the sub-interfaces for all the sites you want to be in the same broadcast domain for the inbound trunk port.  It does not matter what vlan tag they have on this interface.

 

In the bridge domain you assign the vlan tag for your gateway for this broadcast domain.

 

You can then either send that vlan out layer two on another interface towards the gateway.  Or create the IRB layer 3 interface on the MX to serve as the gateway.  If you add the gateway on the MX make sure you consider the routing domain you want the traffic to be in. You might also want to create a virtual router routing instance to isolate that traffic.

 

https://www.juniper.net/documentation/en_US/junos/topics/task/configuration/layer-2-services-bridge-...

Steve Puluka BSEET
Juniper Ambassador
Senior IP Engineer - DQE Communications Pittsburgh, PA (Metro Ethernet & ISP)
JNCIA-Junos JNCIS-SEC JNCIP-SEC JNCSP-SEC
JNCIS-FWV
JNCDA JNCDS-DC JNCDS-SEC
JNCIS-SP
ACE PanOS 6 ACE PanOS 7
http://puluka.com/home
Ethernet Switching

Re: Vlan translation on MX

09.13.17   |  
‎09-13-2017 12:02 PM

Hi Steve,

 

Thanks a lot for the support. I followed your instructions and I got it to work! 

 

This is the working configuration in my case:

 

irb {
     unit 1000 {
           family inet {
                  address 10.1.1.1/24;
           }
     }
}

bridge-domains {
      VLAN_1000 {
                vlan-id 1000;

                interface ge-0/0/0.100;

                interface ge-0/0/0.200;
                routing-interface irb.1000;
         }
}

interfaces {
ge-0/0/0 {
      description "To PROVIDER";
      flexible-vlan-tagging;
      mtu 9192;
      encapsulation flexible-ethernet-services;
      unit 100 {

             description "Customer ACME site 1";
             encapsulation vlan-bridge; 
              vlan-id 100;
     }
     unit 200 {

           description "Customer ACME site 2";
             encapsulation vlan-bridge; 
              vlan-id 200;
   }

 

 

Erac