版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報或認(rèn)領(lǐng)
文檔簡介
附件:1.外文資料翻譯譯文TCP/IP介紹在MicrosoftWindows計算機(jī)上配置TCP/IP協(xié)議時,TCP/IP配置設(shè)置中需要IP地址和子網(wǎng)掩碼,通常還需要一個默認(rèn)網(wǎng)關(guān)。要正確配置TCP/IP,有必要了解TCP/IP網(wǎng)絡(luò)的尋址方式以及網(wǎng)絡(luò)和子網(wǎng)的劃分方式。本文旨在對IP網(wǎng)絡(luò)和子網(wǎng)的概念進(jìn)行一般性介紹。本文結(jié)尾包含一個術(shù)語表。更多信息作為Internet的網(wǎng)絡(luò)協(xié)議,TCP/IP的成功在很大程度上歸功于它將不同大小的網(wǎng)絡(luò)和不同類型的系統(tǒng)連接在一起的能力。這些網(wǎng)絡(luò)被強(qiáng)制定義為具有預(yù)定義大小的三個主要類(還有其他一些類別),每一類都可以由系統(tǒng)管理員分成更小的子網(wǎng)。子網(wǎng)掩碼用于將IP地址分成兩個部分。一部分標(biāo)識主機(jī)(計算機(jī)),另一部分標(biāo)識它所屬的網(wǎng)絡(luò)。查看IP(Internet協(xié)議)地址并研究它的組織方式可以幫助您更好地理解IP地址和子網(wǎng)掩碼的工作方式。TCP的服務(wù)盡管TCP和UDP都使用相同的網(wǎng)絡(luò)層(IP),TCP卻向應(yīng)用層提供與UDP完全不同的服務(wù)。
TCP提供一種面向連接的、可靠的字節(jié)流服務(wù)。面向連接意味著兩個使用TCP的應(yīng)用(通常是一個客戶和一個服務(wù)器)在彼此交換數(shù)據(jù)之前必須先建立一個TCP連接。這一過程與打電話很相似,先撥號振鈴,等待對方摘機(jī)說“喂”,然后才說明是誰。在一個TCP連接中,僅有兩方進(jìn)行彼此通信。廣播和多播不能用于TCP。
TCP通過下列方式來提供可靠性:
應(yīng)用數(shù)據(jù)被分割成TCP認(rèn)為最適合發(fā)送的數(shù)據(jù)塊。這和UDP完全不同,應(yīng)用程序產(chǎn)生的數(shù)據(jù)報長度將保持不變。由TCP傳遞給IP的信息單位稱為報文段或段(segment)TCP如何確定報文段的長度。當(dāng)TCP發(fā)出一個段后,它啟動一個定時器,等待目的端確認(rèn)收到這個報文段。如果不能及時收到一個確認(rèn),將重發(fā)這個報文段。在第21章我們將了解TCP協(xié)議中自適應(yīng)的超時及重傳策略。
當(dāng)TCP收到發(fā)自TCP連接另一端的數(shù)據(jù),它將發(fā)送一個確認(rèn)。這個確認(rèn)不是立即發(fā)送,通常將推遲幾分之一秒
TCP將保持它首部和數(shù)據(jù)的檢驗和。這是一個端到端的檢驗和,目的是檢測數(shù)據(jù)在傳輸過程中的任何變化。如果收到段的檢驗和有差錯,TCP將丟棄這個報文段和不確認(rèn)收到此報文段(希望發(fā)端超時并重發(fā))。既然TCP報文段作為IP數(shù)據(jù)報來傳輸,而IP數(shù)據(jù)報的到達(dá)可能會失序,因此TCP報文段的到達(dá)也可能會失序。如果必要,TCP將對收到的數(shù)據(jù)進(jìn)行重新排序,將收到的數(shù)據(jù)以正確的順序交給應(yīng)用層。
既然IP數(shù)據(jù)報會發(fā)生重復(fù),TCP的接收端必須丟棄重復(fù)的數(shù)據(jù)。
TCP還能提供流量控制。TCP連接的每一方都有固定大小的緩沖空間。TCP的接收端只允許另一端發(fā)送接收端緩沖區(qū)所能接納的數(shù)據(jù)。這將防止較快主機(jī)致使較慢主機(jī)的緩沖區(qū)溢出。兩個應(yīng)用程序通過TCP連接交換8bit字節(jié)構(gòu)成的字節(jié)流。TCP不在字節(jié)流中插入記錄標(biāo)識符。我們將這稱為字節(jié)流服務(wù)(bytestreamservice)。如果一方的應(yīng)用程序先傳10字節(jié),又傳20字節(jié),再傳50字節(jié),連接的另一方將無法了解發(fā)方每次發(fā)送了多少字節(jié)。收方可以分4次接收這80個字節(jié),每次接收20字節(jié)。一端將字節(jié)流放到TCP連接上,同樣的字節(jié)流將出現(xiàn)在TCP連接的另一端。另外,TCP對字節(jié)流的內(nèi)容不作任何解釋。TCP不知道傳輸?shù)臄?shù)據(jù)字節(jié)流是二進(jìn)制數(shù)據(jù),還是ASCII字符、EBCDIC字符或者其他類型數(shù)據(jù)。對字節(jié)流的解釋由TCP連接雙方的應(yīng)用層解釋。這種對字節(jié)流的處理方式與Unix操作系統(tǒng)對文件的處理方式很相似。Unix的內(nèi)核對一個應(yīng)用讀或?qū)懙膬?nèi)容不作任何解釋,而是交給應(yīng)用程序處理。對Unix的內(nèi)核來說,它無法區(qū)分一個二進(jìn)制文件與一個文本文件。TCP是因特網(wǎng)中的傳輸層協(xié)議,使用三次握手協(xié)議建立連接。當(dāng)主動方發(fā)出SYN連接請求后,等待對方回答SYN,ACK。這種建立連接的方法可以防止產(chǎn)生錯誤的連接,TCP使用的流量控制協(xié)議是可變大小的滑動窗口協(xié)議。第一次握手:建立連接時,客戶端發(fā)送SYN包(SEQ=x)到服務(wù)器,并進(jìn)入SYN_SEND狀態(tài),等待服務(wù)器確認(rèn)。第二次握手:服務(wù)器收到SYN包,必須確認(rèn)客戶的SYN(ACK=x+1),同時自己也送一個SYN包(SEQ=y),即SYN+ACK包,此時服務(wù)器進(jìn)入SYN_RECV狀態(tài)。第三次握手:客戶端收到服務(wù)器的SYN+ACK包,向服務(wù)器發(fā)送確認(rèn)包ACK(ACK=y+1),此包發(fā)送完畢,客戶端和服務(wù)器時入Established狀態(tài),完成三次握手。IP地址:網(wǎng)絡(luò)和主機(jī)IP地址是一個32位數(shù)字,它唯一地標(biāo)識TCP/IP網(wǎng)絡(luò)上的主機(jī)(計算機(jī)或其他設(shè)備,如打印機(jī)或路由器)。IP地址通常以點分十進(jìn)制格式表示,四個數(shù)字由句點分隔,例如32。要了解子網(wǎng)掩碼如何用于區(qū)分不同的主機(jī)、網(wǎng)絡(luò)和子網(wǎng),請查看以二進(jìn)制表示的IP地址。例如,點分十進(jìn)制IP地址32在二進(jìn)制表示法中為32位數(shù)字110000000101000111101110000100。此數(shù)字的含義可能很難理解,因此它被分成四個部分,每個部分有八個二進(jìn)制數(shù)字。這些八位部分稱為八位組。示例IP地址于是變成11000000.10101000.01111011.10000100。此數(shù)字表示的含義只是稍微明白了一點,因此在大多數(shù)應(yīng)用中,會將二進(jìn)制地址轉(zhuǎn)換為點分十進(jìn)制格式(32)。點分十進(jìn)制數(shù)字是從二進(jìn)制轉(zhuǎn)換為十進(jìn)制表示法的八位組。為了讓TCP/IP廣域網(wǎng)(WAN)以一個網(wǎng)絡(luò)集的形式高效工作,在網(wǎng)絡(luò)間傳遞數(shù)據(jù)包的路由器并不知道信息包的目標(biāo)主機(jī)的確切位置。路由器只知道主機(jī)是哪一個網(wǎng)絡(luò)的成員,并使用存儲在路由表中的信息來確定如何將數(shù)據(jù)包送達(dá)目標(biāo)主機(jī)的網(wǎng)絡(luò)。當(dāng)數(shù)據(jù)包被傳送到目標(biāo)網(wǎng)絡(luò)后,該數(shù)據(jù)包就會被傳送到相應(yīng)的主機(jī)。為了讓此過程順利進(jìn)行,IP地址分為兩個部分。IP地址的前一部分作為網(wǎng)絡(luò)地址,后一部分作為主機(jī)地址。以32為例,將它分為這兩個部分之后,會得到:192.168.123.網(wǎng)絡(luò),.132主機(jī),-或-,—網(wǎng)絡(luò)地址,32—主機(jī)地址。子網(wǎng)掩碼第二項是子網(wǎng)掩碼,它是TCP/IP正常工作所必需的。TCP/IP協(xié)議使用子網(wǎng)掩碼確定主機(jī)是在本地子網(wǎng)中還是在遠(yuǎn)程網(wǎng)絡(luò)中。在TCP/IP中,將哪部分IP地址用作網(wǎng)絡(luò)地址和主機(jī)地址并不固定,所以除非您掌握詳細(xì)的信息,否則無法確定上述網(wǎng)絡(luò)地址和主機(jī)地址。此信息在另一個32位數(shù)字中提供,稱為子網(wǎng)掩碼。在本例中,子網(wǎng)掩碼為。如果您不知道二進(jìn)制表示法中的255等于11111111,可能并不清楚該數(shù)字表示的含義。照此分析,子網(wǎng)掩碼為:11111111.11111111.11111111.0000000將IP地址和子網(wǎng)掩碼排列在一起比較,就可以分清該地址的網(wǎng)絡(luò)部分和主機(jī)部分:11000000.10101000.01111011.10000100--IP地址(32)11111111.11111111.11111111.00000000--子網(wǎng)掩碼()前24位(子網(wǎng)掩碼中的數(shù)字1)被標(biāo)識為網(wǎng)絡(luò)地址,后8位(子網(wǎng)掩碼中剩余的數(shù)字0)被標(biāo)識為主機(jī)地址,據(jù)此可以得到:11000000.10101000.01111011.00000000--網(wǎng)絡(luò)地址()00000000.00000000.00000000.10000100--主機(jī)地址(000.000.000.132)這樣,我們就可以知道,在這個使用子網(wǎng)掩碼的示例中,網(wǎng)絡(luò)ID為,主機(jī)地址為32。當(dāng)數(shù)據(jù)包到達(dá)子網(wǎng)(從本地子網(wǎng)或遠(yuǎn)程網(wǎng)絡(luò)),而且它的目標(biāo)地址為32時,您的計算機(jī)將從網(wǎng)絡(luò)接收它并對它進(jìn)行處理。幾乎所有十進(jìn)制子網(wǎng)掩碼都轉(zhuǎn)換為左側(cè)全部是一、右側(cè)全部是零的二進(jìn)制數(shù)字。其他一些常見的子網(wǎng)掩碼有:十進(jìn)制 二進(jìn)制921111111.11111111.1111111.11000000241111111.11111111.1111111.11100000InternetRFC1878(從獲取)描述了可在TCP/IP網(wǎng)絡(luò)中使用的有效子網(wǎng)和子網(wǎng)掩碼。網(wǎng)絡(luò)類Internet地址由管理Internet的機(jī)構(gòu)InterNIC()來分配。這些IP地址分成若干類。其中最常見的是A、B和C類。也有D和E類,但是最終用戶通常不會使用。每個地址類都有不同的默認(rèn)子網(wǎng)掩碼??梢酝ㄟ^查看IP地址的第一個八位組來識別該IP地址的類別。下面是A、B和C類Internet地址的范圍,每一類地址都有一個示例:A類網(wǎng)絡(luò)使用的默認(rèn)子網(wǎng)掩碼為,第一個八位組為0-127。地址1就是一個A類地址。它的第一個八位組為10,介于1至126之間(包括1和126)。B類網(wǎng)絡(luò)使用的默認(rèn)子網(wǎng)掩碼為,第一個八位組為128-191。地址3就是一個B類地址。它的第一個八位組為172,介于128至191之間(包括128和191)。C類網(wǎng)絡(luò)使用的默認(rèn)子網(wǎng)掩碼為,第一個八位組為192-223。地址32就是一個C類地址。它的第一個八位組192,介于192至223之間(包括192和223)。在某些情況下,由于網(wǎng)絡(luò)的物理拓?fù)浠蛞驗榫W(wǎng)絡(luò)(或主機(jī))的數(shù)目在默認(rèn)的子網(wǎng)掩碼限制之下并不適用,所以默認(rèn)子網(wǎng)掩碼值可能不適合機(jī)構(gòu)的需要。下一部分將解釋如何使用子網(wǎng)掩碼劃分網(wǎng)絡(luò)。子網(wǎng)配置系統(tǒng)管理員可以進(jìn)一步劃分A、B或C類TCP/IP網(wǎng)絡(luò)或?qū)@些網(wǎng)絡(luò)進(jìn)行子網(wǎng)配置。當(dāng)您將Internet的邏輯地址結(jié)構(gòu)(IP地址和子網(wǎng)的抽象世界)與真實世界中使用的物理網(wǎng)絡(luò)進(jìn)行協(xié)調(diào)時,就有必要進(jìn)行子網(wǎng)配置。接受IP地址塊分配的系統(tǒng)管理員可以用輕松符合這些地址的方式管理未經(jīng)組織的網(wǎng)絡(luò)。例如,您有一個廣域網(wǎng),在該廣域網(wǎng)中,TCP/IP路由器連接的三個網(wǎng)絡(luò)(位于不同城市)中有150個主機(jī)。這三個網(wǎng)絡(luò)中的每個網(wǎng)絡(luò)都有50個主機(jī)。向您分配了C類網(wǎng)絡(luò)。(此地址是為了便于說明,實際上來自Internet中未分配的范圍。)這意味著可以將地址至54用于您的150個主機(jī)。在示例中不能使用的兩個地址為和55,因為主機(jī)部分全部為一和全部為零的二進(jìn)制地址無效。零地址無效的原因是使用它在未指定主機(jī)的情況下指定了網(wǎng)絡(luò)。255地址(在二進(jìn)制表示法中全部為一的主機(jī)地址)用來向網(wǎng)絡(luò)中的每個主機(jī)廣播消息。只需記住,任何網(wǎng)絡(luò)或子網(wǎng)中的第一個地址和最后一個地址不能分配給任何單獨(dú)主機(jī)。現(xiàn)在,您應(yīng)該能夠?qū)P地址給予254個主機(jī)。如果所有150臺計算機(jī)都在一個網(wǎng)絡(luò)中,則此操作會進(jìn)行得很順利。但是,您的150臺計算機(jī)位于三個單獨(dú)的物理網(wǎng)絡(luò)中。不用為每個網(wǎng)絡(luò)請求更多地址塊,只需將網(wǎng)絡(luò)分成使您可以在多個物理網(wǎng)絡(luò)中使用一個地址塊的子網(wǎng)。在此情況下,使用使網(wǎng)絡(luò)地址更大和可能的主機(jī)地址范圍更小的子網(wǎng)掩碼將網(wǎng)絡(luò)分成四個子網(wǎng)。也就是說,您正在“借用”某些通常用于主機(jī)地址的位,并將它們用于地址的網(wǎng)絡(luò)部分。子網(wǎng)掩碼92給予您四個網(wǎng)絡(luò),每個網(wǎng)絡(luò)有62個主機(jī)。由于用二進(jìn)制表示92與1111111.11111111.1111111.11000000相同,所以此操作可以順利進(jìn)行。最后一個八位組的前兩位數(shù)字變?yōu)榫W(wǎng)絡(luò)地址,所以您獲得了附加網(wǎng)絡(luò)00000000(0)、01000000(64)、10000000(128)和11000000(192)。(某些管理員只使用將92作為子網(wǎng)掩碼的其中兩個子網(wǎng)。有關(guān)此主題的更多信息,請參閱RFC1878。)在這四個網(wǎng)絡(luò)中,最后6個二進(jìn)制數(shù)字可用于主機(jī)地址。使用子網(wǎng)掩碼92,則您的網(wǎng)絡(luò)變?yōu)樗膫€網(wǎng)絡(luò)、4、28和92。這四個網(wǎng)絡(luò)將擁有以下有效主機(jī)地址:-625-12629-19093-254再次重審,全部為一或全部為零的二進(jìn)制主機(jī)地址無效,所以您不能使用最后一個八位組為0、63、64、127、128、191、192或255的地址?,F(xiàn)在,看兩個主機(jī)地址1和33,您就會了解其原理。如果使用默認(rèn)C類子網(wǎng)掩碼則這兩個地址都位于網(wǎng)絡(luò)中。但是,如果使用子網(wǎng)掩碼92,則它們位于不同網(wǎng)絡(luò)中;1位于4網(wǎng)絡(luò)中,33位于28網(wǎng)絡(luò)中。默認(rèn)網(wǎng)關(guān)如果TCP/IP計算機(jī)需要與另一個網(wǎng)絡(luò)中的主機(jī)進(jìn)行通信,它通常通過稱為路由器的設(shè)備進(jìn)行通信。在TCP/IP語中,主機(jī)中指定的、用于將主機(jī)子網(wǎng)鏈接到其他網(wǎng)絡(luò)的路由器稱為默認(rèn)網(wǎng)關(guān)。本節(jié)解釋TCP/IP如何確定是否將數(shù)據(jù)包發(fā)送到其默認(rèn)網(wǎng)關(guān)以到達(dá)網(wǎng)絡(luò)中的另一臺計算機(jī)或設(shè)備。當(dāng)主機(jī)嘗試使用TCP/IP與另一個設(shè)備進(jìn)行通信時,它會使用已定義的子網(wǎng)掩碼和目標(biāo)IP地址針對子網(wǎng)掩碼和其自己的IP地址進(jìn)行比較。比較結(jié)果會告訴計算機(jī)目標(biāo)是本地主機(jī)還是遠(yuǎn)程主機(jī)。如果此過程的結(jié)果確定目標(biāo)是本地主機(jī),則計算機(jī)只將數(shù)據(jù)包發(fā)送到本地子網(wǎng)。如果比較結(jié)果確定目標(biāo)是遠(yuǎn)程主機(jī),則計算機(jī)將數(shù)據(jù)包轉(zhuǎn)發(fā)到其TCP/IP屬性中定義的默認(rèn)網(wǎng)關(guān)。然后,路由器負(fù)責(zé)將數(shù)據(jù)包轉(zhuǎn)發(fā)到正確的子網(wǎng)。TCP/IP協(xié)議組件中不同層次的協(xié)議TCP和UDP是兩種最為著名的運(yùn)輸層協(xié)議,二者都使用IP作為網(wǎng)絡(luò)層協(xié)議。雖然TCP使用不可靠的IP服務(wù),但它卻提供一種可靠的運(yùn)輸層服務(wù);UDP為應(yīng)用程序發(fā)送和接收數(shù)據(jù)報。一個數(shù)據(jù)報是指從發(fā)送方傳輸?shù)浇邮辗降囊粋€信息單元(例如,發(fā)送方指定的一定字節(jié)數(shù)的信息)。但是與TCP不同的是,UDP是不可靠的,它不能保證數(shù)據(jù)報能安全無誤地到達(dá)最終目的。SNMP(簡單網(wǎng)絡(luò)管理協(xié)議)也使用了UDP協(xié)議,但是它還要處理許多其他的協(xié)議,IP是網(wǎng)絡(luò)層上的主要協(xié)議,同時被TCP和UDP使用。TCP和UDP的每組數(shù)據(jù)都通過端系統(tǒng)和每個中間路由器中的IP層在互連網(wǎng)中進(jìn)行傳輸。直接訪問IP的應(yīng)用程序是很少見的,但也是可能的。(一些較老的路由選擇協(xié)議就是以這種方式來實現(xiàn)的。當(dāng)然新的運(yùn)輸層協(xié)議也有可能試用這種方式。)ICMP是IP協(xié)議的附屬協(xié)議。IP層用它來與其他主機(jī)或路由器交換錯誤報文和其他重要信息。盡管ICMP主要被IP使用,但應(yīng)用程序也有可能訪問它。我們將分析兩個流行的診斷工具,Ping和Traceroute,它們都使用了ICMP。IGMP是Internet組管理協(xié)議。它用來把一個UDP數(shù)據(jù)報多播到多個主機(jī)。ARP(地址解析協(xié)議)和RARP(逆地址解析協(xié)議)是某些網(wǎng)絡(luò)接口(如以太網(wǎng)和令牌環(huán)網(wǎng))使用的特殊協(xié)議,用來轉(zhuǎn)換IP層和網(wǎng)絡(luò)接口層使用的地址。疑難解答TCP/IP網(wǎng)絡(luò)問題通常是由計算機(jī)的TCP/IP屬性中三個主要條目的錯誤配置導(dǎo)致的。了解TCP/IP配置中的錯誤如何影響網(wǎng)絡(luò)操作后,您可以解決許多常見TCP/IP問題。錯誤的子網(wǎng)掩碼:如果網(wǎng)絡(luò)將默認(rèn)掩碼外的其他子網(wǎng)掩碼用于其地址類,而客戶端仍使用該地址類的默認(rèn)子網(wǎng)掩碼進(jìn)行配置,則可以與遠(yuǎn)程網(wǎng)絡(luò)進(jìn)行通信但無法與某些附近網(wǎng)絡(luò)進(jìn)行通信。例如,如果創(chuàng)建四個子網(wǎng)(例如在子網(wǎng)配置示例中),但是在TCP/IP配置中使用錯誤的子網(wǎng)掩碼,則主機(jī)將無法確定某些計算機(jī)是否在與它們自己的子網(wǎng)不同的子網(wǎng)中。當(dāng)發(fā)生此情況時,發(fā)送到作為相同C類地址一部分的不同物理網(wǎng)絡(luò)中的主機(jī)的數(shù)據(jù)包將不會發(fā)送到默認(rèn)網(wǎng)關(guān)來進(jìn)行傳送。此問題的常見癥狀是計算機(jī)可以與其本地網(wǎng)絡(luò)中的主機(jī)以及所有遠(yuǎn)程網(wǎng)絡(luò)進(jìn)行通信,但無法與位置在附近并具有相同的A、B或C類地址的網(wǎng)絡(luò)進(jìn)行通信。要解決此問題,只需在該主機(jī)的TCP/IP配置中輸入正確的子網(wǎng)掩碼。錯誤的IP址:如果將那些IP地址在本地網(wǎng)絡(luò)的不同子網(wǎng)中的計算機(jī)放在一起,則它們無法進(jìn)行通信。它們會嘗試通過路由器相互發(fā)送數(shù)據(jù)包,而該路由器卻無法正確轉(zhuǎn)發(fā)這些數(shù)據(jù)包。此問題的癥狀是計算機(jī)可以與遠(yuǎn)程網(wǎng)絡(luò)中的主機(jī)進(jìn)行通信,但是無法與其本地網(wǎng)絡(luò)中的某些或全部計算機(jī)通信。要解決此問題,請確保同一物理網(wǎng)絡(luò)中的所有計算機(jī)具有同一IP子網(wǎng)中的IP地址。如果一個網(wǎng)段中的IP地址已用完,還可使用一些解決方案進(jìn)行處理,但已超出本文范圍。錯誤的默認(rèn)網(wǎng)關(guān):使用錯誤的默認(rèn)網(wǎng)關(guān)配置的計算機(jī)能夠與其自己網(wǎng)段中的主機(jī)進(jìn)行通信,但是無法與某些或全部遠(yuǎn)程網(wǎng)絡(luò)中的主機(jī)進(jìn)行通信。如果一個物理網(wǎng)絡(luò)有多個路由器,且將錯誤的路由器配置為默認(rèn)網(wǎng)關(guān),則主機(jī)能夠與某些遠(yuǎn)程網(wǎng)絡(luò)進(jìn)行通信,但是無法與其他遠(yuǎn)程網(wǎng)絡(luò)進(jìn)行通信。如果組織中有一個路由器連接到內(nèi)部TCP/IP網(wǎng)絡(luò),另一個路由器連接到Internet,則此問題很常見。參考TCP/IP中的兩個常用參考是:RichardStevens,AddisonWesley.TCP/IPIllustrated,Volume1:TheProtocols[M].1994.DouglasE.Comer,PrenticeHall.InternetworkingwithTCP/IP,Volume1:Principles,Protocols,andArchitecture[M].1995.極力建議負(fù)責(zé)TCP/IP網(wǎng)絡(luò)的系統(tǒng)管理員至少使用其中一個參考。術(shù)語表廣播地址--主機(jī)部分全部為一的IP地址。主機(jī)--TCP/IP網(wǎng)絡(luò)中的計算機(jī)或其他設(shè)備。Internet--連接在一起并共享公共范圍的IP地址的全球網(wǎng)絡(luò)集合。InterNIC--負(fù)責(zé)管理Internet中的IP地址的機(jī)構(gòu)。IP--用于在TCP/IP網(wǎng)絡(luò)或Internet上發(fā)送網(wǎng)絡(luò)數(shù)據(jù)包的網(wǎng)絡(luò)協(xié)議。IP地址--TCP/IP網(wǎng)絡(luò)或Internet主機(jī)的唯一32位地址。網(wǎng)絡(luò)--在本文中,“網(wǎng)絡(luò)”一詞有兩種含義。一種含義是指單一物理網(wǎng)段上的計算機(jī)組,另一種含義是指系統(tǒng)管理員分配的IP網(wǎng)絡(luò)地址范圍。網(wǎng)絡(luò)地址--主機(jī)部分全部為零的IP地址。八位組--一個8位數(shù)字,4個八位組構(gòu)成一個32位IP地址。它們的范圍是00000000-11111111,對應(yīng)于十進(jìn)制值0-255。數(shù)據(jù)包--通過TCP/IP網(wǎng)絡(luò)或廣域網(wǎng)傳輸?shù)臄?shù)據(jù)單位。RFC(RequestforComment,征求意見文件)--用于定義Internet標(biāo)準(zhǔn)的文檔。路由器--在不同IP網(wǎng)絡(luò)間傳輸網(wǎng)絡(luò)通信的設(shè)備。子網(wǎng)掩碼--一個32位數(shù)字,用于區(qū)分IP地址的網(wǎng)絡(luò)部分和主機(jī)部分。子網(wǎng)--通過將較大的網(wǎng)絡(luò)分成相等的部分而創(chuàng)建的較小網(wǎng)絡(luò)。TCP/IP--通常在Internet和大型網(wǎng)絡(luò)中廣泛使用的協(xié)議、標(biāo)準(zhǔn)和實用工具的集合。廣域網(wǎng)(WAN)--大型網(wǎng)絡(luò),它是路由器分隔的較小網(wǎng)絡(luò)的集合。例如,Internet就是一個非常大的廣域網(wǎng)。附件:2.外文原文TCP/IPINTRODUCTIONWhenyouconfiguretheTCP/IPprotocolonaMicrosoftWindowscomputer,anIPaddress,subnetmask,andusuallyadefaultgatewayarerequiredintheTCP/IPconfigurationsettings.ToconfigureTCP/IPcorrectly,itisnecessarytounderstandhowTCP/IPnetworksareaddressedanddividedintonetworksandsubnetworks.ThisarticleisintendedasageneralintroductiontotheconceptsofIPnetworksandsubnetting.Aglossaryisincludedattheendofarticle.MOREINFORMATIONThesuccessofTCP/IPasthenetworkprotocoloftheInternetislargelybecauseofitsabilitytoconnecttogethernetworksofdifferentsizesandsystemsofdifferenttypes.Thesenetworksarearbitrarilydefinedintothreemainclasses(alongwithafewothers)thathavepredefinedsizes,eachofwhichcanbedividedintosmallersubnetworksbysystemadministrators.AsubnetmaskisusedtodivideanIPaddressintotwoparts.Onepartidentifiesthehost(computer),theotherpartidentifiesthenetworktowhichitbelongs.TobetterunderstandhowIPaddressesandsubnetmaskswork,lookatanIP(InternetProtocol)addressandseehowitisorganized.TCPservicesAlthoughtheTCPandUDPareusingthesamenetworklayer(IP),TCPhasprovidedtotheapplicationlayerandUDPcompletelydifferentservices.TCPprovidesaconnection-oriented,reliablestreamofbytesservices.FortheuseofTCPconnectionmeansthattwooftheapplication(usuallyaclientandaserver)inthemutualexchangeofdatamustbebeforetheestablishmentofaTCPconnection.Thisprocessisverysimilarwiththecall,firstdial-upring,waitingfortheothersidepicksaid,"Hey,"Whoisthatbefore.InaTCPconnection,onlytwopartiestocommunicatewitheachother.BroadcastandMulticastcannotbeusedforTCP.TCPadoptionofthefollowingwaystoprovidereliability:ApplicationdataBeifengechengsuitedtoTCPthatsentmostoftheblock.ThisiscompletelydifferentfromUDP,theapplicationofthedataonthelengthwillremainthesame.TCPfromtheinformationpassedtotheIPunitknownasthetextofthereportorparagraph(segment)TCPonhowtodeterminethelengthofthetext.WhentheTCPsendaparagraphlater,itstartedatimer,waitfortheendpurposeofthisnewspaperthatonreceiptofthetext.Ifnotreceivedaconfirmationintime,willbere-issuedthetextofthereport.InChapter21wewillunderstandTCPprotocolintheovertimeandadaptivere-strategy.WhentheTCPreceivedfromtheothersideoftheTCPconnectiondata,itwillsendaconfirmation.Thisconfirmationisnotsentimmediately,usuallyafractionofasecondwillbepostponed.TCPwillmaintainitsfirstdataandthetestingand.Thisisanend-to-endtestingandtodetectthetransmissionofdatainthecourseofanychanges.Ifyoureceivethetestoftheerrorsand,TCPwillbediscardedthismessage,anddonotacknowledgereceiptofthismessage(hopethatboththeoriginatoroftheovertime).SincetheTCPpacketofdataasreportedtotransmitIP,andIPdataonthedisordermaybereached,TCPpacketofthedisordermayalsobereached.Ifnecessary,TCPwillreceivethedatare-order,willreceivethedatatothecorrectsequencetotheapplicationlayer.SincetheIPdatawillbereportedduplication,TCPthereceivingendmustbedisposedofduplicationofdata.
TCPalsoprovidesflowcontrol.TCPconnectionofeachsidehaveafixed-sizebufferspace.TCPreceiverallowsonlytheothersideofthebufferzonetosendthereceivertoacceptthedata.Thiswillpreventtherapidhostaresultofslowerhostabufferoverflow.TwoapplicationsthroughTCPconnectionexchangeof8bitbytesastreamofbytes.TCPisnotinsertedintherecord-byteidentifier.Weseethisasbyte-service(bytestreamservice).Iftheapplicationisoneofthefirst10-byte,20-byte,50byteslonger,connectedtotheotherpartywillnotbeabletounderstandeachsidesentanumberofbytes.Receivercanreceivefourtimesthis80-byte,eachreceiving20bytes.WillbebanishedtotheendbyteTCPconnection,thesamestreamofbyteswillappearintheotherendofTCPconnection.Inaddition,TCPbyteflowofthecontentnottomakeanyexplanation.TCPdonotknowbytesofdatatransmissionflowisbinarydata,orASCIIcharacters,EBCDICcharacterorothertypesofdata.TheflowofbytesexplainedbytheTCPconnectionthetwosidestoexplaintheapplicationlayer.ThisstreamofbytesoftheUnixoperatingsystemandthehandlingofthedocument'sapproachisverysimilar.Unixkernelofanapplicationreadorwritethecontentnottomakeanyexplanation,buttotheapplicationprocedures.ThecoreofUnix,itcannotdistinguishbetweenabinaryfilewithatextfile.TCPistheInternetinTransportLayerprotocol,shookhandswiththeuseofthreeagreementsestablishaconnection.WhentheinitiativetoconnectaSYNrequestandwaitfortheothersidetoanswerSYN,ACK.Thisconnectionmethodcanpreventawrongconnection,TCPflowcontroltheuseoftheagreementisthesizeofvariableslidingwindowprotocol.Thefirsthandshake:establishaconnection,theclientsentSYNpacket(SEQ=x)totheserverandaccessSYN_SENDstate,waitingfortheservertoconfirm.Secondhandshake:ServerreceivedSYNpacket,customersmustconfirmtheSYN(ACK=x+1),whileitsownpackagealsosendaSYN(SEQ=y),thatis,SYN+ACKpacket,thenentertheserverSYN_RECVstate.Thirdhandshake:clientserverreceivedtheSYN+ACKpacket,sendconfirmationtotheserverpackageACK(ACK=y+1),thispackagesentcompleted,theclientandserver-Establishedstate,completethethreeshookhands.IPaddresses:NetworksandhostsAnIPaddressisa32-bitnumberthatuniquelyidentifiesahost(computerorotherdevice,suchasaprinterorrouter)onaTCP/IPnetwork.IPaddressesarenormallyexpressedindotted-decimalformat,withfournumbersseparatedbyperiods,suchas32.Tounderstandhowsubnetmasksareusedtodistinguishbetweenhosts,networks,andsubnetworks,examineanIPaddressinbinarynotation.Forexample,thedotted-decimalIPaddress32is(inbinarynotation)the32bitnumber110000000101000111101110000100.Thisnumbermaybehardtomakesenseof,sodivideitintofourpartsofeightbinarydigits.Theseeightbitsectionsareknownasoctets.TheexampleIPaddress,then,becomes11000000.10101000.01111011.10000100.Thisnumberonlymakesalittlemoresense,soformostuses,convertthebinaryaddressintodotted-decimalformat(32).Thedecimalnumbersseparatedbyperiodsaretheoctetsconvertedfrombinarytodecimalnotation.ForaTCP/IPwideareanetwork(WAN)toworkefficientlyasacollectionofnetworks,theroutersthatpasspacketsofdatabetweennetworksdonotknowtheexactlocationofahostforwhichapacketofinformationisdestined.Routersonlyknowwhatnetworkthehostisamemberofanduseinformationstoredintheirroutetabletodeterminehowtogetthepackettothedestinationhost'snetwork.Afterthepacketisdeliveredtothedestination'snetwork,thepacketisdeliveredtotheappropriatehost.Forthisprocesstowork,anIPaddresshastwoparts.ThefirstpartofanIPaddressisusedasanetworkaddress,thelastpartasahostaddress.Ifyoutaketheexample32anddivideitintothesetwopartsyougetthefollowing:192.168.123.Network.132Host -or--networkaddress.32-hostaddress.SubnetmaskTheseconditem,whichisrequiredforTCP/IPtowork,isthesubnetmask.ThesubnetmaskisusedbytheTCP/IPprotocoltodeterminewhetherahostisonthelocalsubnetoronaremotenetwork.InTCP/IP,thepartsoftheIPaddressthatareusedasthenetworkandhostaddressesarenotfixed,sothenetworkandhostaddressesabovecannotbedeterminedunlessyouhavemoreinformation.Thisinformationissuppliedinanother32-bitnumbercalledasubnetmask.Inthisexample,thesubnetmaskis.Itisnotobviouswhatthisnumbermeansunlessyouknowthat255inbinarynotationequals11111111;so,thesubnetmaskis:11111111.11111111.11111111.0000000 LininguptheIPaddressandthesubnetmasktogether,thenetworkandhostportionsoftheaddresscanbeseparated:11000000.10101000.01111011.10000100--IPaddress(32)11111111.11111111.11111111.00000000--Subnetmask() Thefirst24bits(thenumberofonesinthesubnetmask)areidentifiedasthenetworkaddress,withthelast8bits(thenumberofremainingzerosinthesubnetmask)identifiedasthehostaddress.Thisgivesyouthefollowing:11000000.10101000.01111011.00000000--Networkaddress()00000000.00000000.00000000.10000100--Hostaddress(000.000.000.132)Sonowyouknow,forthisexampleusingasubnetmask,thatthenetworkIDis,andthehostaddressis32.Whenapacketarrivesonthesubnet(fromthelocalsubnetoraremotenetwork),andithasadestinationaddressof32,yourcomputerwillreceiveitfromthenetworkandprocessit.Almostalldecimalsubnetmasksconverttobinarynumbersthatareallonesontheleftandallzerosontheright.Someothercommonsubnetmasksare:DecimalBinary921111111.11111111.1111111.11000000241111111.11111111.1111111.11100000 InternetRFC1878(availablefrom)describesthevalidsubnetsandsubnetmasksthatcanbeusedonTCP/IPnetworks.NetworkclassesInternetaddressesareallocatedbytheInterNIC(),theorganizationthatadministerstheInternet.TheseIPaddressesaredividedintoclasses.ThemostcommonoftheseareclassesA,B,andC.ClassesDandEexist,butarenotgenerallyusedbyendusers.Eachoftheaddressclasseshasadifferentdefaultsubnetmask.YoucanidentifytheclassofanIPaddressbylookingatitsfirstoctet.FollowingaretherangesofClassA,B,andCInternetaddresses,eachwithanexampleaddress:ClassAnetworksuseadefaultsubnetmaskofandhave0-127astheirfirstoctet.Theaddress1isaclassAaddress.Itsfirstoctetis10,whichisbetween1and126,inclusive.ClassBnetworksuseadefaultsubnetmaskofandhave128-191astheirfirstoctet.Theaddress3isaclassBaddress.Itsfirstoctetis172,whichisbetween128and191,inclusive.ClassCnetworksuseadefaultsubnetmaskofandhave192-223astheirfirstoctet.Theaddress32isaclassCaddress.Itsfirstoctetis192,whichisbetween192and223,inclusive.Insomescenarios,thedefaultsubnetmaskvaluesdonotfittheneedsoftheorganization,becauseofthephysicaltopologyofthenetwork,orbecausethenumbersofnetworks(orhosts)donotfitwithinthedefaultsubnetmaskrestrictions.Thenextsectionexplainshownetworkscanbedividedusingsubnetmasks.SubnettingClassA,B,orCTCP/IPnetworkcanbefurtherdivided,orsubnetted,byasystemadministrator.ThisbecomesnecessaryasyoureconcilethelogicaladdressschemeoftheInternet(theabstractworldofIPaddressesandsubnets)withthephysicalnetworksinusebytherealworld.AsystemadministratorwhoisallocatedablockofIPaddressesmaybeadministeringnetworksthatarenotorganizedinawaythateasilyfitstheseaddresses.Forexample,youhaveawideareanetworkwith150hostsonthreenetworks(indifferentcities)thatareconnectedbyaTCP/IProuter.Eachofthesethreenetworkshas50hosts.YouareallocatedtheclassCnetwork.(Forillustration,thisaddressisactuallyfromarangethatisnotallocatedontheInternet.)Thismeansthatyoucanusetheaddressesto54foryour150hosts.Twoaddressesthatcannotbeusedinyourexampleareand55becausebinaryaddresseswithahostportionofallonesandallzerosareinvalid.Thezeroaddressisinvalidbecauseitisusedtospecifyanetworkwithoutspecifyingahost.The255address(inbinarynotation,ahostaddressofallones)isusedtobroadcastamessagetoeveryhostonanetwork.Justrememberthatthefirstandlastaddressinanynetworkorsubnetcannotbeassignedtoanyindividualhost.YoushouldnowbeabletogiveIPaddressesto254hosts.Thisworksfineifall150computersareonasinglenetwork.However,your150computersareonthreeseparatephysicalnetworks.Insteadofrequestingmoreaddressblocksforeachnetwork,youdivideyournetworkintosubnetsthatenableyoutouseoneblockofaddressesonmultiplephysicalnetworks.Inthiscase,youdivideyournetworkintofoursubnetsbyusingasubnetmaskthatmakesthenetworkaddresslargerandthepossiblerangeofhostaddressessmaller.Inotherwords,youare'borrowing'someofthebitsusuallyusedforthehostaddress,andusingthemforthenetworkportionoftheaddress.Thesubnetmask92givesyoufournetworksof62hostseach.Thisworksbecauseinbinarynotation,92isthesameas1111111.11111111.1111111.11000000.Thefirsttwodigitsofthelastoctetbecomenetworkaddresses,soyougettheadditionalnetworks00000000(0),01000000(64),10000000(128)and11000000(192).(Someadministratorswillonlyusetwoofthesubnetworksusing92asasubnetmask.Formoreinformationonthistopic,seeRFC1878.)Inthesefournetworks,thelast6binarydigitscanbeusedforhostaddresses.Usingasubnetmaskof92,yournetworkthenbecomesthefournetworks,4,28and92.Thesefournetworkswouldhaveasvalidhostaddresses:-62,5-126,29-190,93-254Remember,again,thatbinaryhostaddresseswithallonesorallzerosareinvalid,soyoucannotuseaddresseswiththelastoctetof0,63,64,127,128,191,192,or255.Youcanseehowthisworksbylookingattwohostaddresses,1and33.IfyouusedthedefaultClassCsubnetmaskof,bothaddressesareonthenetwork.However,ifyouusethesubnetmaskof92,theyareondifferentnetworks;1isonthe4network,33isonthe28network.DefaultgatewaysIfaTCP/IPcomputerneedstocommunicatewithahostonanothernetwork,itwillusuallycommunicatethroughadevicecalledarouter.InTCP/IPterms,arouterthatisspecifiedonahost,whichlinksthehost'ssubnettoothernetworks,iscalledadefaultgateway.ThissectionexplainshowTCP/IPdetermineswhetherornottosendpacketstoitsdefaultgatewaytoreachanothercomputerordeviceonthenetwork.WhenahostattemptstocommunicatewithanotherdeviceusingTCP/IP,itperformsacomparisonprocessusingthedefinedsubnetmaskandthedestinationIPaddressversusthesubnetmaskanditsownIPaddress.Theresultofthiscomparisontellsthecomputerwhetherthedestinationisalocalhostoraremotehost.Iftheresultofthisprocessdeterminesthedestinationtobealocalhost,thenthecomputerwillsimplysendthepacketonthelocalsubnet.Iftheresultofthecomparisondeterminesthedestinationtobearemotehost,thenthecomputerwillforwardthepackettothedefaultgatewaydefinedinitsTCP/IPproperties.Itisthentheresponsibilityoftheroutertoforwardthepackettothecorrectsubnet.TCP/IPprotocolcomponentsindifferentlevelsTCPandUDParethetwomostfamoustransportlayerprotocol,bothofwhichuseIPasanetworklayerprotocol.AlthoughtheuseofTCPreliableIPservices,itprovidesareliabletransportlayerservices;UDPforapplicationstosendandreceivedata.Reportedlyreferstoadatasentfromthetransmissiontoreceivingaunitofinformation(forexample,senttothedesignatedacertainnumberofbytesofinformation).ButthedifferenceisthatTCP,UDPisnotreliable,itcannotguaranteethesafetydatawascorrecttoreachtheultimategoal.SNMP(SNMP)alsousedtheUDPprotocol,butitwouldalsoliketoaddressmanyoftheotheragreement,IPnetworklayeristhemainagreement,whiletheuseofTCPandUDP.TCPandUDPdatathroughtheendofeachsystemandeachrouterinthemiddleoftheIPintheInternetinthetransfer.DirectaccesstoIPapplicationsisrare,butitisalsopossible.(Someolderroutingagreementisinthiswaytoachieveit.Ofcourse,newtransportlayerprotocolmayalsotrythisapproach.).ICMPisasubsidiaryofIPprotocolagreement.IPlayeranduseittootherhostorroutertoexchangethewrongmessageandotherimportantinformation.AlthoughICMPmainlyIP,butapplicationsmayalsoaccessit.Wewillanalysethetwopopulardiagnostictool,PingandTraceroute,theyallusetheICMP.IGMPistheInternetGroupManagementProtocol.ItusedtoaUDPdataonmulticasttomultiplehosts.ARP(ARP)andRARP(InverseARP)isacertainnetworkinterface(suchasEthernetandTokenRing)theuseofthespecialprotocolthatisusedtoconvertIPnetworkinterfacelayerandtheuseoftheaddress.TroubleshootingTCP/IPnetworkproblemsareoftencausedbyincorrectconfigurationofthethreemainentriesinacomputer'sTCP/IPproperties.ByunderstandinghowerrorsinTCP/IPconfigurationaffectnetworkoperations,youcansolvemanycommonTCP/IPproblems.IncorrectSubnetMask:Ifanetworkusesasubnetmaskotherthanthedefaultmaskforitsaddressclass,andaclientisstillconfiguredwiththedefaultsubnetmaskfortheaddressclass,communicationwillfailtosomenearbynetworksbutnottodistantones.Asanexample,ifyoucreatefoursubnets(suchasinthesubnettingexample)butusetheincorrectsubnetmaskofinyourTCP/IPconfiguration,hostswillnotbeabletodeterminethatsomecomputersareondifferentsubnetsthantheirown.Whenthishappens,packetsdestinedforhostsondifferentphysicalnetworksthatarepartofthesameClassCaddresswillnotbesenttoadefaultgatewayfordelivery.AcommonsymptomofthisiswhenacomputercancommunicatewithhoststhatareonitslocalnetworkandcantalktoallremotenetworksexceptthosethatarenearbyandhavethesameclassA,B,orCaddress.Tofixthisproblem,justenterthecorrectsubnetmaskintheTCP/IPconfigurationforthathost.IncorrectIPAddress:IfyouputcomputerswithIPaddressesthatshouldbeonseparatesubnetsonalocalnetworkwitheachother,theywillnotbeabletocommunicate.Theywilltrytosendpacketstoeachotherthrougharouterthatwillnotbeabletoforwardthemcorrectly.Asymptomofthisproblemisacomputerthatcantalktohostsonremotenetw
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2025版企業(yè)設(shè)備更新改造貸款合同樣本3篇
- 二零二五年度市政綠化帶維護(hù)承包合同4篇
- 2025版土石方居間服務(wù)與施工質(zhì)量協(xié)議3篇
- 2025年茅勤離婚協(xié)議書婚姻債務(wù)清償標(biāo)準(zhǔn)范本
- 2025年度私人車輛轉(zhuǎn)讓與年度租賃服務(wù)及維修合同
- 2025年度個人藝術(shù)品拍賣居間服務(wù)協(xié)議4篇
- 二手貨車買賣雙方權(quán)責(zé)明確不過戶協(xié)議版B版
- 二零二五年度印刷材料環(huán)保認(rèn)證合同3篇
- 哈爾濱市2025年度文化娛樂行業(yè)勞動合同規(guī)范3篇
- 二零二五年度充電樁安裝工程安全協(xié)議4篇
- 2024年中國醫(yī)藥研發(fā)藍(lán)皮書
- 廣東省佛山市 2023-2024學(xué)年五年級(上)期末數(shù)學(xué)試卷
- 臺兒莊介紹課件
- 疥瘡病人的護(hù)理
- 人工智能算法與實踐-第16章 LSTM神經(jīng)網(wǎng)絡(luò)
- 17個崗位安全操作規(guī)程手冊
- 2025年山東省濟(jì)南市第一中學(xué)高三下學(xué)期期末統(tǒng)一考試物理試題含解析
- 中學(xué)安全辦2024-2025學(xué)年工作計劃
- 網(wǎng)絡(luò)安全保障服務(wù)方案(網(wǎng)絡(luò)安全運(yùn)維、重保服務(wù))
- 現(xiàn)代科學(xué)技術(shù)概論智慧樹知到期末考試答案章節(jié)答案2024年成都師范學(xué)院
- 軟件模塊化設(shè)計與開發(fā)標(biāo)準(zhǔn)與規(guī)范
評論
0/150
提交評論