Sunum yükleniyor. Lütfen bekleyiniz

Sunum yükleniyor. Lütfen bekleyiniz

© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints.

Benzer bir sunumlar


... konulu sunumlar: "© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints."— Sunum transkripti:

1 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints By Lami Kaya, LKaya@ieee.org

2 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.2 Chapter 22 Datagram Forwarding

3 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.3 Topics Covered 22.1 Introduction 22.2 Connectionless Service 22.3 Virtual Packets 22.4 The IP Datagram 22.5 The IP Datagram Header Format 22.6 Forwarding An IP Datagram 22.7 Network Prefix Extraction And Datagram Forwarding 22.8 Longest Prefix Match 22.9 Destination Address And Next-Hop Address 22.10 Best-Effort Delivery

4 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.4 Topics Covered 22.11 IP Encapsulation 22.12 Transmission Across An Internet 22.13 MTU And Datagram Fragmentation 22.14 Reassembly Of A Datagram From Fragments 22.15 Collecting The Fragments Of A Datagram 22.16 The Consequence Of Fragment Loss 22.17 Fragmenting A Fragment

5 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.5 22.1 Introduction This chapter –discusses the fundamental communication service in the Internet –describes the format of packets that are sent across the Internet –discusses the key concepts of datagram encapsulation, forwarding, and fragmentation and reassembly

6 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.6 22.2 Connectionless Service In some application, programs remain unaware of the underlying physical networks –they can send/receive data without knowing the details of the LAN to which a computer connects the remote network to which the destination connects What services that will be offered by a network? – connection-oriented service – connectionless service –or a combination of both TCP/IP include protocols for both –An unreliable connectionless delivery service –A reliable connection-oriented service that uses the underlying connectionless service The design forms the basis for all Internet communication

7 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.7 22.2 Connectionless Service Bazı Uygulamalarda, programlarda alttaki fiziksel ağlardan haberdar değildirler –Detayları bilmeden veri gönderip / alırlar the LAN to which a computer connects the remote network to which the destination connects Ağ tarafından ne servisler sağlanıyor? –Bağlantı-tabanlı servis (connection-oriented) – Bağlantısız servis (connectionless ) –Yada ikisinin kombinasyonu TCP/IP protokollerinde her ikisinide içermektedir –Güvenilirli olmayan bağlatısız iletim servisi (unreliable connectionless) –Güvenilirli bağlantı-tabanlı servis (reliable connection-oriented ) that uses the underlying connectionless service İnternet iletişimi için tasarlanan formlar

8 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.8 22.3 Virtual Packets In connectionless each packet travels independently –It contains information that identifies the intended recipient How does a packet pass across the Internet? –A host creates a packet places the destination address in the packet header and then sends the packet to a nearby router –A router receives a packet uses the destination address to select the next router on the path and then forwards the packet –Eventually, the packet reaches a router that can deliver the packet to its final destination

9 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.9 22.3 Yapay Paketler Bağlatısız her paket birbirinden bağımsız bir şekilde hareket eder –Planlanan alıcıyı tanımlayan bilgiyi içerir Internet üzerinden paket nasıl gider? –A host creates a packet places the destination address in the packet header and then sends the packet to a nearby router –A router receives a packet uses the destination address to select the next router on the path and then forwards the packet –Sonunda, paket router’ a ulaşır ve enson gideceği yere iletilir

10 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.10 22.3 Virtual Packets What format is used for an Internet packet? –Internet consists of heterogeneous networks that use incompatible frame formats it cannot adopt any of the hardware frame formats A router cannot simply reformat the frame header –because the two networks may use incompatible addressing To overcome heterogeneity –IP defines a packet format that is independent of the hardware –The result is a universal, virtual packet that can be transferred across the underlying hardware intact –As the term virtual implies The Internet packet format is not tied directly to any hardware The underlying hardware does not understand or recognize an Internet packet –As the term universal implies Each host or router in the Internet contains protocol software that recognizes Internet packets

