Interface and Hardware Component Command Reference, Cisco IOS XE Release 3SE (Catalyst 3850 Switches)
I through K
Downloads: This chapterpdf (PDF - 1.39MB) The complete bookPDF (PDF - 3.37MB) | Feedback

I through K

I through K

interface

To configure an interface type and to enter interface configuration mode, use the interface command in the appropriate configuration mode.

Standard Syntax

interface type number [name-tag]

Module-Specific and Platform-Specific Syntax

Analysis Module Network Module

interface analysis-module slot /unit

Content Engine Network Module

interface content-engine slot /unit

Cisco 830 Series

interface type [number]

Cisco 2600 Series

interface type slot/ { port-adapter | port . subinterface-number }

Cisco 2600 Series on Voice Interfaces

interface type slot /voice-module-slot /voice-interface-slot

Cisco 3600 Series

interface type slot/ { port | port . subinterface-number }

Cisco 3600 Series on Voice Interfaces

interface type slot /voice-module-slot /voice-interface-slot

Cisco 7100 Series

interface type slot/ { port-adapter | port . subinterface-number }

Cisco 7200 Series and Cisco 7500 Series with a Packet over SONET Interface Processor

interface type slot /port

Cisco 7200 VXR Router Used as a Router Shelf in a Cisco AS5800 Universal Access Server

interface type router-shelf /slot /port

Cisco 7500 Series with Channelized T1 or E1

interface serial slot /port : channel-group

Cisco 7500 Series with Ports on VIP Cards

interface type slot /port-adapter /port

Cisco 7600 Series

interface type number

Note: The number format varies depending on the network module or line card type and the router’s chassis slot it is installed in. Refer to the appropriate hardware manual for numbering information

Cisco 7600 Series with Ports on Ethernet Service Cards

interface type slot /bay /port access

Note: The syntax may vary depending on the Ethernet service line card type. Refer to the appropriate hardware manual for numbering information. For example, for the ES20 line card the syntax takes the following format:

Subinterface Syntax Forms in Global Configuration Mode

Cisco 7200 Series

interface type slot /port . subinterface-number [ multipoint | point-to-point ]

Cisco 7500 Series

interface type slot /port-adapter . subinterface-number [ multipoint | point-to-point ]

Cisco 7500 Series with Ports on VIP Cards

interface type slot /port-adapter /port . subinterface-number [ multipoint | point-to-point ]

Cisco ASR 901 Series Aggregation Services Routers

no interface type number

Shared Port Adapters

interface type slot /subslot /port [ . subinterface-number ]

Syntax Description

type

Type of interface to be configured. See the table below.

number

Port, connector, or interface card number. On Cisco 830 series routers, the numberargumentspecifies the ethernet interface number. On Cisco 4700 series routers, the number argument specifies the network interface module (NIM) or network processor module (NPM) number. The numbers are assigned at the factory at the time of installation or when added to a system; they can be displayed with the showinterfaces command. For Cisco ASR 901 Series Aggregation Services Routers, the range is from 1 to 8.

name-tag

(Optional) Specifies the logic name to identify the server configuration so that multiple server configurations can be entered.

This optional argument is for use with the Redundant Link Manager (RLM) feature.

slot

Chassis slot number.

Refer to the appropriate hardware manual for slot information. For SIPs, refer to the platform-specific SPA hardware installation guide or the corresponding "Identifying Slots and Subslots for SIPs and SPAs" topic in the platform-specific SPA software configuration guide.

/ voice-module-slot

Voice module slot number. The slash(/)is required.

Refer to the “Cisco 3700 Series Routers Voice Interface Numbering” section of the “Understanding Interface Numbering and Cisco IOS Basics” chapter in the platform-specific SPA software configuration guide.

/ voice-interface-slot

Voice interface slot number. The slash(/)is required.

Refer to the “Cisco 3700 Series Routers Voice Interface Numbering” section of the “Understanding Interface Numbering and Cisco IOS Basics” chapter in the platform-specific SPA software configuration guide.

/ subslot

