Juniper Networks
Log in
|
How to Buy
|
Contact Us
|
United States (Change)
Choose Country
Close

Choose Country

North America

  • United States

Europe

  • Deutschland - Germany
  • España - Spain
  • France
  • Italia - Italy
  • Россия - Russia
  • United Kingdom

Asia Pacific

  • Asean Region (Vietnam, Indonesia, Singapore, Malaysia)
  • Australia
  • 中国 - China
  • India
  • 日本 - Japan
  • 대한민국 - Korea
  • 台灣 - Taiwan
Solutions
Products & Services
Company
Partners
Support
Education
Community
Security Intelligence Center

Technical Documentation

Support
Technical Documentation
Content Explorer New
 
Enterprise MIBs
 
EOL Documentation
 
Feature Explorer Login required New
 
File Format Help
 
Glossary
 
Portable Libraries
 
 
Home > Support > Technical Documentation > Configuring VLAN Subinterfaces
Print
Rate and give feedback:  Feedback Received. Thank You!
Rate and give feedback: 
Close
This document helped resolve my issue.  Yes No

Additional Comments

800 characters remaining

May we contact you if necessary?

Name:  
E-mail: 
Submitting...
 

Related Documentation

  • VLAN Overview
  • encapsulation ppp
  • encapsulation vlan
  • interface fastEthernet
  • ip address
  • mpls
  • pppoe
  • pppoe subinterface
  • vlan id
 

Configuring VLAN Subinterfaces

Ethernet interfaces support IP, PPPoE, MPLS, or both IP and PPPoE on each VLAN. In addition to a VLAN major interface level, a VLAN subinterface level distinguishes the VLAN.

Note: You cannot configure VLANs on the Fast Ethernet port of the SRP module.

Tasks to configure VLAN subinterfaces are:

  • Creating a VLAN Major Interface
  • Configuring IP over VLAN
  • Configuring PPPoE over VLAN
  • Configuring MPLS over VLAN
  • Configuring IP over VLAN and PPPoE over VLAN

Creating a VLAN Major Interface

To use VLANs, you must first configure the Ethernet interface for VLAN encapsulation. This creates the VLAN major interface.

To configure the Ethernet interface for VLAN encapsulation:

  1. Specify a Fast Ethernet, Gigabit Ethernet, or 10-Gigabit Ethernet port.
    host1(config)#interface fastEthernet 4/0
  2. Specify VLAN as the encapsulation method.
    host1(config-if)#encapsulation vlan

    The router creates the VLAN major interface.

You can now create multiple VLAN subinterfaces to carry higher-level protocols. For examples, see Configuring VLAN Subinterfaces, next.

Configuring IP over VLAN

To configure IP over VLAN over an Ethernet interface:

  1. Specify a Fast Ethernet, Gigabit Ethernet, or 10-Gigabit Ethernet port.
    host1(config)#interface fastEthernet 4/0
  2. Specify VLAN as the encapsulation method.
    host1(config-if)#encapsulation vlan

    The VLAN major interface is added.

  3. Create a VLAN subinterface by adding a subinterface number to the interface identification command.
    host1(config-if)#interface fastEthernet 4/0.3
  4. Do one of the following:
    1. Assign a VLAN ID for the subinterface.
      host1(config-if)#vlan id 201
    2. Assign a VLAN ID and the optional unique MAC address for the subinterface.
      host1(config-if)#vlan id 201 mac-address 0090.1a01.1234
  5. Assign an IP address and mask.
    host1(config-if)#ip address 192.6.129.5 255.255.255.0
  6. (Optional) Configure additional VLAN subinterfaces by completing Steps 3 through 5.

Figure 1 illustrates the IP/VLAN/Fast Ethernet stacking, showing two separate VLAN subinterfaces. Configure one VLAN subinterface entirely; then configure the next VLAN subinterface.

Figure 1: Example of IP/VLAN/Fast Ethernet Stacking Configuration Procedure

Example of IP/VLAN/Fast Ethernet Stacking
Configuration Procedure

Configuring PPPoE over VLAN

To configure PPPoE over VLAN over an Ethernet interface:

  1. Specify a Fast Ethernet, Gigabit Ethernet, or 10-Gigabit Ethernet port.
    host1(config)#interface fastEthernet 4/1
  2. Specify VLAN as the encapsulation method.
    host1(config-if)#encapsulation vlan

    The VLAN major interface is added.

  3. Create a VLAN subinterface by adding a subinterface number to the interface identification command.
    host1(config-if)#interface fastEthernet 4/1.1
  4. Do one of the following:
    • Assign a VLAN ID for the subinterface.
      host1(config-if)#vlan id 201
    • Assign a VLAN ID and the optional unique MAC address for the subinterface.
      host1(config-if)#vlan id 201 mac-address 0090.1a01.1234
  5. Specify PPPoE as the encapsulation method on the interface.
    host1(config-if)#pppoe
  6. Create a PPPoE subinterface.
    host1(config-if)#pppoe subinterface fastEthernet 4/1.1.1
  7. Specify PPP as the encapsulation method on the interface.
    host1(config-if)#encapsulation ppp
  8. Assign an IP address and mask.
    host1(config-if)#ip address 192.6.129.5 255.255.255.0
  9. (Optional) Configure additional VLAN subinterfaces by completing Steps 3 through 8.

