2011ǯ12

ƥ:

Object trackingѤ뤳ȤΥ롼Ⱦ󤬤뤫ɤˤꡢ롼ƥ󥰤ѹ뤳ȤǽǤR1, R2, R4Ϥ줾F0/0124.124.124.0/24Υͥåȥ³ƤޤR1R3˥ꥢ륱֥ľ(13.13.13.0/24)R2R3˥ꥢ륱֥ľ(23.23.23.0/24)Ƥޤ

R1(config-if)#do sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            124.124.124.1   YES manual up                    up
Loopback0                  17.17.1.1       YES NVRAM  up                    up

R2(config-if)#do sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            124.124.124.2   YES manual up                    up
Serial1/2                  23.23.23.2      YES manual up                    up
Loopback0                  17.17.2.2       YES NVRAM  up                    up

R4(config-if)#do sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            124.124.124.4   YES manual up                    up
Loopback0                  17.17.4.4       YES NVRAM  up                    up

R1, R2, R4EIGRPͭˤޤ

R1(config)#router eigrp 100
R1(config-router)#no auto-summary
R1(config-router)#network 0.0.0.0

R1R2HSRPꤷޤR1ͥŪѤ뤿ᡢץ饤ƥ110Ȥޤ

R1(config-if)#int f0/0
R1(config-if)#standby 124 ip 124.124.124.254
R1(config-if)#standby 124 priority 110

R2(config-if)#int f0/0
R2(config-if)#standby 124 ip 124.124.124.254

R113.13.13.0/24ΥͥåȥäƤ뤫ɤˤꡢHSRPΥץ饤ƥѹޤtrackޥɤ³ơֹ֥ꤷޤǤ1Ȥޤ

R1(config)#track ?
  <1-500>     Tracked object
  resolution  Tracking resolution parameters
  timer       Polling interval timers

R1(config)#track 1 ?
  application  Application
  interface    Select an interface to track
  ip           IP protocol
  list         Group objects in a list
  rtr          Response Time Reporter (RTR) entry
  stub-object  Stub tracking object

R1(config)#track 1 ip ?
  route  IP route

R1(config)#track 1 ip route ?
  A.B.C.D  {/nn || A.B.C.D}  Prefix and mask

R1(config)#track 1 ip route 13.13.13.0/24 ?
  metric        Route metric
  reachability  Route reachability state

R1(config)#track 1 ip route 13.13.13.0/24 reachability ?
  <cr>

R1(config)#track 1 ip route 13.13.13.0/24 reachability

track 1󤷤硢ץ饤ƥͤ20餹(110-20=90)standby 124ꤷޤ

R1(config-if)#standby 124 track 1 ?
  decrement  Priority decrement
  shutdown   Shutdown group
  <cr>

R1(config-if)#standby 124 track 1 decrement ?
  <1-255>  Decrement value

R1(config-if)#standby 124 track 1 decrement 20
R1(config-if)#do sh track
Track 1
  IP route 13.13.13.0 255.255.255.0 reachability
  Reachability is Up (connected)
    5 changes, last change 00:00:06
  First-hop interface is Serial1/2
  Tracked by:
    HSRP FastEthernet0/0 124

ץ饤ƥͤ⤤ΤActiveˤʤ뤿ˤpreempt꤬ʻɬפǤ

R1(config-if)#standby 124 preempt
R2(config-if)#standby 124 preempt

ǸߤǧR1ActiveȤʤäƤ뤳Ȥʬޤ

R1(config)#do sh stan bri
                     P indicates configured to preempt.
                     |
Interface   Grp  Pri P State   Active          Standby         Virtual IP
Fa0/0       124  110 P Active  local           124.124.124.2   124.124.124.254
R1(config-if)#do sh standb
FastEthernet0/0 - Group 124
  State is Active
    5 state changes, last state change 00:06:30
  Virtual IP address is 124.124.124.254
  Active virtual MAC address is 0000.0c07.ac7c
    Local virtual MAC address is 0000.0c07.ac7c (v1 default)
  Hello time 3 sec, hold time 10 sec
    Next hello sent in 2.712 secs
  Preemption enabled
  Active router is local
  Standby router is 124.124.124.2, priority 100 (expires in 7.728 sec)
  Priority 110 (configured 110)
    Track object 1 state Up decrement 20
  Group name is "hsrp-Fa0/0-124" (default)

R1ǥǥХͭˤs0/2򥷥åȤޤ

R1(config)#do deb standb
HSRP debugging is on
R1(config)#int s1/2
R1(config-if)#sh