11 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.11 22.3 Yapay Paketler Internet paketleri için ne formatı kullanılır? –İnternet heterojen ağlar içerir that use incompatible frame formats it cannot adopt any of the hardware frame formats Router frame’başlığını yeniden tanımlayamaz –Çünkü iki ağ birbiri ile uyuşmayan adres çeşitleri kullanabilir Heterojenliğin üstesinden gelebilmek için –IP paket formatı tanımlanmıştır ve donanımdan bağımsızdır –Sonuç evrenseldir, yapay paketler (virtual packet ) Kendi altındaki bozulmamış donanım üzerinden transfer edilir –Yapay kelimesi şunları vurgular İnternet paketi formatı donanım üzerine direkt olarak bağlanmamıştır Alttaki donanım internet paketinin formatını tanımaz –Evrensel kelimesi şunu vurgular Internetteki her host yada router internet paketlerini tanıyacak protokol yazılımı içerir

12 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.12 22.4 The IP Datagram TCP/IP use the name IP datagram to refer to a packet Figure 22.1 illustrates an IP datagram format –Each datagram consists of a header followed by data area (payload) The amount of data carried in a datagram is not fixed The size of a datagram is determined by the application that sends data. A datagram can contain as little as a single octet of data or at most 64K

13 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.13 22.4 The IP Datagram TCP/IP IP datagram ismini paket’e vurgulamak için kullanılır Şekil 22.1 IP datagram formatı gösterir –Her datagram bir başlık (header) ve onu takip eden veri (payload) alanının içerir The amount of data carried in a datagram is not fixed The size of a datagram is determined by the application that sends data. A datagram can contain as little as a single octet of data or at most 64K

14 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.14 22.5 The IP Datagram Header Format What does a datagram header contain? –It contains information used to forward the datagram A datagram heads contains information, such as: –the address of the source (the original sender) –the address of the destination (the ultimate recipient) –and a field that specifies the type of data being carried in the payload Each address in the header is an IP address –MAC addresses for the sender and recipient do not appear Each field in an IP datagram header has a fixed size –which makes header processing efficient Figure 22.2 shows the fields of an IP datagram header

15 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.15 22.5 IP Datagram Başlık Formatı Datafram başlığı ne içerir? –Datagram’ı iletmek için gerekli olan bilgiyi içerir Datagram başlıpı şu bilgileri içerir –Kaynağın adresi (orjinal gönderici) –Hedef’in adresi (alıcı) –Ve ve payload olarak taşınacak verinin tipini tanımlar Başlık içerisindeki her adres, IP adresidir –Alıcı ve gönderici MAC adresleri gözükmez IP datagram içerisindeki her alan sabit büyüklüğe sahiptir –Başlık işlemeyi hızlı ve etkin hale getirir Şekil 22.2 IP datagram başlığındaki alanları gösterir

16 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.16 22.5 IP Datagram Başlık Formatı

17 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.17 22.5 The IP Datagram Header Format VERS –Each datagram begins with a 4-bit protocol version number (the figure shows a version 4 header) H.LEN – 4-bit header specifies the number of 32-bit quantities in the header –If no options are present, the value is 5 SERVICE TYPE – 8-bit field that carries a class of service for the datagram (seldom used in practice) –Chapter 28 explains the DiffServ interpretation of the service type field TOTAL LENGTH – 16-bit integer that specifies the total number of bytes in the datagram (including both the header and the data)

18 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.18 22.5 IP Datagram Başlık Formatı VERS –Her datagram4-bitlik protokol versiyon numarası ile başlar ( şekil versiyon 4’ü gösteriyor) H.LEN –4-bit başlığı 32-bit başlığın büyüklüğünü tanımlar –Eğer herhangi bir opsiyon yoksa, değer 5 tir SERVICE TYPE –8-bitlik alan taşımış olduğu datagram’ın servis sınıfını tanımlar (pratikte çok az kullanılır) –Bölüm 28, DiffServ açıklandığı zaman kendisinin bu alanı kullandığını göreceğiz TOTAL LENGTH –16 bitlik bir tamsayıdır be datagram içerisindeki toplan byte sayısını içerir –(başlık ve verinin toplamını içerir)