Secondary slot number on a SIP where a SPA is installed. The slash (/) is required.

Refer to the platform-specific SPA hardware installation guide and the corresponding "Specifying the Interface Address on a SPA" topic in the platform-specific SPA software configuration guide for subslot information.

/ unit

Number of the daughter card on the network module. For analysis module and content engine (CE) network modules, always use 0. Theslash(/)is required.

/bay

Card interface bay number in a slot. Theslash(/)is required.

Refer to the appropriate hardware manual for bay information.

/ port

Port or interface number. Theslash(/)is required.

Refer to the appropriate hardware manual for port information. For SPAs, refer to the corresponding “Specifying the Interface Address on a SPA” topics in the platform-specific SPA software configuration guide.

router-shelf

Router shelf number in a Cisco AS5800 universal access server. Refer to the appropriate hardware manual for router shelf information.

: channel-group

Channel group number. Cisco 7500 series routers specify the channel group number in the range of 0 to 4 defined with the channel-group controller configuration command.

/ port-adapter

Port adapter number. Refer to the appropriate hardware manual for information about port adapter compatibility. Theslash(/) is required.

. subinterface-number

Subinterface number in the range 1 to 4294967293. The number that precedes the period (.) must match the number to which this subinterface belongs.

access

Creates an access interface for an IP subscriber. The access interface is configured as a subinterface of the physical interface that the IP subscriber is connected to.

multipoint | point-to-point

(Optional) Specifies a multipoint or point-to-point subinterface. There is no default .

Command Default

No interface types are configured.

Command Modes

Global configuration (config)

RITE configuration (config-rite)


Note


To use this command with the RLM feature, the networking device must be in interface configuration mode.


Command History

Release

Modification

10.0

This command was introduced for the Cisco 7000 series routers.

11.0

This command was implemented on the Cisco 4000 series routers.

12.0(3)T

The optional name-tagargument was added for the RLM feature.

12.2(13)T

The content-engine keyword was added.

12.2(15)T

The lex keyword was removed because the LAN Extension feature is no longer available in Cisco IOS software.

12.2(20)S2

This command was implemented for SPAs on the Cisco 7304 router.

12.3(4)T

The serviceengine keyword was added. Support was added for the interface command to be used in RITE configuration mode to support IP trfaffic export profiles.

12.3(7)T

The analysis-module keyword was added.

12.2(22)S

Support for RITE configuration mode and IP traffic export profiles was added.

12.3(14)T

The satellite keyword was added to support satellite interface configuration on network modules.

12.2(18)SXE

This command was implemented for SPAs on the Cisco 7600 series routers and Catalyst 6500 series switches.

12.0(31)S

This command was implemented for SPAs on the Cisco 12000 series routers.

12.2(18)SXF

The tengigabitethernet keyword was added for support of the10 Gigabit Ethernet interface type.

12.2(28)SB

This command was integrated into Cisco IOS Release 12.2(28)SB.

12.2(33)SRA

This command was integrated into Cisco IOS Release 12.2(33)SRA.

Cisco IOS XE 2.1

This command was implemented on Cisco ASR 1000 series routers.

15.1(2)SNG

This command was implemented on Cisco ASR 901 Series Aggregation Services Routers.

15.1(2)SNG

This command was implemented on Cisco ASR 901 Series Aggregation Services Routers.

Usage Guidelines

This command does not have a no form except for Cisco ASR 901 Series Aggregation Services Routers.

The table below displays the keywords that represent the types of interfaces that can be configured with the interface command. Replace the type argument with the appropriate keyword from the table.

Table 1 Interface Type Keywords

Keyword

Interface Type

analysis-module

Analysis module interface. The analysis module interface is a Fast Ethernet interface on the router that connects to the internal interface on the Network Analysis Module (NAM). This interface cannot be configured for subinterfaces or for speed, duplex mode, and similar parameters. See the command-line interface (CLI) help for a list of valid parameters.

async

Port line used as an asynchronous interface.

atm

ATM interface.

bri

