You want to check the status of an interface.
Use the show interfaces command to see the status of the interfaces on the router. With no options, this command shows the status of all interfaces on the router:
aviva@router1> show interfaces
You can also look at the status for a particular interface:
aviva@router1> show interfaces fe-0/0/0
If you want shorter summaries of the status, use one of these command versions:
aviva@router1> show interfaces brief aviva@router1> show interfaces terse
For maximum information for debugging purposes, use one of these commands:
aviva@router1> show interfaces detail aviva@router1> show interfaces extensive
Because the operation of the router revolves around the network interfaces, you often need to get information about the interfaces to check status or to troubleshoot a router or network problem. The basic commands for doing this are variations of the show interfaces command. To just find out what PICs are installed and which interfaces are configured, use the show interfaces terse command (see Recipe 7.12). For basic information about the physical and logical interface settings, use the show interfaces command, or for an abridged view, use the show interfaces brief command. The show interfaces detail command adds traffic statistics and queue counters, and the show interfaces extensive command adds alarms, error statistics, and additional counters.
The output of these commands varies depending on the type of interface. However, the general format of the information is the same for all interfaces, so it's worth examining the output of one so you can become familiar with what to expect in the output. Here's the information displayed by the show interfaces command for a Fast Ethernet interface:
aviva@router1> show interfaces fe-0/0/0 Physical interface: fe-0/0/0, Enabled, Physical link is Up Interface index: 128, SNMP ifIndex: 79 Description: to nutmeg fe-000 Link-level type: Ethernet, MTU: 1514, Speed: 100mbps, Loopback: Disabled, Source filtering: Disabled, Flow control: Enabled Device flags : Present Running Interface flags: SNMP-Traps 16384 Link flags : 4 CoS queues : 4 supported Current address: 00:05:85:02:a4:00, Hardware address: 00:05:85:02:a4:00 Last flapped : 2005-05-12 14:58:08 PDT (05:04:29 ago) Input rate : 0 bps (0 pps) Output rate : 0 bps (0 pps) Active alarms : None Active defects : None Logical interface fe-0/0/0.0 (Index 66) (SNMP ifIndex 84) Flags: SNMP-Traps Encapsulation: ENET2 Protocol inet, MTU: 1500 Flags: None Addresses, Flags: Is-Preferred Is-Primary Destination: 192.168.220.0/30, Local: 192.168.220.1, Broadcast: 192.168.220.3 Protocol iso, MTU: 1497 Flags: Is-Primary
Here's the same interface with the show interfaces brief command:
aviva@router1> show interfaces brief fe-0/0/0 Physical interface: fe-0/0/0, Enabled, Physical link is Up Description: to nutmeg fe-000 Link-level type: Ethernet, MTU: 1514, Speed: 100mbps, Loopback: Disabled, Source filtering: Disabled, Flow control: Enabled Device flags : Present Running Interface flags: SNMP-Traps 16384 Link flags : 4 Logical interface fe-0/0/0.0 Flags: SNMP-Traps Encapsulation: ENET2 inet 192.168.220.1/30 iso
The output has two parts. The top part shows information about the physical interface, and the bottom shows information about the logical interface, including the protocol family and the interface addresses.
The first line of the output shows the most important information when you are checking interface status:
Physical interface: fe-0/0/0, Enabled, Physical link is Up
This line tells whether the interface is operational. Enabled means that the interface has been configured and is administratively up. The output shows Disabled if it's not. The physical link (connection) is up, which means that the interface is receiving the correct Layer 1 physical signaling from the other side of the link, indicating that the interface at the other end of the link is configured and operational. This line of the output is one of the first things to check when you are troubleshooting routing or connectivity problems.
The next line gives indexing information about the physical interface:
Interface index: 137, SNMP ifIndex: 29
The interface index is the physical interface's index number, which is based on the order in which it was initialized. The SNMP ifIndex is the SNMP index number of the physical interface. It allows you to correlate the values in the interface MIB OIDs with actual interfaces. You can also see this information on the router:
aviva@router1> show snmp mib walk ifTable ifDescr.29 = fe-0/0/0
The next line gives more information about the physical properties of the interface:
Link-level type: Ethernet, MTU: 1514, Speed: 100mbps, Loopback: Disabled,
This shows the Layer 2 (link-level) encapsulation type and Maximum Transmission Unit (MTU) of the interface. Both are using the default encapsulations for their interface types. For the IPv4 address family, Ethernet is the only allowed link-level type. If you look in the logical interface section of the output, you see the encapsulation that is being used on the logical interface. The physical encapsulation applies to all protocols running on the interface, and logical interface encapsulation applies only to that address family. You can use the encapsulation statement in both portions of the configuration to modify the defaults:
[edit interfaces fe-0/0/0] aviva@router1# set encapsulation vlan-ccc [edit interfaces fe-0/0/0 unit 0] aviva@router1# set encapsulation ppp-over-ether
The MTU is 1,514 bytes. This is the default media (Layer 2) MTU size, which is the size of the largest packet that the router can transmit through this interface. It applies to all protocols that use this interface. The protocol MTU size is in the logical interfaces portion of the output. Both logical interfaces are running IPv4 (Protocol inet), and the IPv4 MTU size is the standard 1,500 bytes for both interfaces. The media MTU is the sum of the IP MTU and the encapsulation overhead, which is 14 bytes for Ethernet interfaces. All devices on the Ethernet LAN must support the same MTU size. If you notice that a device is dropping traffic, check its MTU.
The speed for the Ethernet shows that this is Fast Ethernet, running at 100 Mbps.
The next line of output shows whether source filter and flow control are configured on the interface:
Source filtering: Disabled, Flow control: Enabled
Source address filtering blocks traffic from specific Ethernet MAC addresses. This is off by default. Flow control, which is on by default on Fast Ethernet interfaces, regulates the amount of traffic sent out on a full-duplex interface. (Flow control, also called pause frames, is an optional clause on the specification for full-duplex Ethernet, defined by the IEEE 802.3x Task Force in Annex 31B.) Source filtering and flow control are explained more in Recipe 7.13.
The device flags list information about the physical device. You see this line for all router interfaces:
Device flags : Present Running
The output shows that the PIC has been recognized by the router software and is operating normally. If the output shows Down instead of Running, check that the interface is configured. If the Present flag is missing, it might indicate that the PIC is not installed properly or is broken.
The next several lines show that SNMP trap notifications are enabled, the number of link flags set on the interface, the number of class-of-service (CoS) queues supported by the PIC, and the PIC's MAC address. The first address is the one currently being used and the second is the one hard-coded on the PIC.
Interface flags: SNMP-Traps 16384 Link flags : 4 CoS queues : 8 supported Current address: 00:05:85:ca:ca:70, Hardware address: 00:05:85:ca:ca:70
The last lines about the physical interface show how long it has been up, the traffic rates in and out the interface, and whether any interface alarms are active:
Last flapped : 2005-04-23 05:16:57 UTC (1w4d 00:49 ago) Input rate : 0 bps (0 pps) Output rate : 0 bps (0 pps) Active alarms : None Active defects : None
The logical interfaces portion of the output starts with the logical interface name and indexing information. The second line shows that SNMP trap notifications are also enabled on the logical interface, and the encapsulation is Ethernet II (RFC 894):
Logical interface fe-0/0/0.0 (Index 66) (SNMP ifIndex 39) Flags: SNMP-Traps Encapsulation: ENET2
The final portion shows the protocol families configured on the interface. Here, IPv4 ( inet) and ISO are configured. For IPv4, the MTU size is 1,500 bytes (for Ethernet, this is the default), and no logical interface flags are set. You then see the IPv4 address flags, here showing that this is default local address for packets originating from the local router and sent to destinations on the subnet (Is-Preferred) and the default address for broadcast and multicast packets (Is-Primary). For ISO, the MTU size is 1,497 bytes (the default), and this is the default local address for broadcast addresses.
Recipes 7.12 and 7.13
Router Configuration and File Management
Basic Router Security and Access Control
Routing Policy and Firewall Filters