19 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.19 22.5 The IP Datagram Header Format IDENTIFICATION – 16-bit number (usually sequential) assigned to the datagram used to gather all fragments for reassembly the datagram FLAGS – 3-bit field with individual bits specifying whether the datagram is a fragment If so, then whether the fragment corresponds to the rightmost piece of the original datagram FRAGMENT OFFSET – 13-bit field that specifies where in the original datagram the data in this fragment belongs –the value of the field is multiplied by 8 to obtain an offset

20 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.20 22.5 IP Datagram Başlık Formatı IDENTIFICATION –16 bitlik sayı datagram’a atanır used to gather all fragments for reassembly the datagram FLAGS –3 bitlik alan bağımsız bitler ile gatagram’ın parçalanıp parçalanmadığını içerir If so, then whether the fragment corresponds to the rightmost piece of the original datagram FRAGMENT OFFSET –13 bitlik alan parçalanmış paketin orjinal pakette nereye denk düştüğünü içerir –Buradaki değeri elde etmek için offset değeri ile 8’in çarpılması gerekir

21 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.21 22.5 IP Datagram Başlık Formatı TIME TO LIVE –8 bitlik tamsayı değeri orjinal gönderici tarafından atanan değerdir –Her routerda değeri bir azaltılır –Eğer değeri sıfır’a ulaştığı zaman (orjinal göndericiye hata mesajı gönderilir) TYPE –8 bitlik alan payload’un tipini tanımlar HEADER CHECKSUM –Header alanının ones-complement değerini içeren 16 bitlik bir değerdir –8.1 deki algoritma ile hesaplanır SOURCE IP ADDRESS –Orjinal göndericinin 32 bitlik internet adresini içerir –(aradaki routerların adresleri header içerisinde bulunmaz)

22 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.22 22.5 The IP Datagram Header Format DESTINATION IP ADDRESS –The 32-bit Internet address of the ultimate destination –The addresses of intermediate routers do not appear in the header IP OPTIONS –Optional header fields used to control routing and datagram processing –Most datagrams do not contain any options which means the IP OPTIONS field is omitted from the header PADDING –If options do not end on a 32-bit boundary zero bits of padding are added to make the header a multiple of 32 bits

23 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.23 22.5 The IP Datagram Header Format DESTINATION IP ADDRESS –32 bitlik internet adresi alıcının adresini belirler –Aradaki routerların adresleri header içerisinde bulunmaz IP OPTIONS –Opsiyonel başlıktaki alanlar routing ve datagram işlenmesinde kullanılır –Çoğu datagramlar herhangi bir opsiyon içermemektedirler which means the IP OPTIONS field is omitted from the header PADDING –Eğer opsiyonlar 32 bit sınırında bitmiyorsa zero bits of padding are added to make the header a multiple of 32 bits

24 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.24 22.6 Forwarding An IP Datagram The Internet uses next-hop forwarding Each router along the path –receives the datagram –extracts the destination address from the header –uses the destination address to determine a next hop to which the datagram should be sent –then forwards the datagram to the next hop either the final destination or another router To make the selection of a next hop efficient, an IP router uses a forwarding table A forwarding table is initialized when the router boots –and must be updated if the topology changes or hardware fails

25 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.25 22.6 Forwarding An IP Datagram Internet bir sonraki hop’a iletme’yi kullanır Yol üzerindeki her router –Datagram’ı alır –Destination adresi header’dan çıkartır –Bir sonraki adresi belirlemek için hedef adresi kullanır to which the datagram should be sent –Datagram’ı bir sonraki router’a iletir either the final destination or another router Bir sonraki hop u faydalı bir şekilde seçebilmek için, IP router’ı iletim tablosunu(forwarding table) kullanır İletim tablosu routerlar’a önyükleme yapıldığı zaman atanır –Ve topoloji değiştiğinde yada donanım çöktüğünde yenilenmek zorundadır