ISDN BRI. This interface configuration is propagated to each of the B channels. B channels cannot be individually configured. The interface must be configured with dial-on-demand commands in order for calls to be placed on that interface.

content-engine

Content engine (CE) network module interface. The CE network module interface cannot be configured for subinterfaces or for speed, duplex mode, and similar parameters. See the command-line interface (CLI) help for a list of valid parameters.

Note   

The content-engine keyword was formerly documented as the interfacecontent-engine command.

dialer

Dialer interface.

ethernet

Ethernet IEEE 802.3 interface.

fastethernet

100-Mbps Ethernet interface. In RITE configuration mode, specifies the outgoing (monitored) interface for exported IP traffic.

Note   

The fastethernet keyword was formerly documented as the interfacefastethernet command.

fddi

FDDI interface.

gigabitethernet

1000-Mbps Ethernet interface.

Note   

The gigabitethernet keyword was formerly documented as the interfacegigabitethernet command.

group-async

Master asynchronous interface.

Note   

The group-async keyword was formerly documented as the interfacegroup-async command.

hssi

High-Speed Serial Interface (HSSI).

loopback

Software-only loopback interface that emulates an interface that is always up. It is a virtual interface supported on all platforms. The number argument is the number of the loopback interface that you want to create or configure. There is no limit on the number of loopback interfaces that you can create.

null

Null interface.

port-channel

Port channel interface.

Note   

The port-channel keyword was formerly documented as the interfaceport-channel command.

pos

Packet OC-3 interface on the Packet-over-SONET (POS) interface processor.

Note   

The pos keyword was formerly documented as the interfacepos command.

Satellite

Satellite network module. Enters satellite configuration mode.

sdcc

Section data communications channel interface.

serial

Serial interface.

service-engine

Network module (NM) or an Advanced Integration Module (AIM), this command may be used for NMs and AIMs only. If your system does not have this hardware, you will be unable to enter this command. The no form of this command (no interface service-engine) is not available. The exit command can be used to exit interface configuration mode.

switch

Switch interface.

tengigabitethernet

10-Gigabit Ethernet interface.

tokenring

Token Ring interface.

tunnel

Tunnel interface; a virtual interface. The number argument is the number of the tunnel interface that you want to create or configure. There is no limit on the number of tunnel interfaces that you can create.

vg-anylan

100VG-AnyLAN port adapter.

Note   

The vg-anylan keyword was formerly documented as the interfacevg-anylan command.

Creating an IP Traffic Export Profile

Ip traffic export is intended only for software switching platforms; distributed architectures are not supported.

After you configure an IP traffic export profile using the iptraffic-exportprofileglobal configuration command, you must also include the interfacecommand after the iptraffic-exportprofilecommand; otherwise, the profile will be unable to export the captured IP packets. If you do not use the interface command, you will receive a warning that indicates that the profile is incomplete.

Subinterfaces

Subinterfaces can be configured to support partially meshed Frame Relay networks. Refer to the “Configuring Serial Interfaces” chapter in the CiscoIOSInterfaceandHardwareComponentConfigurationGuide.

Using the analysis-module Keyword

The analysis module interface is used to access the NAM console for the initial configuration. After the NAM IP parameters are configured, the analysis module interface is typically used only during NAM software upgrades and while troubleshooting if the NAM Traffic Analyzer is inaccessible.

Visible only to the Cisco IOS software on the router, the analysis module interface is an internal Fast Ethernet interface on the router that connects to the internal NAM interface. The analysis module interface is connected to the router’s Peripheral Component Interconnect (PCI) backplane, and all configuration and management of the analysis module interface must be performed from the Cisco IOS CLI.

Using the group-async Keyword

Using the group-async keyword, you create a single asynchronous interface with which other interfaces are associated as members using the group-rangecommand. This one-to-many configuration allows you to configure all associated member interfaces by entering one command on the group master interface, rather than entering this command on each individual interface. You can create multiple group masters on a device; however, each member interface can be associated only with one group.

Using the port-channel Keyword

