Now that you have a little information about troubleshooting the chassis and the major hardware components of the router, we want to spend some time talking about how to monitor the proper operational status of the interfaces. There are two categories of interface monitoring and troubleshooting commands: static and real-time . Note that it is outside the scope of this chapter to list all possible interface-monitoring commands along with their qualifiers, but you can find this information in your JUNOS operational command reference guide or online in the Technical Documentation section of the Juniper Networks Web site at www.juniper.net. 15.5.1 Static MonitoringStatic monitoring of the router interfaces refers to commands that are one-time, or snapshot, commands used to capture a moment in time in the life of the router. Using a static command, you can see ”at that one second ”what has transpired since the last clearing of the counters. You can also check the status of an interface. You must remember, however, that once the response to the command appears on your screen, it is immediately outdated . That does not mean that it is useless information. It simply means that you got a status update. The static monitoring commands for use on the router interfaces all start with the root command in operation mode: show interfaces . You can optionally add the interface name , as well as the qualifiers detail or extensive . The detail option provides detailed information on each interface. The extensive option provides even more detail about the interfaces. The output for a simple show interfaces interface-name command on an ATM interface is shown below: lab@Chicago> show interfaces at-2/1/1 Physical Interface at-2/1/1, Enabled, Physical link is UP Interface index: 30 SNMP ifIndex: 13 Link-level type: ATM-PVC, MTU: 4482, Clocking: Internal, SONET mode, Speed: OC3, Loopback: None, Payload scrambler: Enabled Device Flags : Present Running Link Flags : None Input Rate : 0 bps (0 pps) Output Rate : 0 bps (0 pps) SONET alarms : None SONET defects : None Logical interface at-2/1/1.0 (Index 11) (SNMP ifIndex 56) Flags: Point-to-Point Encapsulation: ATM-SNAP Input packets: 0 Output packets: 0 VCI: 0.100 Flags: Active Total down time: 0 sec, Last down: Never In this example, you can see that there are no active SONET alarms or defects present. You can also gather some information about the type of encapsulation in use and the I/O rate of the interface. The output of this command will look a little different for each interface type. Refer to your JUNOS operational command reference for details. Short summary information, with much less detail, can be obtained by adding the terse option to the command as shown below. Notice that you only see the status, protocol type, and the local and remote addresses. If you need to quickly check the status of an interface, this is a good command to use. lab@Chicago> show interfaces terse Interface Admin Link Proto Local Remote at-2/1/1 UP UP at-2/1/1.0 UP UP inet 10.1.1.1 10.1.1.2 at-2/1/1.100 DOWN DOWN at-2/1/1.3748 DOWN DOWN To obtain only descriptions of the interfaces, use the descriptions qualifier as shown below. As in the above example, you will see the interface name, followed by its status, and a short description, as manually entered. This can be helpful if you name your interfaces by location or another unique identifier. For instance, in this example, the descriptions seem to identify a location and the PVC in use: lab@Chicago> show interfaces descriptions Interface Admin Link Description at-2/1/1.0 UP UP Nassau-0 at-2/1/1.100 UP UP Nassau-100 at-2/1/1.3748 DOWN DOWN Nassau-3748 Using the show interfaces routing command gives you the routing information for each specific interface. You can also include the optional qualifiers interface-name , brief (default), detail , and summary . Using the interface name, you will view only the information for that particular interface. Using brief, you will get the default display information ”a brief view of the basic information for all interfaces (unless you combine this with the interface name). lab@Chicago> show interfaces routing brief Interface State Addresses at-2/1/1.0 Up ISO enabled at-2/1/1.100 Up INET 10.1.1.1 at-2/1/1.3748 Down ISO enabled Using detail , you get a more detailed view of each (or a single) interface. The summary option will give you a short summary of the interfaces on the router and their statuses. lab@Chicago> show interfaces routing summary 5 physical interfaces (4 up) 3 INET protocol addresses (3 up) 5 ISO protocol addresses (4 up) 0 MPLS protocol addresses (0 up) 0 CCC protocol addresses (0 up) Interface Index Metric Trans. Status at-2/1/1.0 6 0 0 Broadcast PointToPoint Multicast at-2/1/1.100 5 0 5 Broadcast PointToPoint Multicast at-2/1/1.3748 4 0 1 Broadcast PointToPoint Multicast lo0.0 3 0 0 Broadcast PointToPoint Multicast fxp1.0 2 0 0 Broadcast Multicast fxp0.0 1 0 1 Broadcast Multicast To gather media-specific information about the interfaces, use the media qualifier. In this example, we are looking at a Fast Ethernet interface. Notice the specific information generated by this command, such as autonegotiation , MAC statistics, and flow control. lab@Chicago> show interfaces media Physical interface: fe-1/0/0, Enabled, Physical link is UP Interface index: 37, SNMP ifIndex: 14 Link-level type: Ethernet, MTU: 1514, Source filtering: Disabled Speed: 100 mbps, Loopback: Disabled, Flow control: Enabled Device flags: Present Running Interface flags: SNMP-Traps Link flags: None Current address: 00:90:69:0e:0c:69, Hardware address: 00:90:69:0e:0c:69 Input rate: 0 bps (0 pps), Output rate: 0 bps (0 pps) Active alarms: None Active defects: None MAC statistics: Input octets: 0, Input packets: 0, Output octets: 0, Output packets: 0 Filter statistics: Filtered packets: 0, Padded packets: 0, Output packet errors: 0 Autonegotiation information: Negotiated status: Complete, Link partner status: OK Link partner: Full-duplex, Flow control: None For statistical information, the command is show interfaces statistics . The default qualifier is detail . You may also specify a particular interface, as we have in the example below, which shows I/O rates in bits per second, as well as clocking information, and so on: lab@Chicago> show interfaces t1-3/1/0 statistics Physical interface: t1-3/1/0, Enabled, Physical link is Up Interface index: 129, SNMP ifIndex: 1300 Link-level type: Cisco-HDLC, MTU: 4474, Clocking: Line Speed: T1, Loopback: Local, FCS: 16, Framing: ESF Device flags : Present Running Interface flags : Point-to-Point Link flags : Keepalives Statistics last cleared: Never Input rate : 0 bps (0 pps), Output rate: 0 bps (0 pps) Input errors : 0, Output errors: 0 Active alarms : None Active defects : None Logical interface t1-3/1/0.0 (Index 4) (SNMP ifIndex 1380) Flags: Point-to-Point, Encapsulation: Cisco-HDLC Protocol inet, MTU: 4470 Addresses, Flags: Is-Preferred, Is-Primary Destination: 10.0.3.2, Local: 10.0.3.1 Static monitoring using the show interfaces command provides you with a way to get a snapshot of a moment in time of a particular interface. By using different parameters with this command, you can gather a great deal of useful troubleshooting information, such as clocking, encapsulation, interface status, and alarms. The next section takes a look at how you can gather ongoing information about an interface with real-time monitoring. 15.5.2 Real-time MonitoringSuppose you don't want just a status update. What if you need a running output that is continuously updated? This is when you need real-time monitoring. There are two primary commands that can be used to monitor router interfaces in real-time for immediate feedback: monitor interface and monitor traffic . The monitor interface command shows statistics for a physical interface updated once per second. You will also see the difference between the statistics at the beginning of the monitoring (or since you last cleared the statistics) and the present update. This is quite helpful when troubleshooting an ongoing problem. Another feature of this command is its ability to discover and display common interface problems like alarms and framing errors. The usage for this command is as follows : lab@Chicago> monitor interface < interface-name traffic> If you do not specify an interface name, you will get output for all interfaces. Adding the traffic qualifier will provide you with traffic data (input and output packets per second, for example) for one or all interfaces. Table 15-4 lists the key sequences for use with the monitor interface command. These key sequences are not case sensitive. Table 15-4. Control Keys for the monitor interface Command
The monitor traffic command can be compared to the UNIX command tcpdump , which also can be used to display the traffic flowing through an interface. Using the monitor traffic command with Boolean expressions, you can print and examine packet headers on traffic on an interface. The monitor traffic command should be used with caution. If you do not use specific parameters to filter the output, it could impact your router's performance, throughput, or both. If you have any questions about the use of this command, contact JTAC before using it. In addition, you can refer to the Juniper Networks Web site or your copy of the JUNOS documentation for software command reference documents for the version of JUNOS you are using. Search for the section on the traffic match condition. The optional qualifiers that can be used with the monitor traffic command are listed in Table 15-5, along with a short description of each. Table 15-5. Optional Qualifiers for the monitor traffic Command
|