26 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.26 22.6 Forwarding An IP Datagram Forwarding table contains a set of entries –each specify a destination and the next hop used to reach that destination Figure 22.3 shows an example internet and the contents of a forwarding table in one of the three routers –each router has been assigned two IP addresses one for each interface –Router R, which is connected 40.0.0.0/8 and 128.1.0.0/16 has been assigned addresses 40.0.0.8 and 128.1.0.8 –IP does not require the suffix to be the same on all interfaces But a network administrator can chose the same suffix for each interface to make it easier for humans who manage the network Each destination in the table corresponds to a network –the number of entries in a forwarding table is proportional to the number of networks in the Internet

27 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.27 22.6 Forwarding An IP Datagram İletim tablosu bir sürü girdiler içerir –Bunlardan herbiri hedef tanımlanır ve diğer hop hedef’e ulaşmak için kullanılır Şekil 22.3 internette örnek gösterir ve iletim tablosu içerikleri bu üç routerdan bir tanesidir –Her router iki IP adresi atanmıştır one for each interface –R router’ı, 40.0.0.0/8 ve 128.1.0.0/16 ile birleştirilmiştir has been assigned addresses 40.0.0.8 and 128.1.0.8 –IP bütün interfaceler için son ek’e(suffix) ihtiyaç duymaz But a network administrator can chose the same suffix for each interface to make it easier for humans who manage the network Tablo içerisindeki Her hedef bir ağdan sorumludur –İletim tablosundaki Kayıt sayıları Internetteki ağ sayıları ile bire bir doğru orantılıdır

28 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.28 22.6 Forwarding An IP Datagram

29 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.29 22.7 Network Prefix Extraction And Datagram Forwarding The process of using a forwarding table to select a next hop for a given datagram is called forwarding The mask field in a forwarding table entry is used to extract the network portion of an address during lookup When a router encounters a datagram with destination IP address D –the forwarding function must find an entry in the forwarding table that specifies a next hop for D –The software examines each entry in the table by using the mask in the entry to extract a prefix of address D –It compares the resulting prefix to the Destination field of the entry If the two are equal, the datagram will be forwarded to the Next Hop

30 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.30 22.7 Network Prefix Extraction And Datagram Forwarding İletim tablosunu kullanarak bir sonraki hop’u seçmenin kendisine forwarding(iletim) diye adlandırılır İletim tablosundaki mask alanı lookup zamanında ağ parçacığının bilgisini çıkarması için kullanılır Router hedef IP addresi D ile karşılaştığı zaman, datagram –İletim fonksiyonu, D için bir sonraki hop’u tanımlamak için, kayıt tablosunda bir kayıt bulmak zorunda –The software examines each entry in the table by using the mask in the entry to extract a prefix of address D –Sonuç prefix’i ile birlikte Kayıt’ın hedef alanını karşılaştırılır If the two are equal, the datagram will be forwarded to the Next Hop

31 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.31 22.7 Network Prefix Extraction And Datagram Forwarding The bit mask representation makes extraction efficient –the computation consists of a Boolean and between the mask and destination address, D –the computation to examine the i th entry in the table can be as: if ( (Mask[i] & D) == Destination[i] ) forward to NextHop[i] As an example –Consider a datagram destined for address 192.4.10.3 –Assume the datagram arrives at the center router, R, in Figure 22.3. –Assume the forwarding searches entries of the table in order The first entry fails since 255.0.0.0 & 192.4.10.3 ≠ 30.0.0.0 After rejecting the second and third entries in the table The routing software eventually chooses next hop 128.1.0.9 because 255.255.255.0 & 192.4.10.3 == 192.4.10.0