Dec 26 03:52:48.779: HSRP: Fa0/0 Grp 124 Hello  out 124.124.124.1 Active  pri 110 vIP 124.124.124.254
Dec 26 03:52:49.795: HSRP: Fa0/0 Grp 124 Hello  in  124.124.124.2 Standby pri 100 vIP 124.124.124.254
Dec 26 03:53:35.347: %LINK-5-CHANGED: Interface Serial1/2, changed state to administratively down
Dec 26 03:53:36.235: %TRACKING-5-STATE: 1 ip route 13.13.13.0/24 reachability Up->Down
Dec 26 03:53:36.239: HSRP: Fa0/0 Grp 124 Track 1 object changed, state Up -> Down
Dec 26 03:53:36.239: HSRP: Fa0/0 Grp 124 Priority 110 -> 90
Dec 26 03:53:36.347: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial1/2, changed state to down
Dec 26 03:53:36.831: HSRP: Fa0/0 Grp 124 Hello  out 124.124.124.1 Active  pri 90 vIP 124.124.124.254
Dec 26 03:53:36.851: HSRP: Fa0/0 Interface adv in, Active, active 1, passive 1, from 124.124.124.2
Dec 26 03:53:36.855: HSRP: Fa0/0 Grp 124 Coup   in  124.124.124.2 Standby pri 100 vIP 124.124.124.254
Dec 26 03:53:36.855: HSRP: Fa0/0 Grp 124 Active: j/Coup rcvd from higher pri router (100/124.124.124.2)
Dec 26 03:53:36.855: HSRP: Fa0/0 Grp 124 Active router is 124.124.124.2, was local
Dec 26 03:53:36.855: HSRP: Fa0/0 Nbr 124.124.124.2 active for group 124
Dec 26 03:53:36.855: HSRP: Fa0/0 Grp 124 Standby router is unknown, was 124.124.124.2
Dec 26 03:53:36.855: HSRP: Fa0/0 Nbr 124.124.124.2 no longer standby for group 124 (Active)
Dec 26 03:53:36.855: HSRP: Fa0/0 Grp 124 Active -> Speak
Dec 26 03:53:36.855: %HSRP-5-STATECHANGE: FastEthernet0/0 Grp 124 state Active -> Speak
Dec 26 03:53:36.855: HSRP: Fa0/0 Interface adv out, Passive, active 0 passive 1
Dec 26 03:53:36.855: HSRP: Fa0/0 Grp 124 Redundancy "hsrp-Fa0/0-124" state Active -> Speak
Dec 26 03:53:36.859: HSRP: Fa0/0 Removed 124.124.124.254 from ARP
Dec 26 03:53:36.859: HSRP: Fa0/0 Grp 124 Deactivating MAC 0000.0c07.ac7c
Dec 26 03:53:36.859: HSRP: Fa0/0 Grp 124 Removing 0000.0c07.ac7c from MAC address filter
Dec 26 03:53:36.863: HSRP: Fa0/0 Grp 124 MAC addr update Delete from SMF  0000.0c07.ac7c
Dec 26 03:53:36.867: HSRP: Fa0/0 Grp 124 Hello  out 124.124.124.1 Speak   pri 90 vIP 124.124.124.254
Dec 26 03:53:36.875: HSRP: Fa0/0 IP Redundancy "hsrp-Fa0/0-124" update, Active -> Speak
Dec 26 03:53:36.879: HSRP: Fa0/0 Interface adv in, Active, active 1, passive 0, from 124.124.124.2
Dec 26 03:53:39.835: HSRP: Fa0/0 Grp 124 Hello  in  124.124.124.2 Active  pri 100 vIP 124.124.124.254
Dec 26 03:53:39.871: HSRP: Fa0/0 Grp 124 Hello  out 124.124.124.1 Speak   pri 90 vIP 124.124.124.254

ActiveR2Ȥʤ뤳Ȥʬޤ

R1(config-if)#do sh stan br
                     P indicates configured to preempt.
                     |
Interface   Grp  Pri P State   Active          Standby         Virtual IP
Fa0/0       124  90  P Standby 124.124.124.2   local           124.124.124.254
R1(config-if)#do sh track
Track 1
  IP route 13.13.13.0 255.255.255.0 reachability
  Reachability is Down (no route)
    6 changes, last change 00:03:38
  First-hop interface is unknown
  Tracked by:
    HSRP FastEthernet0/0 124

ƥ:

RIPǥ˥㥹ȤѤʤɤǧޤEIGRPǥ˥㥹ȤѤˡǧޤ

R1R2ľ뤷ƤF0/0EIGRPѤޤ

R1(config)#do sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            12.12.12.1      YES manual up                    up
Loopback0                  17.17.1.1       YES NVRAM  up                    up

R2(config)#do sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            12.12.12.2      YES manual up                    up
Loopback0                  17.17.2.2       YES NVRAM  up                    up

ޤR1R2Ǻ¤EIGRPꤷޤ

