Table Of Contents
Configuring Layer 3 Interfaces
Layer 3 Interfaces Overview
Logical Layer 3 VLAN Interfaces
Physical Layer 3 Interfaces
Configuration Guidelines
Configuring Logical Layer 3 VLAN Interfaces
Configuring Physical Layer 3 Interfaces
Configuring Layer 3 Interfaces
This chapter describes the Layer 3 interfaces on the Catalyst 4006 switch with Supervisor Engine III. It also provides guidelines, procedures, and configuration examples.
This chapter consists of the following sections:
•
Layer 3 Interfaces Overview
•
Configuration Guidelines
•
Configuring Logical Layer 3 VLAN Interfaces
•
Configuring Physical Layer 3 Interfaces
Note
For complete syntax and usage information for the commands used in this chapter, refer to the Command Reference for the Catalyst 4006 Switch with Supervisor Engine III and the publications at the following URL:
http://www.cisco.com/univercd/cc/td/doc/product/software/ios121/121cgcr/index.htm
Layer 3 Interfaces Overview
The Catalyst 4006 switch with Supervisor Engine III supports Layer 3 interfaces with the Cisco IOS IP and IP routing protocols. In the OSI reference model, Layer 3 is the network layer and is primarily responsible for the routing of data in packets across logical internetwork paths.
Layer 2 is the data link layer, which contains the protocols that control the physical layer (Layer 1) and how data is framed before being transmitted on the medium. The Layer 2 function of filtering and forwarding data in frames between two segments on a LAN is known as bridging.
The Catalyst 4006 switch with Supervisor Engine III supports two types of Layer 3 interfaces. The logical Layer 3 VLAN interfaces integrate the functions of routing and bridging. The physical Layer 3 interfaces allow the Catalyst 4006 switch with Supervisor Engine III to be configured like a traditional router.
This section contains the following subsections:
•
Logical Layer 3 VLAN Interfaces
•
Physical Layer 3 Interfaces
Logical Layer 3 VLAN Interfaces
The logical Layer 3 VLAN interfaces provide logical routing interfaces to VLANs on Layer 2 switches. A traditional network requires a physical interface from a router to a switch to perform inter-VLAN routing. The Catalyst 4006 switch with Supervisor Engine III supports inter-VLAN routing by integrating the routing and bridging functions on a single Catalyst 4006 switch with Supervisor Engine III.
Figure 10-1 shows how the routing and bridging functions in the three physical devices of the traditional network are performed logically on one Catalyst 4006 switch with Supervisor Engine III.
Figure 10-1 Logical Layer 3 VLAN Interfaces for the Catalyst 4006 Switch with Supervisor Engine III
Physical Layer 3 Interfaces
The physical Layer 3 interfaces support capabilities equivalent to a traditional router. These Layer 3 interfaces provide hosts with physical routing interfaces to the Catalyst 4006 switch with Supervisor Engine III.
Figure 10-2 shows how the Catalyst 4006 switch with Supervisor Engine III function as traditional routers.
Figure 10-2 Physical Layer 3 Interfaces for the Catalyst 4006 with Supervisor Engine III
Configuration Guidelines
The Catalyst 4006 switch with Supervisor Engine III does not support:
•
Subinterfaces or the encapsulation keyword on Layer 3 Fast Ethernet or Gigabit Ethernet interfaces
•
IPX routing and Appletalk routing
Configuring Logical Layer 3 VLAN Interfaces
Note
Before you can configure logical Layer 3 VLAN interfaces, you must create the VLANs on the switch, configure the VLANs on the switch, assign VLAN membership to the Layer 2 interfaces, enable IP routing if IP routing is disabled, and specify an IP routing protocol.
To configure logical Layer 3 VLAN interfaces, perform this task:
| |
Task
|
Command
|
Step 1
|
Create the VLAN.
|
Switch(config)# vlan vlan_ID
|
Step 1
|
Select an interface to configure.
|
Switch(config)# interface vlan vlan_ID
|
Step 2
|
Configure the IP address and IP subnet.
|
Switch(config-if)# ip address ip_address
subnet_mask
|
Step 3
|
Enable the interface.
|
Switch(config-if)# no shutdown
|
Step 4
|
Exit configuration mode.
|
|
Step 5
|
Save your configuration changes to NVRAM.
|
Switch# copy running-config startup-config
|
Step 6
|
Verify the configuration.
|
Switch# show interfaces [type slot/interface]
Switch# show ip interfaces [type slot/interface]
Switch# show running-config interfaces [type
slot/interface]
Switch# show running-config interfaces vlan
vlan_ID
|
This example shows how to configure the logical Layer 3 VLAN interface vlan 2 and assign an IP address:
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# interface vlan 2
Switch(config-if)# ip address 10.1.1.1 255.255.255.248
Switch(config-if)# no shutdown
This example uses the show interfaces command to display the interface IP address configuration and status of Layer 3 VLAN interface vlan 2:
Switch# show interfaces vlan 2
Vlan2 is up, line protocol is down
Hardware is Ethernet SVI, address is 00D.588F.B604 (bia 00D.588F.B604)
Internet address is 172.20.52.106/29
MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
ARP type: ARPA, ARP Timeout 04:00:00
Last input never, output never, output hang never
Last clearing of "show interface" counters never
Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
Output queue: 0/40 (size/max)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
0 packets input, 0 bytes, 0 no buffer
Received 0 broadcasts, 0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
0 packets output, 0 bytes, 0 underruns
0 output errors, 0 interface resets
0 output buffer failures, 0 output buffers swapped out
This example uses the show running-config command to display the interface IP address configuration of Layer 3 VLAN interface vlan 2:
Switch# show running-config
Building configuration...
Current configuration : !
ip address 10.1.1.1 255.255.255.248
Configuring Physical Layer 3 Interfaces
Note
Before you can configure physical Layer 3 interfaces, you must enable IP routing if IP routing is disabled, and specify an IP routing protocol.
To configure physical Layer 3 interfaces, perform this task:
| |
Task
|
Command
|
Step 1
|
Enable IP routing (Required only if disabled.)
|
Switch(config)#ip routing
|
Step 1
|
Select an interface to configure.
|
Switch(config)# interface {fastethernet |
gigabitethernet} slot/port} | {port-channel
port_channel_number}
|
Step 2
|
Convert this port from physical L2 port to physical L3 port.
|
Switch(config-if)#no switchport
|
Step 3
|
Configure the IP address and IP subnet.
|
Switch(config-if)# ip address ip_address
subnet_mask
|
Step 4
|
Enable the interface.
|
Switch(config-if)# no shutdown
|
Step 5
|
Exit configuration mode.
|
|
Step 6
|
Save your configuration changes to NVRAM.
|
Switch# copy running-config startup-config
|
Step 7
|
Verify the configuration.
|
Switch# show interfaces [type slot/interface]
Switch# show ip interfaces [type slot/interface]
Switch# show running-config interfaces [type
slot/interface]
|
This example shows how to configure an IP address on Fast Ethernet interface 2/1:
Switch# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# ip routing
Switch(config)# interface fastethernet 2/1
Switch(config-if)# no switchport
Switch(config-if)# ip address 10.1.1.1 255.255.255.248
Switch(config-if)# no shutdown
This example uses the show running-config command to display the interface IP address configuration of Fast Ethernet interface 2/1:
Switch# show running-config
Building configuration...
interface FastEthernet2/1
ip address 10.1.1.1 255.255.255.248