32 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.32 22.7 Network Prefix Extraction And Datagram Forwarding Bit mask temsili çıkarma işlemini verimli bir şekle getirir –Hesaplama Boolean içerir ve mask ile hedef adres D’nin arasındadır –the computation to examine the i th entry in the table can be as: –Hesaplamasının tabloda ki i th giriş’i incelenebilir –if ( (Mask[i] & D) == Destination[i] ) forward to NextHop[i] Örnek olarak, –Datagram’ın hedef adresinin 192.4.10.3 olduğunu farzedin –Datagram merkezi router R’ye ulaştığını farzedin, Şekil 22.3 teki gibi –Ve forwarding girişleri tabloda sıra ile aranır İlk giriş başarısızlıkla sonuçlanır 255.0.0.0 & 192.4.10.3 ≠ 30.0.0.0 Tablo içerisindeki İkinci ve üçüncü girişleri reddettikten sonra Routing yazılımı bir sonraki hop 128.1.0.9 seçer çünkü 255.255.255.0 & 192.4.10.3 == 192.4.10.0

33 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.33 22.9 Destination Address And Next-Hop Address What is the relationship between the destination address in a datagram header and the address of the next hop to which the datagram is forwarded? The DESTINATION IP ADDRESS field in a datagram contains the address of the ultimate destination –it does not change as the datagram passes through the Internet When a router receives a datagram –the router uses the ultimate destination, D –to compute the address of the next router to be sent, N The router forwards a datagram to the next hop, N –the header in the datagram retains destination address D

34 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.34 22.9 Destination Address And Next-Hop Address Datagram başlığı içerisindeki hedef adres ile bir sonraki hop’un adresi ile ne ilişkisi var? Datagram içerisindeki DESTINATION IP ADDRESS alanı son hedef adresi içerir –Internet’te geçilen yerlerde datagram değiştirilmez Datagram Router’ı ulaştığı zaman –Router tam hedef D’yi kullanır –Paketin gönderileceği gibi bir sonraki router adresini hesaplar, N Router datagram’ı bir sonraki hop’a iletir, N –Datagram’ın header’ının içerisinde hedef adres D bulunur

35 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.35 22.10 Best-Effort Delivery Term best-effort to describe the service of IP protocol IP makes a best-effort to deliver each datagram –IP does not guarantee that it will handle all problems The following problems can occur in IP protocol –Datagram duplication –Delayed or out-of-order delivery –Corruption of data –Datagram loss IP is designed to run over any type of network –network equipment can experience interference from noise Packets following one path may take longer than those following another path –this can result in out-of-order delivery

36 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.36 22.10 Best-Effort Delivery Best-Effort IP protokol servisini tanımlar IP her datagram iletimini best-effort yapar –IP bütün problemlerin üstesinden gelmez ve garanti veremez Aşağıdaki problemler IP protokolda oluşabilir –Datagram ikileme –Gecikmeli yada sırasız iletim –Verinin bozulması –Datagram kaybolması IP bütün tip ağların üzerinde çalışacak şekilde tasarlanmıştır –Ağ cihazları gürültüden oluşan karışımdan dolayı tecrübe kazanır Paketler bir yol’u takip etmesi başka bir yolu takip etmesinden daha kısa sürebilir –Buda sonuç olarak sırasız şekilde iletimi doğurur

37 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.37 22.11 IP Encapsulation Datagram fiziksel ağ üzerinde nasıl gönderilir ? (fiziksel ağ datagram’ın formatından anlamaz) –Cevap encapsulation (kapsülleme) olarak bilinir IP dagram’ı frame içerisine kapsüllendiği zaman –Bütün datagram payload alanı içerisine koyulur Ağ donanımı datagram içeren frame’lere tam olarak aynı muameleyi gösterir –Donanım payload’un içerdiği veriyi değiştirmez ŞEkil 22.4 (aşağıdaki) bu konsepti gösterir

