Mod4 Final
Mod4 Final
●
Internetworking protocol (lP) does not have an inbuilt mechanism for sending error and control messages.
●
The IP protocol has no error-reporting or error-correcting mechanism.
●
It provides unreliable and connectionless datagram delivery.
●
The IP protocol also lacks a mechanism for host and management queries.
MODULE 4 – A host sometimes needs to determine if a router or another host is alive. And sometimes a network
administrator needs information from another host or router.
ICMP has been designed to compensate for the above 2 deficiencies.
Network Layer in the Internet ●
●
Type: It is an 8-bit field. It defines the ICMP message type.
●
Type 0 – Echo reply
●
Type 3 – Destination unreachable
●
Type 5 – Redirect Message
●
Type 8 – Echo Request
●
Type 11 – Time Exceeded
●
Type 12 – Parameter problem
●
Code: It is an 8-bit field that defines the subtype of the ICMP message. This field carries
some additional information about the error message and type.
●
Checksum: It is a 16-bit field to detect whether the error exists in the message or not.
1. Error reporting messages 1. Destination unreachable
●
One of the main responsibilities of ICMP is to report errors ●
The destination unreachable error occurs when the packet does not reach the
●
ICMP does not correct errors - it simply reports them. destination.
●
Error correction is left to the higher-level protocols.
●
Suppose the sender sends the message, but the message does not reach the destination,
then the intermediate router reports to the sender that the destination is unreachable.
●
ICMP always reports error messages to the original source.
Types of Error Reporting messages
The error reporting messages are broadly classified into the following categories:
●
2. Timestamp-request and timestamp-reply message
●
The timestamp-request and timestamp-reply messages are also a type of query messages.
●
Suppose the computer A wants to know the time on computer B, so it sends the timestamp-request message to
computer B.
●
The computer B responds with a timestamp-reply message.
ARP stands for Address Resolution Protocol. RARP stands for Reverse Address Resolution Protocol.
A protocol used to map an IP address to a physical (MAC) A protocol used to map a physical (MAC) address to an IP
address address
Host1 broadcasts its IP address and requests a MAC Client broadcasts its MAC address and requests an IP
address, and the host2 responds with the corresponding address, and the server responds with the corresponding IP
MAC address address
Through ARP, (32-bit) IP address mapped into (48-bit) Through RARP, (48-bit) MAC address of 48 bits mapped
MAC address. into (32-bit) IP address.
The primary use of the ARP reply is to update the ARP The primary use of the RARP reply is to configure the local
table. host’s IP address.
Widely used in modern networks to resolve IP addresses to Rarely used in modern networks as most devices have a pre-
MAC addresses assigned IP address
The ARP table is maintained or managed by the local host. The RARP table is maintained by the RARP Server.
Problem of RARP BOOTSTRAP PROTOCOL (BOOTP)
●
Bootstrap Protocol (BOOTP) is a basic protocol that automatically provides each
participant in a network connection with a unique IP address for identification and
●
Broadcasting is done at the data link layer. authentication as soon as it connects to the network.
●
The physical broadcast address doesn’t pass the boundaries of network. – This helps the server to speed up data transfers and connection requests.
– Ie, RARP server must be located within the same physical network.
●
Bootstrap Protocol (BOOTP) is a networking protocol which is used by networking
●
This means that if a network is split into multiple subnets, it need to assign a RARP
administration to give IP addresses to each member which participates in the network
server for each network or subnet. to communicate with other networking devices
●
This is the reason that RARP is almost outdated. ●
BOOTP is used during the bootstrap process when the computer is initially starting up,
●
Two protocols are commonly used for replacing RARP hence the name.
– 1) BOOTP ●
BOOTP was intended for diskless systems because they require such a protocol, in
– 2) DHCP order to contact a server to obtain a network address and some information the
operating system will use.
●
Summary: As soon as a device connects to the network, the Bootstrap Protocol How does BOOTP Work
(BOOTP) immediately provides each member in the connection a distinct IP ●
When a BOOTP client is started, it has no IP address,it only knows its MAC
address address.
●
When a BOOTP client is started, it has no IP address,it only knows its MAC ●
So, it broadcasts a message containing its MAC address onto the network.
address. ●
This message is called a “BOOTP request” and it is picked up by the BOOTP
●
BOOTP message are encapsulated in a UDP packet, and the UDP packet itself server, which replies to the client with the following information that the client
encapsulated in an IP packet. needs:
– The client’s IP address, subnet mask, and default gateway address
– The IP address and host name of the BOOTP server
– The IP address of the server that has the boot image, which the client needs to load its
operating system
●
When the client receives this information from the BOOTP server, it configures and
initializes its TCP/IP protocol stack, and then connects to the server from which the
boot image is shared.
●
The client loads the boot image and uses this information to load and start its
operating system
BOOTP message format
●
Operation Code: Specifies the type of message. A value of 1 indicates a request
(BOOTREQUEST message) while a value of 2 is a reply (BOOTREPLY message).
●
Hardware Type:Denotes the type of hardware technology being used. For example, if the
hardware type is Ethernet, this field holds the value 1.
● Hardware Address Length: Specifies how long hardware addresses are in this message.
For Ethernet or other networks using IEEE 802 MAC addresses, the value is 6.
●
Hops: Specify the number of relay agents or routers through which the message has to
travel between client and the server .client sets it to 0 before transmission and is
incremented at each router.
●
Transaction Identifier: A 32-bit identification field generated by the client, to allow it to
match up the request with replies received from BOOTP servers.
●
Seconds: This field contains the number of seconds “elapsed since the client
started trying to boot”.
– This is supposed to provide information to BOOTP servers to help them
decide which requests to respond to first. ●
Client Hardware Address: The hardware (layer two) address of the client sending
a BOOTREPLY.
●
Client IP Address: If the client has a current IP address that it plans to keep
using, it puts it in this field. By filling in this field, the client is committing to – It is used both to look up a device's assigned IP address and also possibly in delivery of
a reply message
responding to unicast IP datagrams sent to this address.
●
Server Name: The server sending a BOOTREPLY may optionally put its name in this field.
– Otherwise, it sets this field to all zero to tell the server it wants an address
assigned. – This can be a simple text “nickname” or a fully-qualified DNS domain name (such as
“myserver.organization.org”).
●
Your IP Address: The IP address that the server is assigning to the client. This – Name is a unique label that identifies the server.
may be different than the IP address currently used by the client
●
Vendor-Specific Area: Originally created to allow vendors to customize BOOTP to the
●
Server IP Address: The IP address of the BOOTP server sending needs of different types of hardware, this field is now also used to hold additional vendor-
a BOOTREPLY message. independent configuration information.
●
Router IP Address: The IP address of the Router(Relay agent).
Important Features of Bootstrap Protocol
●
Bootstrap Protocol (BOOTP) is a basic protocol that automatically provides each participant in a Uses of Bootstrap Protocol
network connection with a unique IP address for identification and authentication as soon as it
connects to the network. ●
Bootstrap (BOOTP) is primarily required to check the system on a network the first
– This helps the server to speed up data transfers and connection requests. time you start your computer.
●
BOOTP uses a unique IP address algorithm to provide each system on the network with a
completely different IP address in a fraction of a second.
– Records the BIOS cycle of each computer on the network to allow the
computer’s motherboard and network manager to efficiently organize the data
●
This shortens the connection time between the server and the client.
transfer on the computer as soon as it boots up.
●
It starts the process of downloading and updating the source code even with very little information.
●
BOOTP uses a combination of DHCP (Dynamic Host Configuration Protocol) and UDP (User
●
BOOTP is mainly used in a diskless environment and requires no media as all data
Datagram Protocol) to request and receive requests from various network-connected participants is stored in the network cloud for efficient use.
and to handle their responses.
●
BOOTP is the transfer of a data between a client and a server to send and receive
●
In a BOOTP connection, the server and client just need an IP address and a gateway address to
establish a successful connection.
requests and corresponding responses by the networking server.
●
Typically, in a BOOTP network, the server and client share the same LAN, and the routers used in ●
BOOTP supports the use of motherboards and network managers, so no external
the network must support BOOTP bridging. storage outside of the cloud network is required.
●
A great example of a network with a TCP / IP configuration is the Bootstrap Protocol network.
●
Whenever a computer on the network asks for a specific request to the server, BOOTP uses its
unique IP address to quickly resolve them.
●
2. DHCP Offers A Message:
●
5. DHCP Negative Acknowledgment Message:
– The server will respond to the host in this message specifying the unleased IP address and other
TCP configuration information. – Whenever a DHCP server receives a request for an IP address that is invalid according to the scopes
that are configured, it sends a DHCP Nak message to the client.
– The size of the message is 342 bytes.
– Eg-when the server has no IP address unused or the pool is empty, then this message is sent by
– If there is more than one DHCP server present in the network then the client host will accept the the server to the client.
first DHCP OFFER message it receives.
●
6. DHCP Decline:
●
3. DHCP Request Message: – If the DHCP client determines the offered configuration parameters are different or invalid, it sends a
– When a client receives an offer message, it responds by broadcasting a DHCP request message. DHCP decline message to the server.
– The client will produce a gratuitous ARP in order to find if there is any other host present in the – When there is a reply to the gratuitous ARP by any host to the client, the client sends a DHCP
network with the same IP address. decline message to the server showing the offered IP address is already in use.
– If there is no reply from another host, then there is no host with the same TCP configuration in the ●
7. DHCP Release:
network and the message is broadcasted to the server showing the acceptance of the IP address. – A DHCP client sends a DHCP release packet to the server to release the IP address and cancel any
●
4. DHCP Acknowledgment Message: remaining lease time.
– In response to the request message received, the server will make an entry with a specified client ●
8. DHCP Inform:
ID and bind the IP address offered with lease time. – If a client address has obtained an IP address manually then the client uses DHCP information to obtain
– Now, the client will have the IP address provided by the server. other local configuration parameters, such as domain name.
– In reply to the DHCP inform message, the DHCP server generates a DHCP ack message with a local
configuration suitable for the client without allocating a new IP address.
– This DHCP ack message is unicast to the client.
Components of DHCP
●
DHCP Server: DHCP server is a networked device running the DCHP service that holds IP
Advantages of DHCP
addresses and related configuration information. ●
Simplifies the IP address assignment process of network administrators, as the whole process of IP address
assignment can be automated.
– This is typically a server or a router but could be anything that acts as a host, such as an SD-WAN
appliance. – Using DHCP, devices can get their IP addresses and network related parameters automatically on boot up,
without manual intervention
●
DHCP client: DHCP client is the endpoint that receives configuration information from a ●
DHCP optimally uses IP address space, as DHCP mandates periodic renewal of assigned IP addresses.
DHCP server. – Those assigned IP addresses that are not renewed can be used for new end nodes.
– This can be any device like computer, laptop, IoT endpoint or anything else that requires connectivity ●
DHCP supports both static and dynamic modes of IP addresses assignment and both these modes can coexist
to the network. together.
– Most of the devices are configured to receive DHCP information by default. – On a need basis, some nodes could always be assigned the same static IP addresses, based on their device
identity like MAC addresses, while rest of the nodes could be assigned dynamic addresses from a pool of IP
●
IP address pool: IP address pool is the range of addresses that are available to DHCP addresses configured on the DHCP server.
clients. ●
DHCP can be used to assign not only IP addresses, but also a wide range of additional network parameters like
default gateway, DNS server address etc.
– IP addresses are typically handed out sequentially from lowest to the highest. ●
DHCP framework permits vendor specific options to be included inside DHCP messages, so that end nodes can be
●
Subnet: Subnet is the partitioned segments of the large IP networks. assigned even vendor specific parameters.
●
With routers acting as DHCP relay agents, even end nodes that do not have a DHCP server in their network, can
– Subnet is used to keep networks manageable. communicate with remote DHCP servers, to get their IP address and other network related parameters.
●
Lease: Lease is the length of time for which a DHCP client holds the IP address ●
DHCP supports both IPV4 and IPV6 address assignments.
information. Disadvantage -
– When a lease expires, the client has to renew it. ●
IP conflict can occur
– An LSA is a data packet of OSPF that consists of all the information on link-state routing. It is only shared with those routers that
have formed an adjacency.
●
Internal BGP: It is used to interchange routing information between the routers in the same
●
Marker: It is a 32-bit field which is used for the authentication purpose. autonomous system, it is also known as iBGP(Internal Border Gateway Protocol). Internal routers
●
Length: It is a 16-bit field that defines the total length of the message, including the header. also ensure consistency among routers for sharing routing information.
●
Type: It is an 8-bit field that defines the type of the packet.
Internet Multicasting
Exterior Gateway Protocol (EGP) ●
Multicasting is when a group of devices all receive the same messages or packets.
●
The Exterior Gateway Protocol (EGP) was a routing protocol used to connect different
●
Multicast communications refers to one to many communications
autonomous systems on the Internet from the mid-1980s until the mid-1990s, when it was ●
IP multicasting refers to the implementation of multicast communication in Internet.
replaced by Border Gateway Protocol (BGP).
●
Exterior Gateway Protocol (EGP) is a defunct routing protocol used in autonomous systems to
exchange data between surrounding gateway sites.
●
Internet hosts used EGP for data table routing exchanges before BGP was introduced. Available
routers, addresses, cost metrics, and each optimal route selection path are all listed in the EGP
routing table. The EGP model is designed to automate limited events, actions, and transitions.
●
Multicast is driven by receivers.Receivers indicate interest in receiving data.
●
Multicasting works by sharing an IP address between multiple devices.
●
The EGP mechanisms are as follows − ●
Any network traffic directed at that IP address will reach all devices that share the IP address, instead of just one device.
– Obtain neighbors ●
This is much like when a group of employees all receive company emails directed at a certain email
– Keep an eye on your neighbor and check status of neighbours(if they are alive/reachable)
●
A set of receivers for a multicast transmission is called a multicast group.
– Inform neighbours of the networks that reachable within their AS’s. ie, Data is exchanged via update
messages. ●
An user that wants to receive multicast transmissions joins the corresponding multicast group and become a member of
that group.
●
EGP allows neighboring routers in different domains to share information, whereas Interior ●
After an user joins, the network builds the necessary routing paths so that the user receives the data sent to the multicast
Gateway Protocols are utilized within a domain. group.
●
It is used by the hosts and routers to support multicasting.
●
IGMP Membership Report messages :
– Sent by hosts to a multicast router to indicate their interest in joining a multicast group.
●
The IGMP protocol gives the multicast routers information about the membership status of
hosts (routers) connected to the network. – This report informs the router of the presence of a host that wants to receive multicast traffic.
IGMP Messages ●
IGMP Leave Group (LG) messages :
– Sent by hosts to a router indicating that they are leaving a multicast group.
– This message informs the router that the host no longer wants to receive traffic for that
group.
IGMP Message Format Operations of IGMP
1. Joining a Group
●
A host or a router can join a group.
●
A host maintains a list of processes that have membership in a group.
●
When a process wants to join a new group, it sends its request to the host.
●
The host adds the name of the process and the name of the requested group to its list.
●
Type
●
If this is the first entry for this particular group, the host sends a membership report message.
– This is an 8-bit field and is mainly used to define the type of the message. The value of the type can be in both
●
If this is not the first entry, there is no need to send the membership report.
hexadecimal as well as binary notations. 2. Leaving a group
●
Maximum Response Time
●
When a host sees that no process is interested in a specific group, it sends a leave report.
– The size of this field is also 8 bit and it mainly defines the amount of time in which query must be answered. The
●
Similarly, when a router sees that none of the networks connected to its interfaces is interested in a
value of this field is ‘nonzero’ in the query message; while its value is ‘zero’ in the other two types. specific group, it sends a leave report about that group.
●
Checksum ●
However, when a multicast router receives a leave report, it cannot immediately remove that group from
its list.
– The size of this field is 16 bit and it carries the checksum. The checksum is mainly calculated over the 8-byte
message. ●
This is because the report comes from just one host or router and there may be other hosts or routers that
are still interested in that group.
●
Group Address
●
To make sure, the router sends a special query message and wait for a specified time for any host or
– The value of this field is ‘0’ in the case of the general query message. router to respond.
– In the case of a special query, membership report, and leave messages the value of this field defines the groupid. ●
If during this time, no interest (membership report) is received, the router assumes that there are no loyal
members in the network and remove the group from its list.
Working of IGMP
3. Monitoring Membership ●
IGMP works on devices that are capable of handling multicast groups and dynamic multicasting.
●
The multicast router is responsible for monitoring all the hosts or routers in a
●
These devices allows the host to join or leave the membership in the multicast group.
LAN to see if they want to continue their membership in a group. ●
This communication protocol is operated between host and local multicast router.
●
The router periodically (by default, after every 125 s) sends a general query
●
When a multicast group is created, the multicast group address is in range of class D (224-239) IP
addresses and is forwarded as destination IP address in the packet.
message.
●
The router expects an answer for each group in its group list; even new groups
may respond.
●
The query message has a maximum response time of 10 s
●
query message must be sent by only one router (normally called the query ●
L2 or Level-2 devices such as switches are used in between host and multicast router for IGMP
router), also to prevent unnecessary traffic snooping.
●
IGMP snooping is a process to listen to the IGMP network traffic in controlled manner.
●
Switch receives the message from host and forwards the membership report to the local multicast
router.
●
The multicast traffic is further forwarded to remote routers from local multicast routers using PIM
(Protocol Independent Multicast) so that clients can receive the message/data packets.
●
Clients wishing to join the network sends join message in the query and switch intercepts the
message and adds the ports of clients to its multicast routing table.
●
IP address
All the computers of the world on the Internet network communicate with each other with
Working of IP addresses
●
Your device directly requests your Internet Service Provider which then
underground or underwater cables or wirelessly.
grants your device access to the web.
●
If I want to download a file from the internet or load a web page or literally do anything related to
the internet, my computer must have an address so that other computers can find and locate mine ●
And an IP Address is assigned to your device from the given range available.
in order to deliver that particular file or webpage that I am requesting. ●
Your internet activity goes through your service provider, and they route it
●
In technical terms, that address is called IP Address ( Internet Protocol Address ). back to you, using your IP address.
●
An Internet Protocol (IP) address is the unique identifying number assigned to every device
connected to the internet.
●
Your IP address can change. For example, turning your router on or off can
change your IP Address.
– Let us understand it with another example, like if someone wants to send you a letter, then he/she must have
your home address. ●
When you are out from your home location your home IP address doesn’t
– Similarly, your computer too needs an address so that other computers on the internet can communicate with accompany you. It changes as you change the network of your device.
each other without the confusion of delivering information to someone else’s computer.
– And that is why each computer in this world has a unique IP Address. Types of IP Address
– This address is just a string of numbers written in a certain format. ●
IPV4
– It is generally expressed in a set of numbers for example 192.155.12.1. Here each number in the set is from 0
to 255 range.
●
IPV6
– Or we can say that a full IP address ranges from 0.0.0.0 to 255.255.255.255.
●
VERSION: Version of the IP protocol (4 bits), which is 4 for IPv4 .ie, 0100
●
HLEN: IP header length (4 bits), which is the number of 32 bit words in the header. The
minimum value for this field is 5 and the maximum is 15. But actual header length =
HLEN*4 ●
Time to live: Datagram’s lifetime (8 bits), It prevents the datagram to loop through the network by
●
Type of service: Defines additional properties/services of packet like Low Delay, High restricting the number of Hops taken by a Packet before delivering to the Destination and thus avoids
Throughput, Reliability,cost (8 bits) . Eg: If low delay is to be maintained, set value of D to 1. congestion.
●
Total Length: Length of header + Data (16 bits), which has a minimum value 20 bytes and
●
Protocol: Name of the protocol to which the data is to be passed (8 bits) .ie,name of upper layer
protocol that is also involved in packet transmission. eg: TCP,UDP,ICMP etc
the maximum is 216 = 65,535 bytes.
●
Header Checksum: 16 bits header checksum for checking errors in the datagram header itself. Eg:
●
Identification: Unique Packet Id for identifying the group of fragments of a single IP Error: change of address.
datagram (16 bits) ●
Source IP address: 32 bits IP address of the sender
●
Flags: 3 flags of 1 bit each : reserved bit (must be zero), do not fragment flag, more ●
Destination IP address: 32 bits IP address of the receiver
fragments flag Flags (3 bits): These bits are used for controlling and identifying packet ●
Option: Optional information such as source route, record route. Used by the Network administrator to
fragmentation. check whether a path is working or not. The option field is used if extra information need to be added
to the packet. This is not a mandatory field.
●
Fragment Offset: Represents the number of Data Bytes ahead of the particular fragment in
the particular Datagram. It specifies the position of the fragment within the original packet. It
is used to reassemble fragmented packets correctly.
Classes of IPv4 Address:
●
There are around 4.3 billion IPv4 addresses and managing all those
addresses without any scheme is next to impossible.
●
For easier management and assignment, IP addresses are organized in
numeric order and divided into the following 5 classes : A,B,C,D and E.
●
If the address is given in binary notation, the first few bits can
immediately tell us the class of the address.
●
If the address is given in decimal-dotted notation, the first byte defines
the class.
Q1 : ●
Each IP address has two parts
– Network id part - the network, the IP address belongs to.
– Host id part - the host identifier of the device for the network
●
The netid determines the network address while the hostid determines the host connected to that network.
●
In class A, one byte defines the netid and three bytes define the hostid.
●
In class B, two bytes define the netid and two bytes define the hostid.
●
In class C, three bytes definethe netid and one byte defines the hostid.
Q2 :
Solution:
●
a. First bit is 0. Thus, class A
●
b. First 2 bits are 1 and 3rd bit is 0. Thus, class C
●
c. First bit is 1 and second bit is 0. Thus, class B
●
d. First 4 bits are 1. Thus, class E
Subnets ●
To understand subnetting better let's look at a simple scenario.
●
A college has four departments: Information Technology, Computer Science,
●
Subnetting is a process of dividing a single network into multiple sub networks. Mechanical, and Civil.
●
When a bigger network is divided into smaller networks, to maintain security, then that
is known as Subnetting. ●
There are 50 students in each department.
●
The number of sub networks created depends upon the requirements. ●
The institution used a private class C IP network(with network ID 192.168.1.0).
Uses of Subnetting ●
All computers will work in a single huge network if there is no subnetting.
●
Maintenance is easier for smaller networks. For example, if we consider a class A
address, the possible number of hosts is 224 for each network, it is obvious that it is
●
It becomes complex for the institution admin to handle the task because if he
difficult to maintain such a huge number of hosts, but it would be quite easier to broadcasts some message to the system, it will forward to all the departments.
maintain if we divide the network into small parts. ●
To solve this type of problem, we use subnetting.
●
Subnetting helps in organizing the network in an efficient way which helps in
expanding the technology for large firms and companies.
●
Reduces traffic and maintain order and efficiency.
●
Reduces network complexity
●
Subnetting enhances the network's overall performance by removing redundant traffic.
●
Increases network security .
●
Simplified management
Types of Subnetting-
Summary:
●
How it works
– A subnet mask performs a logical AND operation with the destination IP address of the incoming
packet to determine the correct subnet to direct that packet.
●
How it's written 1. Fixed Length Subnetting-
– A subnet mask is initially written in binary format, with ones representing network bits and zeros Fixed length subnetting also called as classful subnetting divides the network into subnets where-
representing host bits.
– All the subnets are of same size.
●
The internal router will forward the packet to the network through an interface . The
interface will be identified by the routing table residing in the router. – All the subnets have equal number of hosts.
– Routing table
– All the subnets have same subnet mask.
●
If the network id doesn’t matches with any, then the packet will be sent to default entry.
●
Default entry has network id as 0.0.0.0. 2. Variable Length Subnetting-
Variable length subnetting also called as classless subnetting divides the network into subnets where-
Q5: If the subnet mask 255.255.255.128 belongs to class C, find- Q6:One needs to subnet a network that has 5 subnets , each with atleast 16
– a. Number of subnets hosts. Which of the following can be true?
– b. Number of hosts in each subnet
ANS:
Given subnet mask = 255.255.255.128
= 11111111.11111111.11111111.10000000
Number of Host ID bits = Number of 0’s = 7
It is given that subnet mask belongs to class C.
Ans:
So, Number of Net ID bits = 24 and Number of Subnet ID bits= 1
255.255.255.224 classful subnet mask can be used
Thus, Number of subnets = 21 = 2
Number of hosts per subnet = 27 – 2 = 126 hosts
Q7 : You currently use the default mask for your IP network 192.168.1.0. You need Step 3: Calculate the Number of Bits for Networks
to subnet your network so that you have 30 additional networks, and 4 hosts per ●
Next, calculate the number of bits needed for the networks. You need 30 networks:
network. Is this possible, and what subnet mask should you use? ●
2m ≥ Number of Networks, Where m is the number of bits for the networks.
ANS: ●
For 30 networks: 2m≥30
25=32 ⇒ m=5
Step 1: Calculate Hosts Required
●
Since you need 4 hosts per network, and you need to account for the network Step 4: Calculate Total Bits and Subnet Mask
and broadcast addresses, you actually need 6 addresses (4 usable + 2 reserved). ●
The default subnet mask for a Class C address (like 192.168.1.0) is 255.255.255.0,
Step 2: Calculate the Number of Bits for Hosts which uses 24 bits for the network.
●
You are using: 5 bits for networks and 3 bits for hosts
●
To find the number of bits needed for the hosts, use the formula:
2n−2 ≥ Number of Hosts, where n is the number of bits for the hosts.
●
The total number of bits used will be : 24+5=29 bits for the network
●
This leaves : 32−29=3 bits for hosts
●
For 6 addresses: 2n−2 ≥ 6
23−2 = 6 ⇒ n=3
●
So, you need 3 bits for the hosts Step 5: Determine the Subnet Mask
●
In decimal format, the subnet mask is: 255.255.255.248
Q8: You have sub-netted your class C network 192.168.1.0 with a subnet mask of 255.255.255.240. Q9: You have sub-netted your class C network 200.138.1.0 with a subnet mask of
Please list the following: 255.255.255.252. Please list the following: number of networks, number of hosts per
1. Number of networks network, the full range of the first three networks, and the usable address range from those
first three networks. Additionally, identify the broadcast addresses for each network
2. Number of hosts per network
3. The full range of the first three networks ANS:
4. The usable address range from those first three networks.
●
Number of networks = 64
ANS: ●
Number of hosts = 2
1. Number of networks = 16 ●
Full Range for first three networks:
2. Number of hosts = 14 200.138.1.0- 200.138.1.3
3. Full Range for first three networks: 200.138.1.4- 200.138.1.7
192.168.1.0-192.168.1.15 200.138.1.8- 200.138.1.11
192.168.1.16-192.168.1.31 ●
Usable Range for first three networks:
192.168.1.32-192.168.1.47 200.138.1.1-200.138.1.2
4. Usable Range for first three networks: 200.138.1.5-200.138.1.6
192.168.1.1- 192.168.1.14 200.138.1.9-200.138.1.10
192.168.1.17-192.168.1.30 ●
Broadcast Addresses for first three networks: 200.138.1.3, 200.138.1.7, 200.138.1.11
192.168.1.33-192.168.1.46
Q11: Subnet the Class C IP Address 195.1.1.0 So that you have 10 subnets each with a Q12: Subnet the Class C IP Address 205.11.2.0 so that you have 30 subnets.
maximum 12 hosts on each subnet. List the Address on host 1 on subnet 0,1,2,3,10
What is the subnet mask for the maximum number of hosts?
ANS:
How many hosts can each subnet have?
Current default mask= 255.255.255.0
What is the IP address of host 3 on subnet 2 ?
Subnet Bits needs for 10 subnets =4
So, no.of possible subnets = 2 4 =16 possible subnets ANS:
Current mask= 255.255.255.0
Host Bits needs for 12 hosts = 4
Bits needs for 30 subnets =5 since 25 =32 is the next possible no.of subnets
So, no.of possible hosts = 2 4 -2 = 16-2=14 possible hosts.
Bits left for hosts = 8-5= 3
So our mask in binary =11111111 11111111 11111111 11110000 ie, 255.255.255.240
Thus,no.of possible hosts = 23 -2 = 8-2 = 6 possible hosts.
Subnet 0 : host 1: IP address = 195.1.1.1 (0000 0001)
So our mask in binary =11111111 11111111 11111111 11111000
Subnet 1 : host 1: IP address = 195.1.1.17 (0001 0001)
Ie, Final Mask =255.255.255.248
Subnet 2 : host 1: IP address = 195.1.1.33 (0010 0001)
Address of host 3 on subnet 2 is
Subnet 3 : host 1: IP address = 195.1.1.49 (0011 0001)
Subnet 2 : Host 3 IP address = 205.11.2.19 (00010 011)
Subnet 10 : host 1: IP address =195.1.1.161 (1010 0001)
Advantages
●
Large Address Space: An IPv6 address is 128 bits long. Compared with the 32 bit address of IPv4,
this is a huge increase in the address space.
●
The IPv6 header is a crucial part of the IPv6 protocol, designed ●
Better Header Format: IPv6 uses a new header format in which options are separated from the
base header and inserted, when needed, between the base header and the upper layer data . This
to make data transmission more efficient and support the simplifies and speeds up the routing process because most of the options do not need to be checked
growing number of devices on the Internet. by routers.
●
New Options: IPv6 has new options to allow additional functionalities.
●
It includes fields like version, traffic class, flow label, payload ●
Allowance for extension: IPv6 is designed to allow the extension of the protocol if required by new
length, next header, hop limit, source address, and destination technologies or applications.
address. ●
Realtime Data Transmission: In IPv6,the type of service field has been removed, but two new
fields, traffic class and flow label have been added to enables the source to request special handling
●
These fields help to ensure that data is routed accurately and of the packet. This mechanism can be used to support traffic such as real-time audio and video.
– Example : Live streaming services such as cricket matches, or other tournament that are streamed on web
efficiently. exactly as soon as it happens with a maximum delay of 5-6 seconds.
●
Support For more Security: The encryption and authentication options in IPv6 provide
confidentiality and integrity of the packet.
Differences Between IPv4 Header and IPv6 Header Difference Between IPv4 and IPv6