Monitoring Routing Policy
You can monitor the following aspects of routing policy using show commands:
To Display | Commands |
|---|---|
Access lists | show access-list |
Community lists | show ip community-list |
Policy lists | show ip match-policy-list |
Prefix lists | show ip prefix-list |
Prefix trees | show ip prefix-tree |
Protocols | show ip protocols |
Redistribution policies | show ip redistribute |
Routes | show ip route |
Route maps | show route-map |
Interfaces and next hops | show ip route slot 5 192.168.5.4 |
Static routes | show ip static |
Traffic | show ip traffic |
You can use the output filtering feature of the show command to include or exclude lines of output based on a text string that you specify. For details, see Command Line Interface in JunosE System Basics Configuration Guide.
show access-list
show ipv6 access-list
- Use to display information about access lists.
- The displayed information includes the instances of each access list.
- Use the detail keyword to display the automatically assigned element ID for each access list entry. Only rules that you explicitly create have element IDs.
- Example 1
host1#show access-list IP Access List 1: permit ip host 172.31.192.217 any permit ip 12.40.0.0 0.0.0.3 any deny ip any any IP Access List 2: permit ip 172.19.0.0 0.0.255.255 any deny ip 0.0.0.0 255.255.255.255 any IP Access List 10: permit ip any any IP Access List 11: deny ip any any - Example 2
host1#show access-list detail IP Access List 1: 1: permit ip host 172.31.192.217 any 2: permit ip 12.40.0.0 0.0.0.3 any deny ip any any - See show access-list.
- See show ipv6 access-list.
show ip as-path-access-list
- Use to display information about AS-path access lists.
- Example
host1#show ip as-path-access-list AS Path Access List 1: permit .* AS Path Access List 2: deny .* AS Path Access List 3: permit _109_ deny .* AS Path Access List 4: permit _109$ deny .* AS Path Access List 10: deny _109$ permit ^108_ deny .* - See show ip as-path-access-list.
show ip community-list
- Use to display community list information.
- Display varies based on whether you issued the ip bgp community new-format command.
- Example 1—If you did not issue the ip bgp community new-format command, the display appears
as follows:
host1#show ip community-list Community List 1: permit 81200109 permit 81200110 permit 81200108 Community List 2: deny 81200109 permit 81200110 permit 81200108 Community List 4: permit local-as Community List 5: permit no-advertise Community List 6: permit no-export Community List 7: permit internet - Example 2—If you did issue the ip bgp
community new-format command, the display appears as
follows:
host1#show ip community-list Community List 1: permit 1239:1005 permit 1239:1006 permit 1239:1004 Community List 2: deny 1239:1005 permit 1239:1006 permit 1239:1004 Community List 4: permit local-as Community List 5: permit no-advertise Community List 6: permit no-export Community List 7: permit internet - See show ip community-list.
show ip match-policy-list
- Use to display configured policy lists.
- Example
host1#show ip match-policy-list match-policy-list list1, permit Match clauses: match access-list addrList1 match distance 100 - See show ip match-policy-list.
show ip prefix-list
- Use to display information about the prefix lists currently configured on the router.
- Use the summary keyword to display abbreviated information about prefix lists.
- Example 1
host1#show ip prefix-list Prefix-list with the last deletion/insertion: def ip prefix-list name abc: 4 entries seq 5 permit 192.168.0.0/16 le 24 seq 10 permit 192.178.0.0/16 le 24 seq 15 deny 195.178.0.0/16 le 24 seq 20 deny 195.178.0.0/16 le 32 ip prefix-list name def: 1 entries seq 5 deny 192.170.0.0/16
- Example 2
host1#show ip prefix-list summary Total memory used for prefix-list: 310 bytes Prefix-list with the last deletion/insertion: def ip prefix-list name abc: count: 4, range entries: 4, sequences: 5-20 ip prefix-list name def: count: 1, range entries: 0, sequences: 5-5
- See show ip prefix-list.
show ip prefix-tree
- Use to display information about the prefix trees currently configured on the router.
- Use the summary keyword to display abbreviated information about prefix trees.
- Example 1
host1#show ip prefix-tree Prefix-tree with the last deletion/insertion: t_abc5 ip prefix-tree name t_abc1: 1 entries permit 108.243.0.0/16 ip prefix-tree name t_abc2: 3 entries permit 101.10.254.0/24 permit 102.10.248.0/21 permit 103.10.192.0/18 permit 108.109.0.0/16 permit 108.109.241.0/24 ip prefix-tree name t_abc3: 1 entries deny 108.0.0.0/8
- Example 2
host1#show ip prefix-tree summary Total memory used for prefix-tree: 860 bytes Prefix-tree with the last deletion/insertion: t_abc5 ip prefix-tree name t_abc1: count: 1 ip prefix-tree name t_abc2: count: 5 ip prefix-tree name t_abc3: count: 1
- See show ip prefix-tree.
show ip protocols
- Use to display detailed information about the protocols currently configured on the router.
- Use the summary keyword to display only a list of the configured protocols.
- For field descriptions, see the show commands for the individual routing protocols in their respective Configuration Guide chapters.
- Example
host1#show ip protocols Routing Protocol is “ bgp 1”
Default local preference is 100 IGP synchronization is enabled Always compare MED is disabled Router flap damping is disabled Administrative Distance: external 20 internal 200 local 200 Neighbor(s): No neighbors are configured Routing for Networks:Routing Protocol is “ ospf 255” with Router ID 100.100.100.1 Distance is 110
Address Summarization: None Routing for Networks:Routing Protocol is “ rip” Router Administrative State: enable System version RIP1: send = 1, receive = 1 or 2 Update interval: 30 seconds Invalid after: 180 seconds hold down time: 120 seconds flushed interval: 300 seconds Filter applied to outgoing route update is not set Filter applied to incoming route update is not set No global route map Distance is 120 Interface Tx Rx Auth
Routing for Networks: 10.2.1.0/255.255.255.0 - See show ip protocols.
show ip redistribute
- Use to display configured route redistribution policy.
- Field descriptions
- To—Protocol into which routes are distributed
- From—Protocol from which routes are distributed
- status—Redistribution status
- route map number—Number of the route map
- Example
host1#show ip redistribute To ospf, From static is enabled with route map 4 To ospf, From connected is enabled with route map 3
- See show ip redistribute.
show ip route
- Use to display the current state of the routing table, including routes that are not used for forwarding.
- You can display all routes, a specific route, all routes beginning with a specified address, routes for a particular protocol (BGP, IS-IS, OSPF, or RIP), locally connected routes, internal control routes, static routes, or summary counters for the routing table.
- Field descriptions
- Prefix—IP address prefix
- Length—Prefix length
- Type—Protocol type
- Next Hop—IP address of the next hop
- Dist—Distance metric for the route
- Met—Number of hops
- Intf—Interface type and interface specifier
- Example 1
host1#show ip route Protocol/Route type codes: I1- ISIS level 1, I2- ISIS level2, I- route type intra, IA- route type inter, E- route type external, i- metric type internal, e- metric type external, O- OSPF, E1- external type 1, E2- external type2, N1- NSSA external type1, N2- NSSA external type2
Prefix/Length Type Next Hop Dist/Met Intf ------------- ---- -------- -------- ------ 172.16.2.0/24 Bgp 192.168.1.102 20/1 fastEthernet0/0 10.10.0.112/32 Static 192.168.1.1 1/1 fastEthernet0/0 10.1.1.0/24 Connect 10.1.1.1 0/1 atm3/0.100
- Example 2
host1#show ip route static Protocol/Route type codes: I1- ISIS level 1, I2- ISIS level2, I- route type intra, IA- route type inter, E- route type external, i- metric type internal, e- metric type external, O- OSPF, E1- external type 1, E2- external type2, N1- NSSA external type1, N2- NSSA external type2
Prefix/Length Type Next Hop Dist/Met Intf ------------- ---- -------- -------- ------ 10.10.0.112/32 Static 192.168.1.1 1/1 fastEthernet0/0
- Example 3
host1#show ip route summary Unicast routes: 8 total routes, 576 bytes in route entries 0 isis routes 0 rip routes 3 static routes 2 connected routes 1 bgp routes 0 ospf routes 2 other internal routes 0 access routes 0 internally created access host routes
Last route added/deleted: 2::4/128 by BGP At MON FEB 04 2008 14:18:25 UTC
Unicast routes used only for Multicast RPF check: 0 total routes, 0 bytes in route entries 0 isis routes 0 rip routes 0 static routes 0 connected routes 0 bgp routes 0 ospf routes 0 other internal routes 0 access routes 0 internally created access host routes 0 mbgp routes 0 dvmrp routes
Last route added/deleted: null by Invalid At MON FEB 04 2008 14:18:04 UTC
MPLS tunnel routes (not used for forwarding): 3 total routes, 216 bytes in route entries 1 bgp tunnel routes 1 ldp tunnel routes 1 rsvp tunnel routes
Last route added/deleted: 2::4/128 by BGP Tunnel At MON FEB 04 2008 14:18:26 UTC
- See show ip route.
show ip route slot
- Use to display the interface and next hop for an IP address
in the routing table of a line module specified by the slot it occupies.
- slotNumber—Number of the slot that contains the line module for which the information is displayed
- ipAddress—IP address to look up in the routing table
- Field descriptions
- IP address—Address that is reachable through the interface
- Interface—Interface type and specifier associated with the IP address; displays “ Local Interface” if a special interface index is present in the routing table for special IP addresses, such as broadcast addresses
- Next Hop—Next hop to reach the IP address; displays “ ---” if no next hop is associated with the IP address
- Example 1
host1#show ip route slot 6 10.10.0.231 IP address Interface Next Hop ------------ ---------------- ------------ 10.10.0.231 fastEthernet 6/0 10.10.0.231
- Example 2
host1#show ip route slot 9 90.248.1.2 IP address Interface Next Hop ------------ ---------------- ------------ 90.248.1.2 serial9/23:2 ---
- Example 3
host1#show ip route slot 9 90.249.255.255 IP address Interface Next Hop ------------ ---------------- ------------ 90.249.255.255 Local Interface ---
- See show ip route slot.
show ip static
- Use to display the status of static routes in the routing table.
- You can specify an optional IP mask that filters specific routes.
- Field descriptions
- Prefix—IP address prefix
- Length—Prefix length
- Next Hop—IP address of the next hop
- Met—Number of hops
- Dist—Administrative distance or weight assigned to the route
- Tag—Tag value assigned to the route
- Intf—Interface type and interface specifier
- Example
host1#show ip static Prefix/Length Next Hop: Met: Dist: Tag: Intf: 10.2.0.0/24 192.168.1.1 1 1 0 ethernet6/0 10.2.1.0/24 192.168.1.1 1 1 1 ethernet6/0 172.31.1.48/32 172.18.2.2 1 1 0 atm5/1.1
- See show ip static.
show ip traffic
- Use to display statistics about IP traffic.
- Field descriptions
- IP Statistics Rcvd:
- Router Id—Router ID number
- total—Number of frames received
- local destination—Frames with this router as their destination
- hdr errors—Number of packets received that contain header errors
- addr errors—Number of packets received that contain addressing errors
- unkn proto—Number of packets received that contain unknown protocols
- discards—Number of discarded packets
- IP Statistics Frags:
- reassembled—Number of reassembled packets
- reasm timed out—Number of reassembled packets that timed out
- reasm req—Number of requests for reassembly
- reasm fails—Number of reassembly failures
- frag ok—Number of fragmented packets reassembled successfully
- frag fail—Number of fragmented packets reassembled unsuccessfully
- frag creates—Number of packets created by fragmentation
- IP Statistics Sent:
- forwarded—Number of packets forwarded
- generated—Number of packets generated
- out disc—Number of outbound packets discarded
- no routes—Number of packets that could not be routed
- routing discards—Number of packets that could not be routed that were discarded
- IP Statistics Route:
- routes in table—Number of routes in the routing table
- timestamp req—Number of requests for a timestamp
- timestamp rpy—Number of replies to timestamp requests
- addr mask req—Number of address mask requests
- addr mask rpy—Number of address mask replies
- ICMP Statistics Rcvd:
- total—Total number of ICMP packets received
- errors—Number of error packets received
- dst unreach—Number of packets received with destination unreachable
- time exceed—Number of packets received with time-to-live exceeded
- param probs—Number of packets received with parameter errors
- src quench—Number of source quench packets received
- redirects—Number of receive packet redirects received
- echo req—Number of echo request (ping) packets received
- echo rpy—Number of echo replies received
- timestamp req—Number of requests for a timestamp received
- timestamp rpy—Number of replies of timestamp requests received
- addr mask req—Number of mask requests received
- addr mask rpy—Number of mask replies received
- ICMP Statistics Sent:
- total—Total number of ICMP packets sent
- errors—Number of error packets sent
- dest unreach—Number of packets sent with destination unreachable
- time excd—Number of packets sent with time-to-live exceeded
- param prob—Number of packets sent with parameter errors
- src quench—Number of source quench packets sent
- redirects—Number of send packet redirects sent
- echo req—Number of echo request (ping) packets sent
- echo rpy—Number of echo replies sent
- timestamp req—Number of requests for a timestamp sent
- timestamp rpy—Number of replies to timestamp requests sent
- addr mask req—Number of address mask requests sent
- addr mask rpy—Number of address mask replies sent
- UDP Statistics Rcvd:
- total—Total number of UDP packets received
- checksum—Number of checksum error packets received
- no port—Number of packets received for which no application listener was listening on the destination port
- UDP Statistics Sent:
- total—Total number of UDP packets sent
- errors—Number of error packets sent
- TCP Global Statistics Connections:
- attempted—Number of outgoing TCP connections attempted
- accepted—Number of incoming TCP connections accepted
- established—Number of TCP connections established
- dropped—Number of TCP connections dropped
- closed—Number of TCP connections closed
- TCP Global Statistics Rcvd:
- total pkts—Total number of TCP packets received
- in-sequence pkts—Number of packets received in sequence
- bytes—Number of bytes received
- chksum err pkts—Number of checksum error packets received
- authentication err pkts—Number of authentication error packets received
- bad offset pkts—Number of packets received with bad offsets
- short pkts—Number of short packets received
- duplicate pkts—Number of duplicate packets received
- out of order pkts—Number of packets received out of order
- TCP Global Statistics Sent:
- total pkts—Total number of TCP packets sent
- data pkts—Number of data packets sent
- bytes—Number of bytes sent
- retransmitted pkts—Number of packets retransmitted
- retransmitted bytes—Number of retransmitted bytes
- OSPF Statistics—Not supported for this version of the router
- IGMP Statistics—Not supported for this version of the router
- ARP Statistics—Not supported for this version of the router
- IP Statistics Rcvd:
- Example
host1#show ip traffic IP statistics: Router Id: 172.31.192.217 Rcvd: 97833 total, 171059 local destination 0 hdr errors, 0 addr errors 167 unkn proto, 0 discards Frags: 4 reassembled, 30 reasm timed out, 8 reasm req 0 reasm fails, 145 frag ok, 0 frag fail 290 frag creates Sent: 15 forwarded, 25144 generated, 0 out disc 0 no routes,0 routing discards Route: 57680 routes in table 0 timestamp req, 0 timestamp rpy 0 addr mask req, 0 addr mask rpy
ICMP statistics: Rcvd: 561 total, 0 errors, 15 dst unreach 0 time exceed, 0 param probs, 0 src quench 0 redirects, 0 echo req, 0 echo rpy 0 timestamp req, 0 timestamp rpy 0 addr mask req, 0 addr mask rpy Sent: 0 total, 0 errors, 0 dest unreach 0 time excd, 0 param prob, 0 src quench 0 redirects, 0 echo req, 0 echo rpy
UDP Statistics: Rcvd: 93326 total, 0 checksum errors, 90610 no port Sent: 0 total, 0 errors
TCP Global Statistics: Connections: 7358 attempted, 4 accepted, 7362 established 0 dropped, 14718 closed Rcvd: 75889 total pkts, 53591 in-sequence pkts, 3120283 bytes 0 chksum err pkts, 0 authentication err pkts, 0 bad offset 0 short pkts, 0 duplicate pkts, 0 out of order pkts Sent: 82318 total pkts, 44381 data pkts, 656321 bytes 34 retransmitted pkts, 487 retransmitted bytes
OSPF Statistics:
IGMP Statistics:
ARP Statistics: - See show ip traffic.
show route-map
- Use to display the configured route maps.
- The displayed information includes the instances of each access list such as match and set commands.
- Example
host1(config)#route-map 1 permit 10 host1(config-route-map)#match community 44 host1(config-route-map)#set local-pref 400 host1(config-route-map)#exit host1(config)#exit host1#show route-map 1 route-map 1, permit, sequence 10 Match clauses: match community 44 Set clauses: set local-pref 400 - See show route-map.
Hide Navigation Pane
Show Navigation Pane
SHA1