38 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.38 22.11 IP Encapsulation How does a receiver know whether the payload of an incoming frame contains an IP datagram or other data? –Sender/receiver must agree on the value used in the frame type field –Software on the sending computer assigns the frame type field When a frame arrives with the IP value in its type field –the receiver knows that the payload area contains an IP datagram For example, the Ethernet specifies that the type field of a frame carrying an IP datagram is assigned 0x0800 Encapsulation requires the sender to supply the MAC address of the next computer – to which the datagram should be sent

39 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.39 22.11 IP Encapsulation Alıcı payload’un içerisinde IP datagram’a ait olup olmadığını nasıl anlar? –Gönderici/Alıcı, frame’in tipi alanı üzerinde anlaşmaya varmak zorundadır –Gönderen bilgisayarın Yazılım kısmı frame tipi alanına değer atar When a frame arrives with the IP value in its type field –Alıcı payload alanında IP datagram’ı barındığını bilir Mesela, Ethernet frame’i taşımış olduğu verinin hakkında bilgiyi, type of field alanında bulundurur, mesela IP datagram 0x0800 atanır Kapsülleme de, gönderici, bir sonraki adresin MAC adresine ihtiyacı vardır –Datagram gönderilmeli

40 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.40 22.12 Transmission Across An Internet After the sender selects a next hop –the sender encapsulates the datagram in a frame –and transmits the result across the physical network When the frame reaches the next hop –the receiving software examines the IP datagram If the datagram must be forwarded across another network – a new frame is created Figure 22.5 illustrates how a datagram is encapsulated and unencapsulated as it travels along a path Each network can use a different hardware technology than the others –meaning that the frame formats and frame header sizes can differ

41 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.41 22.12 Internet Üzerinden İletilir Gönderici bir sonraki hop’u şeçtikten sonra –Gönderici frame’in içerisindeki datagram’ı encapsulate eder –Ve sonucu fiziksel ağ üzerinden iletir Frame bir sonraki hop’a ulaştığı zaman –Alıcı yazılımı IP datagram inceler Eğer datagram farklı bir ağ üzerinden iletilmek zorundadır –Yeni frame oluşturulur Şekil 22.5 datagram’ın nasıl kapsülleneceği ve kapsülden çıkartılarak yol üzerinden iletilir Her ağ farklı donanım teknolojisini kullanabilir –Frame formatları ve frame büyüklüğü farklı olabilir

42 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.42 22.12 Internet Üzerinden İletilir

43 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.43 22.12 Transmission Across An Internet Frame headers do not accumulate during a trip through the Internet When a datagram arrives –the datagram is removed from the incoming frame before being encapsulated in an outgoing frame When the datagram reaches its final destination –the frame header will be the header of the last network over which the datagram arrived –once the header is removed, the result is the original datagram

44 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.44 22.12 Internet Üzerinden İletilir Frame başlıkları internetteki gezintisi sonucunu biriktirir Datagram geldiği zaman –Gelen paketin içerisindeki Datagram çıkartılır ve giden paketin içerisine koyulacaktır Datagram en son adres’e ulaştığı zaman –Frame başlığı ağdaki en son durağın adresini içerir –Header çıkartılır, sonuç olarak elde kalan datagram’dır

45 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.45 22.13 MTU And Datagram Fragmentation Each hardware technology specifies the maximum amount of data that a frame can carry –The limit is known as a Maximum Transmission Unit (MTU) There is no exception to the MTU limit –Network hardware is not designed to accept or transfer frames that carry more data than the MTU allows –A datagram must be smaller or equal to the network MTU or it cannot be encapsulated for transmission In an internet that contains heterogeneous networks, MTU restrictions create a problem A router can connect networks with different MTU values –a datagram that a router receives over one network can be too large to send over another network