Figure 2 illustrates the PPPoE/VLAN/Fast Ethernet stacking, showing two separate VLAN subinterfaces. One VLAN subinterface has two PPPoE subinterfaces, and one VLAN subinterface has one PPPoE subinterface.

Figure 2: Example of PPPoE/VLAN/Fast Ethernet Stacking Configuration Procedure

Example of PPPoE/VLAN/Fast Ethernet Stacking
Configuration Procedure

Configuring MPLS over VLAN

To configure MPLS over VLAN over an Ethernet interface:

  1. Specify a Fast Ethernet, Gigabit Ethernet, or 10-Gigabit Ethernet port.
    host1(config)#interface fastEthernet 4/0
  2. Specify VLAN as the encapsulation method.
    host1(config-if)#encapsulation vlan

    The VLAN major interface is added.

  3. Create a VLAN subinterface by adding a subinterface number to the interface identification command.
    host1(config-if)#interface fastEthernet 4/1.1
  4. Do one of the following:
    • Assign a VLAN ID for the subinterface.
      host1(config-if)#vlan id 400
    • Assign a VLAN ID and the optional unique MAC address for the subinterface.
      host1(config-if)#vlan id 400 mac-address 0090.1a01.1234
  5. Enable MPLS on the interface.
    host1(config-if)#mpls

Figure 3 illustrates the MPLS/VLAN/Fast Ethernet stacking, showing one VLAN subinterface.

Figure 3: Example of MPLS/VLAN/Fast Ethernet Stacking Configuration Procedure

Example of MPLS/VLAN/Fast Ethernet Stacking
Configuration Procedure

Configuring IP over VLAN and PPPoE over VLAN

To configure IP over VLAN with PPPoE over the same VLAN over an Ethernet interface:

  1. Specify a Fast Ethernet, Gigabit Ethernet, or 10-Gigabit Ethernet port.
    host1(config)#interface fastEthernet 4/1
  2. Specify VLAN as the encapsulation method.
    host1(config-if)#encapsulation vlan

    The VLAN major interface is added.

  3. Create a VLAN subinterface by adding a subinterface number to the interface identification command.
    host1(config-if)#interface fastEthernet 4/1.1
  4. Do one of the following:
    • Assign a VLAN ID for the subinterface.
      host1(config-if)#vlan id 400
    • Assign a VLAN ID and the optional unique MAC address for the subinterface.
      host1(config-if)#vlan id 400 mac-address 0090.1a01.1234
  5. Create an IP interface on the same VLAN as the PPPoE interface.
    host1(config-if)#ip address 164.10.6.71 255.255.255.0
  6. Specify PPPoE as the encapsulation method on the interface.
    host1(config-if)#pppoe
  7. Create a PPPoE subinterface.
    host1(config-if)#pppoe subinterface fastEthernet 4/1.1.1
  8. Specify PPP as the encapsulation method on the interface.
    host1(config-if)#encapsulation ppp
  9. Assign an IP address and mask.
    host1(config-if)#ip address 192.6.129.5 255.255.255.0
  10. (Optional) Configure additional PPPoE subinterfaces by completing Steps 7 through 9 using unique numbering.

To configure additional IP interfaces over the VLAN major interface:

  1. Create a new VLAN subinterface by adding a unique subinterface number to the interface identification command.
    host1(config-if)#interface fastEthernet 4/1.2
  2. Assign a VLAN ID for the subinterface.
    host1(config-if)#vlan id 401
  3. Assign an IP address and mask.
    host1(config-if)#ip address 164.10.6.51 255.255.255.0

Figure 4 illustrates the configuration steps for two VLAN subinterfaces. In this example:

  • VLAN subinterface 4/1.1 has an IP interface, a PPPoE interface, and multiple PPPoE subinterface stacks.
  • VLAN subinterface 4/1.2 has only an IP interface.

    Note: Before you can remove a VLAN subinterface, you must remove the upper-layer interface stack.

    Figure 4: Example of PPPoE over VLAN with IP over VLAN Stacking Configuration Procedure

    Example of PPPoE over VLAN with IP over
VLAN Stacking Configuration Procedure
 

Related Documentation

  • VLAN Overview
  • encapsulation ppp
  • encapsulation vlan
  • interface fastEthernet
  • ip address
  • mpls
  • pppoe
  • pppoe subinterface
  • vlan id
 

Published: 2012-06-26

 
  • About Juniper
  • Investor Relations
  • Press Releases
  • Newsletters
  • Juniper Offices
  • Green Networking
  • Resources
  • How to Buy
  • Partner Locator
  • Image Library
  • Visio Templates
  • Security Center
  • Community
  • Forums
  • Blogs
  • Junos Central
  • Social Media
  • Developers
  • Support
  • Technical Documentation
  • Knowledge Base (KB)
  • Software Downloads
  • Product Licensing
  • Contact Support
Site Map / RSS Feeds / Careers / Accessibility / Feedback / Privacy & Policy / Legal Notices
Copyright© 1999-2012 Juniper Networks, Inc. All rights reserved.
Help
|
My Account
|
Log Out