国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 學院 > 網絡通信 > 正文

熟悉常用的IP相關命令

2019-11-04 20:48:48
字體:
來源:轉載
供稿:網友

  ip相關命令很多,本實驗主要對常用的IP相關命令進行練習。
  
  1.實驗目的
  
  通過本實驗。讀者可以把握以下技能:
  使用ip address和ip address secondary命令;
  使用show interface、show ip interface和show ip interface brief命令;
  使用ip subnet-zero命令;
  使用arp相關命令;
  使用ip domain-lookup、ipdomain-name、ip name-server命令;
  使用terminal ip metmask-format。
  
  2. 設備需求
  
  本實驗需要以下設備:
  2臺Cisco路由器,要求每臺至少具有1個以太網接口;
  1臺Hub,2條雙絞線;
  1臺終端服務器,如Cisco 2509路由器,及用于反向Telnet的相應線纜;
  1臺帶有超級終端程序的PC機,以及Comsole電纜及轉接器。
  
  3.拓撲結構及配置說明
  
  從本章開始,在實驗中將以拓撲結構圖代替設備連接圖,以便明確參與實驗的主要設備之間的關系。在實驗中必須的PC機、終端服務器、Hub及相應線纜等在拓撲圖中不再出現。
  本實驗的拓撲結構如圖4.1所示,兩臺路由器通過Hub連接到一起。
  