46 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.46 22.13 MTU ve Datagram Parçalanması Her donanım teknolojisi frame’in taşıyacağı maksimum büyüklüğündeki veriyi tanımlar –Limit gönderilebilecek maksimum unite MTU(Maximum Transmission Unit ) olarak bilinir MYU limit’inde istisnai bir durum yoktur –Network hardware is not designed to accept or transfer frames that carry more data than the MTU allows –Network donanımı MTU’dan daha büyük paketleri kabul etmiyor Yada iletim için kapsüllenmez Internet heterojen ağlar içerir, MTU kısıtlamaları problem oluşturur Router farklı MTU değerlerine sahip ağlarla çalışabiliyor –Router’ın almış olduğu Datagram farklı bir ağ’a göndermek için çok büyük olabilir

47 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.47 22.13 MTU ve Datagram Parçalanması Şekil 22.6 (aşağıdaki) MTU boyutu 1500 and 1000 olan iki ağın birleşimini gösterir –H host’u Ağ’a MTU 1500 olan değeri ile ulaşır Ve datagram 1500 octet olan veri gönderir –H Host Ağ’a MTU 1000 olan değeri ile ulaşır buda 1000 octetten büyük datagramları gönderip alamaz –Eğer H host’u 1500-octet datagram’ı H’a gönderir –R router’ı ağ 2’ye iletilmek için kamsüle edilmez

48 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.48 22.13 MTU And Datagram Fragmentation To solve the problem of heterogeneous MTUs –a router uses a technique known as fragmentation When a datagram is larger than the MTU of the network over which it must be sent –the router divides the datagram into smaller pieces called fragments –and sends each fragment independently A fragment has the same format as other datagrams –a bit in the FLAGS field of the header indicates whether a datagram is a fragment or a complete datagram Other fields in the header are assigned information for the ultimate destination to reassemble fragments –to reproduce the original datagram The FRAGMENT OFFSET specifies where in the original datagram the fragment belongs

49 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.49 22.13 MTU ve Datagram Parçalanması Heterojen MTU’lardan kaynaklanan problemi çözmek için –Router’ların kullanmış olduğu teknik fragmentation (parçalanmak) olarak bilinir Ağ üzerinden gönderilecek Datagram’dan büyük olan MTU nasıl gönderilecek? –Router datagram’ı küçük paçalara bölerler (fragment’ler) –Ve her parça bağımsız olarak iletilir Parçalar diğer datagram’lardaki aynı format’ı kullanır –Başlık içerisindeki FLAGS alanındaki bit datagram’ın içerisindeki paketlerin parçalanıp parçalanmadığını içerir Başlık içerisindeki diğer Alanlar bilgi olarak atanır, bunuda hedef adreste birleştirmek için kullanılır –Orjinal datagram’ı yeniden oluşturulur FRAGMENT OFFSET orjinal datagram’ın parçaların hangi datagram’a ait olduğunu içerir

50 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.50 22.13 MTU And Datagram Fragmentation A router uses the network MTU and the header size to calculate –the maximum amount of data that can be sent in each fragment –and the number of fragments that will be needed The router then creates the fragments –It uses fields from the original header to create a fragment header For example, the router copies the IP SOURCE and IP DESTINATION fields from the datagram into the fragment header –It copies the appropriate data from the original datagram into the fragment –Then it transmits the result Figure 22.7 illustrates the division of a datagram into fragments

51 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.51 22.13 MTU ve Datagram Parçalanması Router Ağ’ın MTU’sunu kullanır ve başlık büyüklüğü hesaplanır –Her fragmet’e gönderilecek maksimum veri büyüklüğü –Ve gerekli olan parçaların sayısı Router daha sonra parçalarını oluşturur –Orjinal başlıktaki alanları yeni fragmente başlığı oluşturmak için kullanılır For example, the router copies the IP SOURCE and IP DESTINATION fields from the datagram into the fragment header –Orjinal veriden gerekli verinin kopyalanması gerekir –Sonra paketleri gönderir ŞEkil 22.7 bu bölünmeyi gösterir