R1(config)#router eigrp 100
R1(config-router)#no auto-summary
R1(config-router)#network 12.12.12.1 0.0.0.0

¹Ը塢ǧޤ

R1(config-router)#do sh ip ei int
IP-EIGRP interfaces for process 100

                        Xmit Queue   Mean   Pacing Time   Multicast    Pending
Interface        Peers  Un/Reliable  SRTT   Un/Reliable   Flow Timer   Routes
Fa0/0              1        0/0        13       0/1           50           0
R1(config-router)#do sh ip ei nei
IP-EIGRP neighbors for process 100
H   Address                 Interface       Hold Uptime   SRTT   RTO  Q  Seq
                                            (sec)         (ms)       Cnt Num
0   12.12.12.2              Fa0/0             11 00:01:41   13   200  0  4

λǤΥѥåȤǥХdzǧȡޥ㥹(224.0.0.10)ѤƤ뤳Ȥʬޤ

R2#deb ip packet detail
IP packet debugging is on (detailed)
R2#
Dec 20 06:18:42.095: IP: s=12.12.12.1 (FastEthernet0/0), d=224.0.0.10, len 60, rcvd 2, proto=88
Dec 20 06:18:44.791: IP: s=12.12.12.2 (local), d=224.0.0.10 (FastEthernet0/0), len 60, sending broad/multicast, proto=88

EIGRPǥ˥㥹ȤѤˤneighborޥɤѤޤ

R1(config-router)#neighbor 12.12.12.2 f0/0

R2(config-router)#neighbor 12.12.12.1 f0/0

¹Ը塢ѥåȤǧȥޥ㥹ȤǤϤʤ˥㥹ȥɥ쥹(12.12.12.2)ѤƤ뤳Ȥʬޤ

Dec 20 06:20:27.563: IP: s=12.12.12.1 (FastEthernet0/0), d=12.12.12.2 (FastEthernet0/0), len 60, rcvd 3, proto=88
Dec 20 06:20:27.735: IP: s=12.12.12.2 (local), d=12.12.12.1 (FastEthernet0/0), len 60, sending, proto=88

ƥ:

̾RIPϥޥ㥹ȤѤƥ롼ƥ󥰾ήޤ˥㥹Ȥ֥ɥ㥹ȤѤ뤳ȤǽǤ

R1(config)#do sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            12.12.12.1      YES manual up                    up
Loopback0                  17.17.1.1       YES NVRAM  up                    up

R2(config)#do sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            12.12.12.2      YES manual up                    up
Loopback0                  17.17.2.2       YES NVRAM  up                    up

R1R2RIPԤޤ

R1(config)#router rip
R1(config-router)#no auto-summary
R1(config-router)#version 2
R1(config-router)#network 12.12.12.1
R1(config-router)#network 17.17.1.1

塢ǥХ̤򸫤ȥޥ㥹(224.0.0.9)ѤƤ뤳ȤǧǤޤ

R2(config-router)#do deb ip rip
RIP protocol debugging is on
Dec 11 05:54:42.151: RIP: received v2 update from 12.12.12.1 on FastEthernet0/0
Dec 11 05:54:42.151:      17.17.1.0/24 via 0.0.0.0 in 1 hops
Dec 11 05:54:52.475: RIP: sending v2 update to 224.0.0.9 via Loopback0 (17.17.2.2)
Dec 11 05:54:52.479: RIP: build update entries
Dec 11 05:54:52.479:    12.12.12.0/24 via 0.0.0.0, metric 1, tag 0
Dec 11 05:54:52.483:    17.17.1.0/24 via 0.0.0.0, metric 2, tag 0

˥㥹ȤѤˤϤޤpassive-interfaceޥɤRIPߤޤneighborޥɤܥ롼ꤷޤ

R1(config-router)#passive-interface f0/0
R1(config-router)#neighbor 12.12.12.2

ǥХǧȥ˥㥹(12.12.12.1)ѹ줿ȤǧǤޤ

Dec 11 05:57:46.843: RIP: received v2 update from 12.12.12.1 on FastEthernet0/0
Dec 11 05:57:46.843:      17.17.1.0/24 via 0.0.0.0 in 1 hops
Dec 11 05:58:05.067: RIP: sending v2 update to 12.12.12.1 via FastEthernet0/0 (12.12.12.2)
Dec 11 05:58:05.067: RIP: build update entries

Ǹ˥֥ɥ㥹ȤǧޤޤۤɤΥ˥㥹Ȥޤ

R1(config-router)#no passive-interface f0/0
R1(config-router)#no neighbor 12.12.12.2

ϥ󥿡եǹԤip rip v2-broadcastޥɤѤޤ

