0% found this document useful (0 votes)
58 views

Data Comm Part 2.ppt New

IP addresses are numeric identifiers assigned to devices connected to the internet or a private network. They consist of four numbers separated by periods. IP addresses are allocated and managed by IANA and ISPs. Organizations obtain address blocks from their ISP which they can then assign to individual hosts using DHCP or manual configuration. Subnetting allows more efficient use of IP addresses by creating additional networks and subnets from a single address block.

Uploaded by

muhabamohamed21
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
58 views

Data Comm Part 2.ppt New

IP addresses are numeric identifiers assigned to devices connected to the internet or a private network. They consist of four numbers separated by periods. IP addresses are allocated and managed by IANA and ISPs. Organizations obtain address blocks from their ISP which they can then assign to individual hosts using DHCP or manual configuration. Subnetting allows more efficient use of IP addresses by creating additional networks and subnets from a single address block.

Uploaded by

muhabamohamed21
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 48

IP addressing

 An IP address is a string of numbers separated by periods. IP


addresses are expressed as a set of four numbers. for example
an address might be 192.158.1.38. Each number in the set can
range from 0 to 255. So, the full IP addressing range goes from
0.0.0.0 to 255.255.255.255.
HOW TO GET IP ADDRESS????
 IP addresses are not random. They are mathematically
produced and allocated by the Internet Assigned Numbers
Authority (IANA), a division of the Internet Corporation for
Assigned Names and Numbers (ICANN). Each time anyone
registers a domain on the internet, they go through a domain
name registrar, who pays a small fee to ICANN to register the
domain.
1
Internet service provider(ISP)
 In order to obtain a block of IP addresses for use within an
organization’s subnet, a network administrator might
first contact its ISP, which would provide addresses from a
larger block of addresses that had already been allocated to the
ISP.
 For example, the ISP may itself have been allocated the address
block 200.23.16.0/20. The ISP, in turn, could divide its
address block into eight equal-sized contiguous address blocks
and give one of these address blocks out to each of up to eight
organizations that are supported by this ISP.
 If you are configuring a host (computer):
 Manual configuration by system admin.
 Windows: Control panel  network configuration
TCP/IP  properties.
 DHCP (Dynamic Host Configuration Protocol).
 Dynamically get address from server (plug-and-play).
 Once an organization has obtained a block of addresses, it can
assign individual IP addresses to the host and router
interfaces in its organization.
 Host addresses can also be configured manually, but more
often this task is now done using the Dynamic Host
Configuration Protocol (DHCP).
3
Dynamic Host Configuration Protocol (DHCP)
 Allow a host to obtain its IP address automatically.
 Other information such as subnet mask and DNS server will
also be obtained automatically.
 Each subnet must have a DHCP server.
 Alternatively, the router must be configured so that it can
relay a DHCP request to a DHCP server on a different
subnet.
 A DHCP server maintains a list of available IP
addresses.
 A host that joins the network will be given an available IP
address from the list.
 When the host leaves the network, the IP address will be
returned to the list and again becomes available.

4
Internet Protocol Versions(IPv4 & IPv6)
 Internet Protocol (IP) Version (IPv4) is currently the most
widely-used version of IP.
 It is the only IP protocol that is used to carry user data over
the Internet.
 IP version 6(IPv6) is developed and being
implemented in some areas.
 IPv6 will operate alongside IPv4 and may replace it in the
future.
 IPv4 basic characteristics:
 Connectionless -No connection is established before
sending data packets. 5

 Best Effort (unreliable) - No overhead is used to guarantee


IPv4 addressing
 IP address is a 32 bit Internet address.
 Unique 32 bit IP address is assigned to each host in the Internet.
 Each device connected to the Internet must have a physical
(MAC) address and also a logical or Internet address.
 It is divided into two parts:
o First part identifies network (prefix).
o Second part identifies host (suffix).
 Global authority assigns unique prefix to network and
 Local administrator assigns unique suffix to host.

6
 Internet address designers (IPV4) decided to divide the IP
address space into five classes varying in their size.
 These are:
 Class A
 Class B
 Class C
 Class D
 Class E
 Each class fixes the boundary between the network prefix and
the host number at a different point within the 32 bit
address.
7
Contd
Finding the class in binary notation
Finding the address class
Finding the class in decimal notation
Netid and Hostid
Class A networks ( /8 )
 Have 8 bit network prefix starting with 0 and 7 bit network
number, followed by 24 bit host number.
 A maximum of 126 (2^7-2) /8 networks can be defined.
 All zeros (00000000) is reserved for default route, & 127 is
reserved for the “loopback” (01111111).
 Each network supports a maximum of 16,777,214(2^24-2)
hosts.
 All zeros “for this network” and all ones for broadcast number in
each network.