The Fast EtherChannel feature allows multiple Fast Ethernet point-to-point links to be bundled into one logical link to provide bidirectional bandwidth of up to 800 Mbps. You can configure the port-channel interface as you would any Fast Ethernet interface.

After you create a port-channel interface, you assign upto four Fast Ethernet interfaces to it. For information on how to assign a Fast Ethernet interface to a port-channel interface, refer to the channel-group command in the interface configuration mode.


Caution


The port-channel interface is the routed interface. Do not enable Layer 3 addresses on the physical Fast Ethernet interfaces. Do not assign bridge groups on the physical Fast Ethernet interfaces because doing so creates loops. Also, you must disable spanning tree.



Caution


With Release 11.1(20)CC, the Fast EtherChannel supports Cisco Express Forwarding (CEF) and distributed Cisco Express Forwarding (dCEF). We recommend that you clear all explicitiproute-cachedistributed commands from the Fast Ethernet interfaces before enabling dCEF on the port-channel interface. Clearing the route cache gives the port-channel interface proper control of its physical Fast Ethernet links. When you enable CEF/dCEF globally, all interfaces that support CEF/dCEF are enabled. When CEF/dCEF is enabled on the port-channel interface, it is automatically enabled on each of the Fast Ethernet interfaces in the channel group. However, if you have previously disabled CEF/dCEF on the Fast Ethernet interface, CEF/dCEF is not automatically enabled. In this case, you must enable CEF/dCEF on the Fast Ethernet interface.


As you work with the port-channelkeyword, consider the following points:

  • Currently, if you want to use the Cisco Discovery Protocol (CDP), you must configure it only on the port-channel interface and not on the physical Fast Ethernet interface.
  • If you do not assign a static MAC address on the port-channel interface, the Cisco IOS software automatically assigns a MAC address. If you assign a static MAC address and then later remove it, Cisco IOS software automatically assigns a MAC address.
  • The access keyword creates an ethernet channel access interface for an IP subscriber and is specific to Cisco 7600 series routers only. For more information on access interface, see IP Subscriber Interfaces.

Using the vg-anylan Keyword

The 100VG-AnyLAN port adapter provides a single interface port that is compatible with and specified by IEEE 802.12. The 100VG-AnyLAN port adapter provides 100 Mbps over Category 3 or Category 5 cable with RJ-45 terminators and supports IEEE 802.3 Ethernet packets.

You configure the 100VG-AnyLAN port adapter as you would any Ethernet or Fast Ethernet interface. The 100VG-AnyLAN port adapter can be monitored with the IEEE 802.12 Interface MIB.

Cisco ASR 901 Series Aggregation Services Routers

The first EtherChannel interface configured becomes the bundled master for all EtherChannel interfaces in the group. That is, the MAC address of the first EtherChannel interface is the MAC address for all EtherChannel interfaces in the group. If the first EtherChannel interface is removed at any time, the second EtherChannel interface becomes the bundled master by default.

Repeat this configuration on every EtherChannel port to be bundled into a Fast Ether Channel (FEC) or Gigabit Ether Channel (GEC) group. This configuration must be present on all EtherChannel interfaces before the EtherChannel group can be configured.

Examples

The following example configures an analysis module interface when the NAM router is in router slot 1:

Router(config)# interface analysis-module 1/0

Examples

The following example shows how to define asynchronous group master interface 0:

Router(config)# interface group-async 0

Examples

The following example configures an interface for a content engine network module in slot 1:

Router(config)# interface content-engine 1/0

Examples

The following example configures a new ethernet2interface on the LAN or on the WAN side of the Cisco 830 series router.

c837# configure terminal
 
Enter configuration commands, one per line.  End with CNTL/Z.
c837(config)# interface ethernet 2

Examples

The following example shows how to configure Ethernet port 4 on the Ethernet Interface Processor (EIP) in slot 2 on the Cisco 7500 series router:

Router(config)# interface ethernet 2/4

Examples