R1(config-router)#int f0/0
R1(config-if)#ip rip v2-broadcast

ȡΤ˥֥ɥ㥹(255.255.255.255)Ѥ뤳Ȥʬޤ

Dec 11 06:00:53.591: RIP: sending v2 update to 255.255.255.255 via FastEthernet0/0 (12.12.12.2)
Dec 11 06:00:53.595: RIP: build update entries
R2(config-router)#do und all
R2(config-router)#do deb ip pac de
IP packet debugging is on (detailed)
R2(config-router)#
Dec 11 06:20:10.495: IP: s=12.12.12.1 (FastEthernet0/0), d=255.255.255.255, len 52, rcvd 2
Dec 11 06:20:10.499:     UDP src=520, dst=520

ƥ:

Cisco롼桢LinuxǤ褯ȤnetstatϤʤäȻפȤ褯ޤʻshow tcpޥɤ϶ᤤǤ

R1#show ip interface brief
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            12.12.12.1      YES manual up                    up
Loopback0                  17.17.1.1       YES NVRAM  up                    up

R2#sh ip int b
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            12.12.12.2      YES manual up                    up
Loopback0                  17.17.2.2       YES NVRAM  up                    up

R1R2ꡢR1R2Фtelnet³Ԥޤ

R1#telnet 12.12.12.2
Trying 12.12.12.2 ... Open

User Access Verification

Password:
R2>

³λ顢show tcp briefޥɤ¹ԤƤߤޤnetstat -tߤʴǤ͡

R2#show tcp brief
TCB       Local Address               Foreign Address             (state)
6738A76C  12.12.12.2.23               12.12.12.1.27603            ESTAB

ɽTCB(Transmission Control Block)ꤹȾܺ٤ɽȤʤޤ

R2#show tcp tcb 6738A76C
Connection state is ESTAB, I/O status: 1, unread input bytes: 0
Connection is ECN Disabled, Mininum incoming TTL 0, Outgoing TTL 255
Local host: 12.12.12.2, Local port: 23
Foreign host: 12.12.12.1, Foreign port: 27603
Connection tableid (VRF): 0

Enqueued packets for retransmit: 0, input: 0  mis-ordered: 0 (0 bytes)

Event Timers (current time is 0x1DFDC0):
Timer          Starts    Wakeups            Next
Retrans            75          0             0x0
TimeWait            0          0             0x0
AckHold            76          4             0x0
SendWnd             0          0             0x0
KeepAlive           0          0             0x0
GiveUp              0          0             0x0
PmtuAger            0          0             0x0
DeadWait            0          0             0x0
Linger              0          0             0x0
ProcessQ            0          0             0x0

iss:  732715540  snduna:  732720033  sndnxt:  732720033     sndwnd:   3023
irs:  636591890  rcvnxt:  636592009  rcvwnd:       4010  delrcvwnd:    118

SRTT: 300 ms, RTTO: 303 ms, RTV: 3 ms, KRTT: 0 ms
minRTT: 12 ms, maxRTT: 300 ms, ACK hold: 200 ms
Status Flags: passive open, active open
Option Flags: 0x400000
IP Precedence value : 6

Datagrams (max data segment is 1460 bytes):
Rcvd: 135 (out of order: 0), with data: 80, total data bytes: 118
Sent: 103 (retransmit: 0, fastretransmit: 0, partialack: 0, Second Congestion: 0), with data: 98, total data bytes: 4492
Packets received in fast path: 0, fast processed: 0, slow path: 0
Packets send in fast path: 0
fast lock acquisition failures: 0, slow path: 0

show tcp statisticsȤޥɤ⤢ޤ

R2#show tcp statistics
Rcvd: 217 Total, 0 no port
      0 checksum error, 0 bad offset, 0 too short
      133 packets (246 bytes) in sequence
      0 dup packets (0 bytes)
      0 partially dup packets (0 bytes)
      0 out-of-order packets (0 bytes)
      0 packets (0 bytes) with data after window
      0 packets after close
      0 window probe packets, 2 window update packets
      3 dup ack packets, 0 ack packets with unsend data
      112 ack packets (4973 bytes)
Sent: 166 Total, 0 urgent packets
      7 control packets (including 0 retransmitted)
      142 data packets (4966 bytes)
      0 data packets (0 bytes) retransmitted
      0 data packets (0 bytes) fastretransmitted
      17 ack only packets (14 delayed)
      0 window probe packets, 0 window update packets
0 Connections initiated, 4 connections accepted, 4 connections established
3 Connections closed (including 0 dropped, 0 embryonic dropped)
0 Total rxmt timeout, 0 connections dropped in rxmt timeout
0 Keepalive timeout, 0 keepalive probe, 0 Connections dropped in keepalive

ΥڡΥȥåץ

Ф