13
Class B networks ( /16 )
 Has 16 bit network prefix starting with 10.
 14 bit network number & 16 bit host number.
 A maximum of 2^14= 16,384 networks can be
defined.
 2^16-2= 65,534 hosts per network.

14
Class C networks ( /24 )

 Each network address has a 24 bit network prefix.


 Starts with 110 and 21 bit network number.
 A maximum of 2^21= 2,097,152 networks can be
defined with up to 2 ^8-2 = 254 hosts per network.
 Class C’s individual addresses is 2^29 = 536,870,912.

15
Dotted decimal notation
 Was devised to make Internet addresses easier for
people to read and write.
 Shorthand for IP addresses.
 Allows humans to avoid binary.
 Represents each byte in decimal separating by dots.
 Four decimal values per 32 bit addresses.

16
Dotted decimal notation

17
Reserved IPv4 Address Ranges
 The IPv4 address range is 0.0.0.0 to 255.255.255.255= 2^32
 Not all of these addresses can be used as host addresses.
 Experimental Addresses
 Ranges from 240.0.0.0 to 255.255.255.254. Reserved for
special purposes (research or experimentation).
 Host Addresses
 an address range of 0.0.0.0 to 223.255.255.255 is used for
IPv4 hosts. However, within this range are many addresses
that are already reserved for special purposes.

18
Special IPv4 Addresses
 Loopback
 is a special address that hosts use to direct
traffic to themselves.
 Although only the single 127.0.0.1 address is used,
addresses 127.0.0.0 to 127.255.255.255 are
reserved.
 Link-Local Addresses

 These addresses can be automatically assigned to


the local host by the operating system in
environments where no IP configuration is
available.
 The address block is 169.254.0.0 to 169.254.255.255
19
Contd
 TEST-NET Addresses
 The address block 192.0.2.0 to 192.0.2.255 (192.0.2.0
/24) is set aside for teaching and learning purposes. can be
used in documentation and network examples.
Default gateway
 Each PC is configured with an IP address and a default gateway.
 The default gateway is the IP address of a router port on the
same network as the PC.
 It is the router’s job to handle messages to other networks.
 Each router port is on a different network and has a different IP
address.
20
Problems with IPV4 addressing
 The eventual exhaustion of IPV4 address space.
 The need to route traffic between the increasing number of
networks that comprise the Internet.
 Addresses are assigned to those asked without concerns of
their actual need, but according their request.
 Lack of a network class that support medium size
organizations. (/24 supports 254 hosts, too small, while /16
supports 65,534 hosts, too large).

21
Sub netting
 Sub netting is the process of creating new networks (or
subnets) by stealing/borrowing bits from the host portion of a
subnet mask. stealing bits from hosts creates more networks
but fewer hosts per network.

 Two level class-full hierarchy

 Three level subnet hierarchy

22
Subnet mask
 The subnet mask is created by placing a binary 1 in each bit
position that represents the network portion and placing a
binary 0 in each bit position that represents the host portion.
Identifies how much of the address spaces are used for the
network and for the host.
 Identifies Prefix / suffix boundary.
 1 bits cover prefix and 0 bits cover suffix
• 10000010.00000101.00000101.00011001= 130.5.5.25/24
• 11111111.11111111.11111111.00000000 = 255.255.255.0
Default subnet mask for class A = 255.0.0.0
Default subnet mask for class B = 255.255.0.0
Default subnet mask for class C = 255.255.255.0
23
Comparison of a default mask and
a subnet mask

The number of subnets must be


a power of 2.
Subnet design
 Four key points taken into consideration:
 How many total subnets does the organization need
today?
 How many total subnets will the organization need in
the future?
 How many hosts are on the organization’s largest subnet
today?
 How many hosts will there be on the organization’s
largest subnet in the future?
 It is to take the maximum number of subnets required and
round up to the nearest power of two.
 To ensure that there are enough host addresses for the
organization’s largest subnet.
25
Classless Inter-domain Routing (CIDR)
 CIDR is a system of IP addressing and routing that solves
many problems of classful addressing by eliminating fixed
address classes in favor of a flexible, hierarchical
multiple level structure of networks of varying sizes.
 Advantages of CIDR:
 Efficient address space allocation
 Elimination of class imbalances

26
Slash notation

Slash notation is also called


CIDR
notation.
A block in classes A, B, and C
can easily be represented in slash
notation as
A.B.C.D/ n
where n is
either 8 (class A), 16 (class B), or
24 (class C) or classless
Classless Inter domain Routing (CIDR)
 Since there are no address classes in CIDR, one can not tell
the size of the network ID of an address from the address
alone.
 IN CIDR the length of the network ID (prefix) is
indicating by placing it following a slash after the
address.
 This is called CIDR notation or slash notation.
 Example: 184.13.152.0/22. “22” means this network has 22