52 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.52 22.13 MTU ve Datagram Parçalanması Router Ağ’daki MTU’yu kullanır ve başlık büyüklüğünü hesaplar –Her parçada gönderilebilecek maksimum veri büyüklüğü –Ve gerekli olan parça sayıları Router parçaları üretir –Orjinal başlıktaki alanları kullanarak parçalanmış başlıkları oluşturur For example, the router copies the IP SOURCE and IP DESTINATION fields from the datagram into the fragment header –Orjinal veriden gerekli olan veriler parçalanmış paketlere kopyalanır –Sonra, sonucu iletir Şekil 22.7 bu bölme işelemini gösterir

53 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.53 22.13 MTU ve Datagram Parçalanması

54 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.54 22.14 Reassembly Of A Datagram From Fragments Datagramdan orjinal dosyanın kopyasını çıkarmak için parçalanmış paketler tekrar birleştirilir Her parçalanmış paket, orjinal datgram başlığının bir kopyasını barındırır Bütün parçalar aynı hedef adresini içerir, ve bu bilgide orjinal datagram dan alınan bilgidir Enson veri’yi taşıyan paket, başlığında ek olarak bir bilgi barındırır –Böylelikle, birim birleştirme işlemini gerçekleştirir ve bütün paketlerin başarılı bir şekilde ulaşıp ulaşmadığını bildirir En son hedef bütün parçaları birleştirmek zorunda

55 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.55 22.14 Reassembly Of A Datagram From Fragments Consider the configuration in Figure 22.8 –if host H 1 sends a 1500-octet datagram to host H 2, router R 1 will divide the datagram into two fragments, which it will forward to R 2 –Router R 2 does not reassemble the fragments Instead R uses the destination address in a fragment to forward the fragment as usual –The ultimate destination host, H 2, collects the fragments, and reassembles them to produce the original datagram

56 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.56 22.14 Reassembly Of A Datagram From Fragments Şekil 22.8 deki konfigurasyonu gözden geçirin –Eğer host –if host H 1 sends a 1500-octet datagram to host H 2, router R 1 will divide the datagram into two fragments, which it will forward to R 2 –Router R 2 does not reassemble the fragments Instead R uses the destination address in a fragment to forward the fragment as usual –The ultimate destination host, H 2, collects the fragments, and reassembles them to produce the original datagram

57 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.57 22.14 Reassembly Of A Datagram From Fragments Requiring the ultimate destination to reassemble fragments has two advantages: First, it reduces the amount of state information in routers –When forwarding a datagram, a router does not need to know whether the datagram is a fragment Second, it allows routes to change dynamically –If an intermediate router were to reassemble fragments, all fragments would need to reach the router By postponing reassembly until the ultimate destination –IP is free to pass some fragments from a datagram along different routes than other fragments –That is, the Internet can change routes at any time (e.g., to route around a hardware failure)

58 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.58 22.14 Reassembly Of A Datagram From Fragments Requiring the ultimate destination to reassemble fragments has two advantages: First, it reduces the amount of state information in routers –When forwarding a datagram, a router does not need to know whether the datagram is a fragment Second, it allows routes to change dynamically –If an intermediate router were to reassemble fragments, all fragments would need to reach the router By postponing reassembly until the ultimate destination –IP is free to pass some fragments from a datagram along different routes than other fragments –That is, the Internet can change routes at any time (e.g., to route around a hardware failure)

59 © 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.59 22.15 Collecting The Fragments Of A Datagram Parçalanmış datagramlar sıralı ulaşabilir –Bağımsız parçalanmış paketler kaybolabilir yada sırasız da ulaşır Sırasız giden paketlerin nasıl tekrar orjinal pakete birleştirilir? Gönderici giden paketin içerisinde eşsiz tanıma numarası IDENTIFICATION alanı ekler Router paket’i parçaladığı zaman –Router her fragment’e olan paket’e bu numarayı koyar Alıcı bu tanıma numarasını kullanır –Fragmente olan paketin hangi datagram’a sahip olduğunu hesaplamak için FRAGMENT OFFSET alanı alıcıya verinin orjinal datagram’da neye karşılık geldiğini belirtir


"© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints." indir ppt

Benzer bir sunumlar


Google Reklamları