4. IP addressing
IP Address
192.168.15.2 (decimal)
11000000 10101000
00001111 00000010 (binary)
Subnet Mask:
255.255.255.0 (decimal)
11111111 11111111
11111111 00000000 (binary)
IP Address
192.168.15.2 (decimal)
11000000 10101000
00001111 00000010 (binary)
Subnet Mask:
255.255.255.0 (decimal)
11111111 11111111
11111111 00000000 (binary)
Network part Host part
5. IP addressing (network/ broadcast)
.1
.254
192.168.15.0/24
For our example:
192.168.15.255
-> broadcast
address;
Packet sent to
broadcast address
.1
.254
A packet sent to broadcast address will be
received by all nodes.
Range: 192.168.15.0 to 192.168.15.255;
Two addresses are reserved in every network
1) host bits all zeros (for representing the network)
2) host bits all ones (for the broadcast address)
6. Example application
We assumed that a student (in the
niit.edu.pk LAN) wanted to access NUST-
SEECS website hosted at www.niit.edu.pk
W
W
W
P
C
In the last lecture, we assumed a
greatly simplified model of the
LAN of NUST-SEECS
Network’s domain name:
niit.edu.pk
8. W
W
W
D
N
SReply
The IP address of
www.niit.edu.pk is
202.125.157.196
DNS Client/Server Exchange
The IP address of
www.niit.edu.pk is
202.125.157.196
10. W
W
W
D
N
S
Reply
The MAC address of
202.125.157.196 is
12:34:aa:bb:cc:dd
ARP Client/Server Exchange
The MAC address of
202.125.157.196 is
12:34:aa:bb:cc:dd
11. Layered Communications
GET / HTML/1.1
Source MAC address | Destination MAC address
23:34:aa:bb:cc:dd | 12:34:aa:bb:cc:dd
FCSPayload
PayloadSource Port | Destination Port
> 1024 | 80
Payload
PayloadSource IP | Destination IP
202.125.157.150 | 202.125.157.196
Payload
Application data
TCP Segment
MAC Frame
IP Packet
12. HTTP High-level Exchange
W
W
W
D
N
S
Send me the index.html page
for the host www.niit.edu.pk
using HTTP version 1.1
Request
Send me the index.html page
for the host www.niit.edu.pk
using HTTP version 1.1
13. W
W
W
D
N
S
Reply
The index.html page in the wwwroot directory
configured for the www.niit.edu.pk webserver
is sent back to the browser for display
HTTP Client/Server Exchange
16. Layered Communication
GET / HTML/1.1
Source MAC address | Destination MAC address
23:34:aa:bb:cc:dd | 12:34:aa:bb:cc:dd
FCSPayload
PayloadSource Port | Destination Port
> 1024 | 80
Payload
PayloadSource IP | Destination IP
202.125.157.150 | 202.125.157.196
Payload
Application layer
Transport layer
Link layer
Internet layer
TCP/IP model
Point-to-point (PTP) topology connects two nodes directly together. The following examples are pure point to point links:
Two computers communicating via modems.
A mainframe terminal communicating with a front end processor.
A workstation communicating along a parallel cable to a printer.
http://www.dcs.napier.ac.uk/~bill/cisco_presentation/brian.ppt
Courtesy: www.layertwo.net
www.tcpipguide.com
There’s another layering model that’s called OSI model; we will not cover it in this course. However, you should know that it exists. You will study more about it in your computer networking course sometime in your last year.
OSI very successful at shaping thought. TCP/IP standard, however, has been practically more successful since it’s not based on the rigid OSI model
There’s another layering model that’s called OSI model; we will not cover it in this course. However, you should know that it exists. You will study more about it in your computer networking course sometime in your last year.
OSI very successful at shaping thought. TCP/IP standard, however, has been practically more successful since it’s not based on the rigid OSI model
Explain hubs/ switches/ routers through animations:
In a hub: a frame is received; it is copied on all other ports; it’s called a physical layer device. Show a frame being copied on all ports.
Motivate the question? Why copy on all ports, when you can just copy to the port the destination MAC is in? This can improve throughput as it will reduce some collisions and enable simultaneous transmissions.
In a switch, the frame is copied to the port destination MAC is connected to; how are the MAC addresses learnt?
A router is used to connect different LANs; An example?