This is an old revision of the document!
Switch# show interface type mod/num switchport
Switch# show interface gigabitethernet 0/1 switchport Name: Gi0/1 Switchport: Disabled Switch#
Switch(config)# interface type mod/num
Switch(config-if)# switchport
Switch(config)# interface type mod/num
Switch(config-if)# no switchport
Switch(config-if)# ip address ip-address mask [secondary]
Switch(config)# interface vlan vlan-id
Switch(config-if)# ip address ip-address mask [secondary]
Switch(config-if)# no shutdown
AUTOSTATE:
Podmínky za kterých je SVI UP díky autostate:
Př. Na switchi je definována VLAN2, je do ní přiřazeno několik interfejsů, ale žádný není aktivní
Switch(config)#interface vlan2 Switch(config-if)# *Apr 21 10:13:10.949: %LINK-3-UPDOWN: Interface Vlan2, changed state to up Switch(config-if)# Switch(config-if)#ip address 192.168.1.1 255.255.255.0 Switch(config-if)#^Z
Switch# show ip interface brief Interface IP-Address OK? Method Status Protocol Vlan1 unassigned YES manual administratively down down Vlan2 192.168.1.1 YES manual up down FastEthernet1/0/1 unassigned YES unset down down FastEthernet1/0/2 unassigned YES unset down down
Připojení PC k jednomu z portů ve VLAN2:
Switch# *Apr 21 10:21:31.925: %LINK-3-UPDOWN: Interface FastEthernet1/0/1, changed state to up *Apr 21 10:21:32.009: %LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan2, changed state to up *Apr 21 10:21:32.932: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet1/0/1, changed state to up Switch#
Odpojení PC od portu:
Switch# *Apr 21 10:21:45.624: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet1/0/1, changed state to down *Apr 21 10:21:45.624: %LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan2, changed state to down *Apr 21 10:21:46.622: %LINK-3-UPDOWN: Interface FastEthernet1/0/1, changed state to down
Zajistí, že tento int. nebude mít vliv na stav SVI:
Switch(config-if)# switchport autostate exclude
(route cache switching)
Podporované platformy:
Zobrazení FIB:
Switch# show ip cef [type mod/num | vlan vlan-id] [detail]
Switch# show ip cef vlan 101 Prefix Next Hop Interface 10.1.1.0/24 attached Vlan101 10.1.1.2/32 10.1.1.2 Vlan101 10.1.1.3/32 10.1.1.3 Vlan101
Switch# show ip cef [prefix-ip prefix-mask] [longer-prefixes] [detail]
longer-prefixes - vypíše i routy s delší maskou než která byla specifikována v příkazu
Switch# show ip cef 10.1.0.0 255.255.0.0 longer-prefixes Prefix Next Hop Interface 10.1.1.0/24 attached Vlan101 10.1.1.2/32 10.1.1.2 Vlan101 10.1.1.3/32 10.1.1.3 Vlan101 10.1.2.0/24 attached Vlan102 10.1.3.0/26 192.168.1.2 Vlan99 192.168.1.3 Vlan99 10.1.3.64/26 192.168.1.2 Vlan99 192.168.1.3 Vlan99 10.1.3.128/26 192.168.1.4 Vlan99 192.168.1.3 Vlan99 [output omitted]
Switch# show ip cef 10.1.3.0 255.255.255.192 detail 10.1.3.0/26, version 270, epoch 0, per-destination sharing 0 packets, 0 bytes via 192.168.1.2, Vlan99, 0 dependencies traffic share 1 next hop 192.168.1.2, Vlan99 valid adjacency via 192.168.1.3, Vlan99, 0 dependencies traffic share 1 next hop 192.168.1.3, Vlan99 valid adjacency 0 packets, 0 bytes switched through the prefix tmstats: external 0 packets, 0 bytes internal 0 packets, 0 byte
Důvody proč paket není směrován dle FIB:
Switch# show adjacency [type mod/num | vlan vlan-id] [summary | detail]
Switch# show adjacency summary Adjacency Table has 106 adjacencies Table epoch: 0 (106 entries at this epoch) Interface Adjacency Count Vlan99 21 Vlan101 3 Vlan102 1 Vlan103 47 Vlan104 7 Vlan105 27
Switch# show adjacency vlan 99 detail Protocol Interface Address IP Vlan99 192.168.1.2(5) 0 packets, 0 bytes 000A5E45B145000E387D51000800 ARP 01:52:50 Epoch: 0 IP Vlan99 192.168.1.3(5) 1 packets, 104 bytes 000CF1C909A0000E387D51000800 ARP 04:02:11 Epoch: 0
Switch# show ip cef adjacency glean Prefix Next Hop Interface 10.1.1.2/32 attached Vlan101 127.0.0.0/8 attached EOBC0/0 [output omitted] Switch# show ip arp 10.1.1.2 Switch# show ip cef 10.1.1.2 255.255.255.255 detail 10.1.1.2/32, version 688, epoch 0, attached, connected 0 packets, 0 bytes via Vlan101, 0 dependencies valid glean adjacency
Typy záznamů v adjacency table:
Switch# show cef drop CEF Drop Statistics Slot Encap_fail Unresolved Unsupported No_route No_adj ChkSum_Err RP 8799327 1 45827 5089667 32 0
Switch# show cef not-cef-switched CEF Packets passed on to next switching layer Slot No_adj No_encap Unsupp’ted Redirect Receive Options Access Frag RP 3579706 0 0 0 41258564 0 0 0
Důvody pro zpracování v L3 enginu:
Na Cat3750 a 4500 lze vypnout:
Switch(config-if)# no ip route-cache cef
Switch(config-if)# no ip cef
VERIFING MLS str.257