bits for the network ID and 10 bits for host address.
 Its subnet mask is 255.255.252.0 and has a total of 1022(2^10-
2) hosts.

29
Classless Inter domain Routing (CIDR)
 Example:
 A middle size ISP has assigned an address 71.94.0.0/15,
means 15 bits network ID and 17 bits host address.
 It was assigned from a large size ISP
 71.94.0.0/15 has 131,070 possible host addresses (2^17-2).
 It is possible to create 2 subnets using 1 bite from the host
part = 71.94.0.0/16 and 71.95.0.0/16, each with 2^16-2
(65534) host addresses.

30
Data Link Layer
 It is the responsible of node to node delivery of messages.
Functions of DLL
 Framing: The layer which divides the stream of packets
received from the network layer into manageable data units
called frames.
 Physical Addressing it adds physical address of sender and
receiver in the head of each frame.
 Error control and Flow control
33

Error control and Flow control


 The most important responsibilities of the data link layer are

flow control and error control.


 Error Control involves both error detection and error
correction.
 It is necessary because errors are inevitable in data
communication, in spite of the use of better equipment and
reliable transmission media based on the current technology.
Error
Single-bit error

Multiple-Bit Error:

34
Error detection
 Error Detection techniques allow to the destination to detect
errors.
 Sometimes undetected errors will still remain but the goal is to
minimize these errors.
 Error Detection mechanisms

 Parity Check

 CRC

 Check sum

35
Parity check- method
 A parity bit is added to every data unit so that the total number of

1’s in the unit becomes even or odd.

36
Example

The sender wants to send the data: 1110111 1101111


The actual bits sent are: 11101110 11011110

Without error: 11101110 11011110 are transmitted.


The receiver counts 1’s in each character and comes up with: (6, 6)
Accepted!

With error: 11111110 11011110 are transmitted


The receiver counts 1’s each character and comes up with: (7, 6)
The data are corrupted! discards them, and asks for
retransmission.
CRC
Steps: First, a string of n 0’s is appended to the data unit.

 The number n is 1 less if-number of bits in the

predetermined divisor which is n + 1 bits.

 Second, the newly elongated data unit is divided by the

divisor, using binary division.

 The remainder resulting from this division is the CRC.

 Third, the CRC of n bits derived in step 2 replaces the

appended 0’s at the data unit.


38
Cont.’
 The data unit arrives at the receiver data first, followed by

the CRC.

 We assume that:

 There is no error, the remainder is therefore all 0’s, and the

data are accepted.

 There is error, the remainder is therefore non-zero, and the

data are discarded.

39
Error correction
Flow control
 Flow Control: refers to a set of procedures used to restrict
the amount of data that the sender can send before waiting for
acknowledgment.
 Is the process of rate of data transmission between two nodes to

prevent a faster sender from overwhelming a slow receiver and


it prevents receiver becoming overloaded.
 There are three methods developed for flow control
1 Stop-and-wait
2. Go-Back N ARQ
3. Selective Repeat ARQ.
Stop-and-Wait ARQ
 A transmitter sends a frame then stops and waits for an

acknowledgment.

 The sending device keeps a copy of the sent frame

transmitted until it receives an acknowledgment( ACK).

 The sender starts a timer when it sends a frame. If an ACK is

not received within an allocated time, the sender resends it.

 Both frames and acknowledgment (ACK) are numbered

alternately 0 and 1( two sequence number only).


42
Stop and wait protocols

RTT = Round Trip Time


Go Back N ARQ
 Go back –N retransmit all packets

 Based on sliding window

 Sliding window is a method for controlling transmitted


data packets b/n two network computers.
 Assume GB4:

 sender window size=4

 We need at least sequence number=4

 What happen during transmission of the frames?

44
Explanation- GB4
 ...
3 2 1 0 Sender Receiver
0
0 1 2 3 0 1 2 3
1

If ACK s are lost


0
1
Retransmission 2
Frame duplication!
3
45
Selective Repeat ARQ
• Go-back-n ARQ is inefficient of a noisy link.

 In a noisy link frames have higher probability of damage ,


which means the resending of multiple frames.
 This resending consumes the bandwidth and slow down
the transmission .
solution:
 Selective repeat ARQ protocol : resent only the damage
frame
46
Explanation

Sender Receiver

Data-0

Data-1

Data-2

NACK-2 Frame-2 discarded


Retransmit Data-2 Data-2

.
. Data-3

47
Physical Layer
Physical layer coordinates the functions required to carry
a bit stream over a physical medium. It deals with the
mechanical and electrical specifications of the interface
and transmission medium.
Functions of Physical layer
 Representation of bits
 Physical topology
 Transmission mode

You might also like