熟悉常用的IP相關命令

  
  兩臺路由器分別為R1和R2,用于與Hub連接的接口均為E0接口。R1路由器E0接口IP地址為172.16.1.1,R2路由器E0接口IP地址為172.16.1.2,子網掩碼均為255.255.255.0。
  
  4. 實驗配置及監(jiān)測結果
  
  用PC機通過終端服務器訪問R1和R2,開始進行實驗。
  
  第1部分:ip address。ip address secondary、show interface等命令
  
  監(jiān)測清單4-1記錄了這部分實驗的操作過程。
  
  監(jiān)測清單4-1 ip address、ip address secondary、show interface等命令
  
  R1#
  R1#conft
  Enter configuration commands, one per line. End with CNTL/Z.
  R1(config)#int e0
  R1(config-if)#ip addr 172.16.1.1255.255.255.0
  R1(config-if)#no sh
  R1(config-if)#end
  R1#
  00:51:18: %SYS-5-CONFIG_1: Configured from console by console
  (鍵入組合鍵Ctrl+shift+6,x,切換回終端服務器)
  Term_Server>2
  [Resuming connection 2 to R2 ... ]
  R2#
  R2#conft
  Enter configuration commands, one per line. End with CNTL/Z.
  R2(config)#int eO
  R2(config-if)#ip addr 172.16.1.2 255.255.255.0
  R2(config-if)#no sh
  R2(config-if)#end
  R2#
  00:52:58: %SYS-5-CG_I: Configured from console by console
  R2#sh int eO
  Ethernet0 is up, line PRotocol is up
  Hardware is
  Internet address is 172.16.1.2/24
  MTU 1500 bytes,BW 1000 Kbit,DLY 1000 usec.
   reliability 255/255,txload 1/255,rxload 1/255
  Encapsulation ARPA, loopback not set
  Keepalive set (10 sec)
  ARP type: ARPA, ARP Timeout 04:00:00
  Last input 00:00:10, output 00:00:09, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0
  Queueing strategy:fifo
  Output queue :0/40 (size/max)
  5 minute input rate Orbits/see, ;1:pactets/sec
  5 minute output
   203 packets input, 29123 bytes, 0 no buffer
   Received 203 broadcasts, 0 runts, 0 giants, 0 throttles
   0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
   0 input packets with dribble condition detected
   382 packets output, 37648 bytes, 0 underruns
   0 output errors, 0 collisions, 18 interface resets
   0 babbles, 0 late collision, 0 deferred
   0 lost carrier, 0 no carrier
   0 output buffer failures, 0 output buffers swapped out
  R2#sh ip int eO
  EthemetO is up, line protocol is up
  Internet address is 172.16.1.2.2/24
  Broadcast address is 255.255.255.255
  Adress determined by setup command
  MTU is 1500 bytes
  Helper address is not set
  Directed broadcast forwarding is desabled
  lutgoing access list is not set
  Inbound access list is not set
  Proxy ARP is enabled
  security level is default
  split horion is enabled
  ICMP redirects are always sent
  ICMP unreachables are always sent
  IP fast switching is enabled
  IP fast switching on the same interface is disabled
  IP Flow switching is disabled
  IP Fast switching turbo vector
  IP multicast fast switching is enabled
  IP multicast distributed fast switching is disabled
  IP route-cache flags are Fast
  Router Discovery is disabled
  IP output packet accounting is disabled
  IP access violation accounting is disabled
  TCP/IP header compression is disabled
  RTP/IP header compression is disabled
  Probe proxy name replies are disabled
  Policy routing is disabled
  Network address translation is disabled
  WCCP Redirect outbound is disabled
  WCCP Redirect exclude is disabled
  BGP Policy Mapping is disabled
  R2#SH IP int brief
  interface       IP-Address     ok?Method status     protocol
  Ethernet0       170.16.1.2     YES manual up       up
  serial0        unassigned     YES NVRAM  administratively down down
  serial1        unassigned     YES NVRAM  administratively down down 
  R2#ping 172.16.1.1
  Type escape sequence to abort.
  sending 5,100-byte ICMPEchos to 172.16.1.1,timeout is 2 seconds:
  ..!!!
  sUCcess rate is 60 percent(3/5),round-trip min/avg/max=4/4/4 ms
  R2#conft
  Enter configuration commands,one per line.End winth CNTL/Z
  R2(config)#ip subnet-zero
  R2(config)#ing e0
  R2(config-if)#ip addr 172.0.0.1 255.255.255.0
  Bad mask/24 for address 172.0.0.1
  R2(config-if)#exit
  R2(config)#if subnet-zero
  R2(config)#int e0
  R2(config-if)#ip addr 172.0.0.1255.255.255.0
  R2(config-if)#ip addr 172.1.0.1 255.255.255.0 secondary
  R2(config-if)#ip addr 172.2.0.1 255.255.255.0 secondary
  R2(config-if)#^Z
  R2#
  (1)在監(jiān)測清單的開始部分,分別在Rl和R2路由器的EO接口上配置了相應的IP地址。注重配置好IP地址后立即發(fā)出了Ho shut命令激活接口,初學者往往忽視此命令。
  (2)sh int e0命令即show interface e0,其運行結果顯示了EO接口的配置信息和統(tǒng)計信息,其中大部分是統(tǒng)計信息。配置信息有MAC地址(0000。0c8e。cdd2)、IP地址、MTU(15OOBytes)、BW(帶寬,lOMbMs)、DLY(延遲)。reliability(可靠性)以及負載 (txload和rxload)等信息;統(tǒng)計信息是關于隊列(而putqueue、Output queue)、最近5min時間內的輸入、輸出速率及數據包數量等信息。
  (3)show ip interface e0(sh ip int eo)命令顯示了EO接口上有關IP的所有配置信息,包括IP地址、廣播地址、MTU、訪問列表。Proxy ARP等眾多條目我們應主要關注與CCNA考試相關的條目。
  (4),show ip interface e0(sh ip int brief)以簡潔的形式列出了路由器所有接口有關IP地址的配置信息,包括接口IP地址、是否可用 (OK?)、IP地址獲取的方式 (Method)。接口狀態(tài)(Status)和協(xié)議狀態(tài)(Protocol)。其中manual表示人工設置,NVRAM表示啟動時從配置文件中獲取。
  (5)使用Ping命令測試Rl和R2的IP連通性,以確認配置是否生效。注重ping命令執(zhí)行結果中的細節(jié),即"..!!!",這表示前兩個包沒有ping通,這是因為開始時在R2的ARP表中還沒有R1的EO接口相關的表項,即不知道172.16.1.1的MAC地址是什么,在下面關于ARP相關命令的實驗中,這一點會非常清楚地顯示出來。
  (6)在IOS11.3以后的版本中,ip subnet-zero語句成為Cisco路由器的缺省配置。它使得零子網成為合法的網絡號。在實驗中,首先關閉了此功能,即發(fā)出命令no ip subnet-zero,當設置EO接口的IP地址為172.0.0.1時,路由器報錯;當發(fā)出命令ip subnet-zero答應零子網存在時,對EO接口重復上述的配置命令時,IP地址被成功設置。
  (7)ip addr 172.1.0.1.255.255.255.0 secondary命令為EO接


發(fā)表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發(fā)表
主站蜘蛛池模板: 濮阳市| 德保县| 五原县| 景洪市| 西昌市| 鄂尔多斯市| 遂溪县| 海原县| 四子王旗| 项城市| 宁明县| 高阳县| 宽城| 玉门市| 崇礼县| 巨鹿县| 皋兰县| 怀集县| 三明市| 通州区| 县级市| 惠州市| 库车县| 宜丰县| 昌江| 苏尼特左旗| 石家庄市| 平潭县| 北海市| 温泉县| 望谟县| 和田市| 布拖县| 卢氏县| 灌阳县| 盖州市| SHOW| 聊城市| 肇源县| 康马县| 五河县|