Computer Networks - IPv4 and IPv6 (LEC #8)
Document Details
Uploaded by PromptIntegral3045
Imam Abdulrahman Bin Faisal University
Tags
Summary
These lecture notes cover computer networks, focusing on IPv4 and IPv6 addressing. The document includes discussions on topics like addresses, communication types (unicast, broadcast, multicast), and network portions. Useful for those studying computer networking.
Full Transcript
Computer Networks LEC #8 Computer Networks Addressing the LEC #2 Network IPv4 and IPv6 Communicating Over the Network Lecture Outlines Explain the use of IPv4 addresses. IPv4 Unicast, Broadcast, and Multicast Explain public, private, and reserved IPv4 addr...
Computer Networks LEC #8 Computer Networks Addressing the LEC #2 Network IPv4 and IPv6 Communicating Over the Network Lecture Outlines Explain the use of IPv4 addresses. IPv4 Unicast, Broadcast, and Multicast Explain public, private, and reserved IPv4 addresses IPv6 Network Addresses Internet Protocol Version 4 (IPv4) IPv4 Addresses Binary numbering system consists of the numbers 0 and 1 called bits IPv4 addresses are expressed in 32 binary bits divided into 4 octets(8-bit) 4 IPv4 Addresses (Cont.) IPv4 addresses are commonly expressed in dotted decimal notation 5 Network and Host Portions An IPv4 address is hierarchical. Composed of a Network portion and Host portion. All devices on the same network must have the identical network portion. 6 The Subnet Mask helps devices identify the network portion and host portion. The IPv4 Address configured on a host Three IPv4 addresses must be configured on a host: Unique IPv4 address of the host. Subnet mask - identifies the network/host portion of the IPv4 address. Default gateway -IP address of the local 7 router interface. IPv4 Address Structure The Subnet Mask The IPv4 address is compared to the subnet mask bit by bit, from left to right. A 1 in the subnet mask indicates that the corresponding bit in the IPv4 address is a network bit. 8 Network, Host, and Broadcast Addresses Types of Addresses in Network 192.168.10.0/24 Network Address - host portion is all 0s (.00000000) First Host address - host portion is all 0s and ends with a 1 (.00000001) Last Host address - host portion is all 1s 9 and ends with a 0 (.11111110) Broadcast Address - host portion is all 1s (.11111111) Static IPv4 Address Assignment to a Host Some devices like printers, servers and network devices require a fixed IP address. Hosts in a small network can also be configured with static addresses. 10 Dynamic IPv4 Address Assignment to a Host Most networks use Dynamic Host Configuration Protocol (DHCP) to assign IPv4 addresses dynamically. The DHCP server provides an IPv4 address, subnet mask, default gateway, and other configuration information. DHCP leases the addresses to hosts for a certain length of time. If the host is powered down or taken off the 11 network, the address is returned to the pool for reuse. IPv4 Unicast, Broadcast, and Multicast IPv4 Communication 12 Unicast – one to Broadcast– one Multicast – one one to all. to a communication. select group. Unicast Transmission Unicast – one to one communication. Use the address of the destination device as the destination address. 13 Broadcast Transmission Broadcast– one to all Message sent to everyone in the LAN (broadcast domain.) destination IPv4 address has all ones (1s) in the host portion. 14 Multicast Transmission Multicast– one to a select group. 224.0.0.0 to 239.255.255.255 addresses reserved for multicast. routing protocols use multicast transmission to 15 exchange routing information. Public and Private IPv4 Addresses Private Addresses Not routable Introduced in mid 1990s due to depletion of IPv4 addresses Used only in internal networks. Must be translated to a public IPv4 to be routable. Defined by RFC 1918 Private Address Blocks © 2016 Cisco and/or its affiliates. All rights reserved. Cisco 16 Confidential Address ranges to be use by private networks are: Class A: 10.0. 0.0 to 10.255. 255.255. Class B: 172.16. 0.0 to 172.31. 255.255. Class C: 192.168. 0.0 to 192.168. 255.255. Special User IPv4 Addresses Loopback addresses (127.0.0.0 /8 or 127.0.0.1) Used on a host to test if the TCP/IP configuration is operational. Link-Local addresses (169.254.0.0 /16 or 169.254.0.1) Used for link local addresses between two hosts on a single link when no IP address is otherwise specified, such as would have normally been retrieved from a DHCP (Dynamic Host Configuration Protocol ) server. TEST-NET addresses (192.0.2.0/24 or 192.0.2.0 to 192.0.2.255) Used for teachin© 2g016 aCisnco dand/olr eits aaffiliratens. Ailnl rigghts.reserved. Cisco Special address blocks Number of Address block Address range Scope Description addresses 127.0.0.0– Used for loopback addresses to 127.0.0.0/8 16777216 Host 127.255.255.255 the local host. Used for link-local addresses between two hosts on a single 169.254.0.0– link when no IP address is 169.254.0.0/16 65536 Subnet 169.254.255.255 otherwise specified, such as would have normally been retrieved from a DHCP server. 192.0.2.0– Assigned as TEST-NET-1, 192.0.2.0/24 256 Documentation 192.0.2.255 documentation and examples. IPv4 Packet Header An IPv4 packet header consists of the fields containing binary numbers. These numbers identify various settings of the IP packet which are examined by the Layer 3 process. Significant fields include: Version – Specifies that the packet is IP version 4 Differentiated Services or DiffServ (DS) – Used to determine the priority of each packet on the network. Time-to-Live (TTL) – Limits the lifetime of a © 2016 Cisco and/or its affiliates. All rights reserved. Cisco Confidential 19 packet – decreased by one at each router along the way. Protocol – Used to identify the next level protocol. Source IPv4 Address – Source address of Internet Protocol Version 6 (IPv6) IPv6 Introducing IPv6 In the early „90s, started looking at a replacement for IPv4 – which led to IPv6. Advantages of IPv6 over IPv4 include: Increased address space – based on 128-bit addressing vs. 32-bit with IPv4 Improved packet handling – fewer fields with IPv6 than IPv4 21 Eliminates the need for NAT(network address translation) – no need to share addresses with IPv6 There are roughly enough IPv6 addresses for every grain of sand on Earth. IPv6 Address Representation IPv6 Addresses: 128 bits in length Every 4 bits is represented by a single hexadecimal digit Hextet - unofficial term referring to a segment of 16 bits or four 22 hexadecimal values. Encapsulating IPv6 The IPv6 header is simpler than the IPv4 header. Encapsulating IPv6 (Cont.) Advantages of IPv6 over IPv4 using the simplified header: Simplified header format for efficient packet handling Hierarchical network architecture for routing efficiency Autoconfiguration for addresses Elimination of need for network address translation (NAT) between private and public addresses 24 IPv6 Packet Header IPv6 packet header fields: Version – Contains a 4-bit binary value set to 0110 that identifies it as a IPv6 packet. Traffic Class – 8-bit field equivalent to the IPv4 Differentiated Services (DS) field. Flow Label – 20-bit field suggests that all packets with the same flow label receive the same type of handling by routers. Payload Length – 16-bit field indicates the length of the data portion or payload 25 of the packet. Next Header – 8-bit field is equivalent to the IPv4 Protocol field. It indicates the data payload type that the packet is carrying. IPv6 Packet Header (Cont.) IPv6 packet header fields: Hop Limit – 8-bit field replaces the IPv4 TTL field. This value is decremented by 1 as it passes through each router. When it reaches zero, the packet is discarded. Source IPv6 Address – 128-bit field that identifies the IPv6 address of the sending host. Destination IPv6 Address – 128-bit field that identifies the IPv6 address of the 26 receiving host. 27