The following example shows how to configure the profile “corp1,” which will send captured IP traffic to host “00a.8aab.90a0” at the interface “FastEthernet 0/1.” This profile is also configured to export one in every 50 packets and to allow incoming traffic only from the access control list “ham_ACL.”

Router(config)# ip traffic-export profile corp1
Router(config-rite)# interface FastEthernet 0/1
Router(config-rite)# bidirectional
Router(config-rite)# mac-address 00a.8aab.90a0
Router(config-rite)# outgoing sample one-in-every 50
Router(config-rite)# incoming access-list ham_acl
Router(config-rite)# exit
Router(config)# interface FastEthernet 0/0
Router(config-if)# ip traffic-export apply corp1

Examples

The following example shows how to configure Fast Ethernet interface 0 on a Cisco 2600 series router:

Router(config)# interface fastethernet0/0

or

Router(config)# interface fastethernet0/0.1

Examples

The following example shows how to configure Fast Ethernet interface 0 on a Cisco 3600 series router:

Router(config)# interface fastethernet0/0

or

Router(config)# interface fastethernet0/0.1

Examples

The following example shows how to configure Fast Ethernet interface 0 for standard ARPA encapsulation (the default setting) on a Cisco 4700 series router:

Router(config)# interface fastethernet 0

Examples

The following example shows how to configure Fast Ethernet interface 0 on a Cisco 7100 series router:

Router(config)# interface fastethernet0/0

or

Router(config)# interface fastethernet0/0.1

Examples

The following example shows how to configure Fast Ethernet interface 6 on a Cisco 12000 series router:

Router(config)# interface fastethernet6/0

or

Router(config)# interface fastethernet6/0.1

Examples

The following example shows how to configure the Gigabit Ethernet interface for slot 0, port 0:

Router(config)# interface gigabitethernet 0/0

Examples

The following example shows how to specify the second interface (1) on a Gigabit Ethernet SPA installed in the first subslot of a SIP (0) installed in chassis slot 3:

Router(config)# interface gigabitethernet 3/0/1

Examples

The following example shows how to enable loopback mode and assign an IP network address and network mask to the interface. The loopback interface established here will always appear to be up.

Router(config)# interface loopback 0
Router(config-if)# ip address 10.108.1.1 255.255.255.0

Examples

The following example shows how to specify the single Packet OC-3 interface on port 0 of the POS OC-3 port adapter in slot 2:

Router(config)# interface pos 2/0

Examples

The following example shows how to configure a partially meshed Frame Relay network. In this example, subinterface serial 0.1 is configured as a multipoint subinterface with two associated Frame Relay permanent virtual connections (PVCs), and subinterface serial 0.2 is configured as a point-to-point subinterface.

Router(config)# interface serial 0
Router(config-if)# encapsulation frame-relay
Router(config-if)# exit
Router(config)# interface serial 0/0.1 multipoint
Router(config-if)# ip address 10.108.10.1 255.255.255.0
Router(config-if)# frame-relay interface-dlci 42 broadcast
Router(config-if)# frame-relay interface-dlci 53 broadcast
Router(config-if)# exit
Router(config)# interface serial 0/0.2 point-to-point
Router(config-if)# ip address 10.108.11.1 255.255.255.0
Router(config-if)# frame-relay interface-dlci 59 broadcast

Examples

The following example shows how to create a port-channel interface with a channel group number of 1 and add two Fast Ethernet interfaces to port-channel 1:

Router(config)# interface port-channel 1
Router(config-if)# ip address 10.1.1.10 255.255.255.0
Router(config-if)# exit
Router(config)# interface fastethernet 1/0/0
Router(config-if)# channel-group 1
Router(config-if)# exit
Router(config)# interface fastethernet 4/0/0
Router(config-if)# channel-group 1

Examples

The following example configures the first interface (port 0) as a section data communications channel (SDCC) interface on a POS SPA, where the SPA is installed in the top subslot (0) of the MSC, and the MSC is installed in slot 4 of the Cisco 7304 router:

Router(config)# interface sdcc 4/3/0 
Router(config-if)# ip address 10.1.9.2 255.255.255.0 
Router(config-if)# logging event link-status 
Router(config-if)# load-interval 30 
Router(config-if)# no keepalive 
Router(config-if)# no fair-queue 
Router(config-if)# no cdp enable 

Examples

The following example shows how to configure serial interface 0 with PPP encapsulation:

Router(config)# interface serial 0
Router(config-if)# encapsulation ppp

Examples

The following example configures the second interface (port 1) on a 4-Port 10/100 Fast Ethernet SPA for standard ARPA encapsulation (the default setting), where the SPA is installed in the bottom subslot (1) of the MSC, and the MSC is installed in slot 2 of the Cisco 7304 router:

Router(config)# interface fastethernet 2/1/1

Examples

The following example shows how to configure circuit 0 of a T1 link for PPP encapsulation:

Router(config)# controller t1 4/1
Router(config-controller)# circuit 0 1
Router(config-controller)# exit
Router(config)# interface serial 4/1:0
Router(config-if)# ip address 10.108.13.1 255.255.255.0
Router(config-if)# encapsulation ppp

Examples

The following example shows how to configure the Token Ring interface processor in slot 1 on port 0 of a Cisco 7500 series router:

Router(config)# interface tokenring 1/0

Examples

The following example shows how to specify the 100VG-AnyLAN port adapter in the first port adapter in slot 1:

Router(config)# interface vg-anylan 1/0/0

Related Commands

Command

Description

channel-group

Defines the time slots that belong to each T1 or E1 circuit.

channel-group (Fast EtherChannel)

Assigns a Fast Ethernet interface to a Fast EtherChannel group.

clear interface

Resets the hardware logic on an interface.

controller

Configures an E1, J1, T1, or T3 controller and enters controller configuration mode.

group-range

Creates a list of asynchronous interfaces that are associated with a group interface on the same device.

ip traffic-export profile

Create or edit an IP traffic export profile.

mac-address

Sets the MAC layer address.

ppp

Starts an asynchronous connection using PPP.

show controllers content-engine

Displays controller information for CE network modules.

show interfaces

Displays information about interfaces.

show interfaces

Displays information about interfaces.

show interfaces content-engine

Displays basic interface configuration information for a CE network module.

shutdown (RLM)

Shuts down all of the links under the RLM group.

slip

Starts a serial connection to a remote host using SLIP.

interface fastethernet

The interfacefastethernetcommand is now documented as the fastethernetkeyword of the interface command. For more information, see the interface command.

interface gigabitethernet

The interfacegigabitethernetcommand is now documented as the gigabitethernetkeyword of the interface command. For more information, see the interface command.

interface port-channel

The interfaceport-channel command is now documented as the port-channelkeyword of the interface command. For more information, see the interface command.

interface range

To execute commands on multiple subinterfaces at the same time, use the interfacerange command in global configuration mode.

interface range { type number [ [-interface number ] ] [,]... type number | macro word }

no interface range type number

Syntax Description

type number

Interface type and interface or subinterface number. For more information about the numbering syntax for your networking device, use the question mark (?) online help function.

  • You can enter any number of interface type and numbers.

- interface-number

(Optional) Ending interface number.

,

Allows you to configure more interface types.

macro

Specifies a macro keyword.

word

Previously defined keyword, up to 32 characters long.

Command Default

No interface range is set.

Command Modes

Global configuration (config)

Command History

Release

Modification

12.0(7)XE

This command was introduced.

12.1(5)T

This command was integrated into Cisco IOS Release 12.1(5)T.

12.2(2)DD

This command was expanded to support subinterface ranges.

12.2(4)B

This command was integrated into Cisco IOS Release 12.2(4)B.

12.2(8)T

This command was integrated into Cisco IOS Release 12.2(8)T.

12.2(18)SX

This command was integrated into Cisco IOS Release 12.2(18)SX.

12.2(33)SXH

The create keyword was added to enable the creation of VLANs that operate within a specified range of physical interfaces.

Usage Guidelines

Configuration Changes

All configuration changes made to a range of subinterfaces are saved to NVRAM, but the range itself does not get saved to NVRAM. Use the defineinterfacerange command to create and save a range.

You can enter the range in two ways:

  • Specifying up to five interface ranges
  • Specifying a previously defined macro

You can specify either the interfaces or the name of a range macro. A range must consist of the same interface type, and the interfaces within a range cannot span slots.

You cannot specify both the interfacerangeand macro keywords in the same command. After creating a macro, the command does not allow you to enter additional ranges. Likewise, if you have already specified an interface range, the command does not allow you to enter a macro.

The spaces around the hyphen in the interfacerange command syntax are required. For example, using a Catalyst 6500 router, the command interfacerangefastethernet1-6is valid; the command interfacerangefastethernet1-6is not valid.

VLANs

When you define a Catalyst VLAN, valid values are from 1 to 4094. The last VLAN number cannot exceed 4094.

You cannot use the interfacerange command to create switch virtual interfaces (SVIs) in that particular range. You can use the interfacerange command only to configure existing VLAN SVIs within the range. To display VLAN SVIs, enter the showrunning-config command. VLANs not displayed cannot be used in the interfacerange command.

The commands entered under theinterfacerange command are applied to all existing VLAN SVIs within the range.

You can enter the command interfacerangecreatevlanx-y to create all VLANs in the specified range that do not already exist. If you are using discontiguous VLANs, you can use the interfacerangevlan command to configure multiple SVIs without creating unneeded SVIs and wasting interface descriptor blocks (IDBs).

After specifying a VLAN range, you can continue using the interfacerange command to specify another interface (ATM, FastEthernet, GigabitEthernet, loopback, port-channel, or tunnel).

Examples

Examples

The following example shows how to use the interfacerange command to configure a Fast Ethernet range:

Router(config)# interface range fastethernet 5/1 - 4
 

The following example configures the Fast Ethernet subinterfaces within the range 5/1.1 to 5/1.4 and applies the following VLAN IDs to those subinterfaces:

Fast Ethernet5/1.1 = VLAN ID 301 (vlan-id)
Fast Ethernet5/1.2 = VLAN ID 302 (vlan-id = 301 + 2 - 1 = 302)
Fast Ethernet5/1.3 = VLAN ID 303 (vlan-id = 301 + 3 - 1 = 303)
Fast Ethernet5/1.4 = VLAN ID 304 (vlan-id = 301 + 4 - 1 = 304)
Router(config)# interface range fastethernet 5/1 - 4
 
Router(config-if-range)# encapsulation dot1q 301
Router(config-if-range)# no shutdown
 
Router(config-if)#
*Oct  6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/1.1, changed state to up
*Oct  6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/1.2, changed state to up
*Oct  6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/1.3, changed state to up
*Oct  6 08:24:35: %LINK-3-UPDOWN: Interface FastEthernet5/1.4, changed state to up
*Oct  6 08:24:36: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/1.1, changed state to up
*Oct  6 08:24:36: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/1.2, changed state to up
*Oct  6 08:24:36: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/1.3, changed state to up
*Oct  6 08:24:36: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet5/1.4, changed state to up

Examples

The following example shows how to set a Gigabit Ethernet range:

Router(config)# interface range gigabitethernet 1/1 - 6

Examples

The following example shows how to use the loopback interface:

Router(config)# interface range loopback 34567

Examples

The following example shows how to use the tunnel interface:

Router(config)# interface range tunnel 55555

Examples

The following example shows how to use the port-channel interface:

Router(config)# interface range port-channel 100

Examples

The following example shows how to set a VLAN:

Router(config)# interface range vlan 123

The following example shows how to create a range of VLANs:

Router(config)# interface range create vlan 4

Examples

The following example shows how to execute a range macro:

Router(config)# interface range macro macro1

Related Commands

Command

Description

define interface range

Defines an interface range macro.

encapsulation dot1q

Applies a unique VLAN ID to each subinterface within the range.

interface vlan

Configures a VLAN interface.