Rakesh Jain Profile picture
Jan 18 β€’ 28 tweets β€’ 7 min read
Network Fundamentals -
Basics of Network IP Addressing

A Detailed Thread πŸ‘‡ PC: https://www.webopedia.com/wp-content/uploads/2021/08/DRL
Basics of IP Addressing in Linux -

Each device connected to the internet has a unique identifier knows as an IP Address.

An IP address is a 32-bit binary number that is assigned to a computing device such as a PC, Tablet, or smartphone in an IP network. PC: https://img.webnots.com/2018/12/What-is-IP-Address.jpg
Most of the networks today, including all computers on the internet uses the TCP/IP as a standard to communicate with each other.

In the TCP/IP protocol, this unique identifier is the IP Address. The two kinds of IP Addresses are IPv4 and IPv6. PC: https://heydaytechie.com/wp-content/uploads/2020/10/tcp_
When devices communicate with each other over a local area nw, or "LAN", or across the internet, the message transmitted is ultimately directed to the target device's nw hw address that is programmed into the device by the manufacturer. PC: https://i1.wp.com/learntomato.flashrouters.com/wp-conten
Unfortunately, MAC's r not helpful 4 routing comm'n msgs outside of a small no. of locally interconnected devices bcz dey r randomly scattered arnd d world, i.e, a device wid a MAC addr of 10:20:30:40:50:60 cud be in Delhi & anthr wid mac addr of 10:20:30:40:50:61 cud be in Seoul
To enable devices to find each other easily no matter where dey r in d world, d creators of d Internet came up wid a logical addressing scheme dat made it much easier for devices to find each other. These logical, Internet Protocol, addresses r commonly referred to as "IP addrs".
IP Terminologies -

Bit - This is a single digit, represented either as 1 or 0
Byte - This is a collection or series of 8 bits. 1 byte = 8 bits
Octet - An octet comprises 8 bits or 1 byte

An IP address is segmented into 4 octets or bytes. Each octet has 8 bits.
As IP address can be depicted in the following ways:

Dotted-decimal form -
For example 192.168.1.5

Binary form - 11000000.10101000.00000001.00000101.

Hexadecimal form -
c0.a8.01.05.

All the above notations represent the same IP address.
The hexadecimal format is rarely used. PC: https://newtheblogger.files.wordpress.com/2018/05/images
Classful Routing -

Message routing devices or "routers" that transfer messages from one organization to another use a highly structured method of IP addressing called "classful routing", where IP address ranges are grouped into five classes.
IP Classes -

Typically, the IPv4 space allows us to hv addrs b/n 0.0.0.0 to 255.255.255.255. Hwevr, some no's in dat range r reserved 4 specific purposes on TCP/IP nw's.

These reservations r recognized by TCP/IP addressing Authority the Internet Assigned Numbers Authority IANA
0.0.0.0 β€” This represents the default network, which is the abstract concept of just being connected to a TCP/IP network.
255.255.255.255 β€” This address is reserved for network broadcasts, or messages that should go to all computers on the network.
127.0.0.1 - This is called d loopback addr, meaning ur device's way of identifying itself, whether or not it has an IP addr.

169.254.0.1 to 169.254.255.254 - This is d Automatic Private IP Addressing (APIPA) range of addr's assigned automatically wen a device doesn't get dhcp ip PC: data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAS0AAACnCA
IPv4 address can be categorized into 5 classes:
Class A
Class B
Class C
Class D
Class E

Class A, B, and C which are mostly used in host systems.
Class D is used for multicast and E is mostly for research and experimental purposes. PC: https://embeddedgeeks.com/wp-content/uploads/2020/06/ip_
Class A. This is the biggest class boasting of 16,777,216 IP addresses that can be assigned to hosts and the least number of assignable networks which are 126 by default. PC: https://www.gatevidyalay.com/wp-content/uploads/2018/09/
Use-

Class A is used by organizations requiring very large size networks like NASA, Pentagon etc.
Class B which has the second-highest number of possible IP addresses which are 65,534 and 16,384 assignable networks by default. PC: https://www.gatevidyalay.com/wp-content/uploads/2018/09/
Use -

Class B is used by organizations requiring medium size networks like IRCTC, banks etc.
Class C which is the smallest class yielding only 254 possible IP addresses and 2,097,152 assignable networks by default. PC: https://www.gatevidyalay.com/wp-content/uploads/2018/09/
Use-

Class C is used by organizations requiring small to medium size networks.

For example- engineering colleges, small universities, small offices etc.
All the classes of IP Address are summarized in the following table-
Classless Inter-Domain Routing (CIDR) -
D no. of class "A", "B" and "C" IP addr ranges is severely limited, so wen an org obtains an IP addr range, dey usually obtain a number of class "C" ranges, or if dey r lucky, a class "B". Obtaining a class "A" addr range is highly unlikely
Fortunately, the development of d Classless Inter-Domain Routing (CIDR) method of IP addressing & routing gave org's d opportunity to easily segregate any of their classful IP addr ranges or "networks" into a number of sub-ranges or "subnets" through d use of "subnet masks".
Subnet masks -
Each Internet router dat uses classful routing knows dat any IP addr starting with 0-127 is a class "A" addr with a nw identifying component 1 byte in length. Any IP addr beginning wid 128-191 is a class "B" addr, so d nw component is two bytes in length, etc.
But when an org'n needs to break up its class "A" or class "B" nw into a number of class "C"- or other smaller-sized subnets, its routers cannot rely on the initial byte of d IP addr to tell it anything about the length of the network identifying component of the subnetted addrs.
To provide the routers with this information when using classless routing, you must specify the length of the network identifying component of the subnet's IP addresses through the use of a "subnet mask". PC: https://www.freecodecamp.org/news/content/images/2021/04
CIDR notation -
Since many of us r not very efficient binary calculators, CIDR provides a simpler method of expressing d mask merely by indicating the nw addr (i.e d first addr in d IP addr range) followed by a slash & d no of bits dat r in d nw identifying component of d IP addr PC: https://matt-rickard.com/content/images/2021/09/image-12
Routable address vs. Non-routable addresses -

Were we to give every device in the world its own unique IP addr, we would have run out of addresses a long time ago.
So Internet Engineering Task Force (IETF) decided dat, since most devices only need to be accessed within their org & never need to be accessed remotely, dey would reserve ranges of addrs dat every org can use for their internal device-to-internal device communication traffic. PC: https://3.bp.blogspot.com/-LGh7k2Ga6V4/W91Hsj4i0lI/AAAAA

β€’ β€’ β€’

Missing some Tweet in this thread? You can try to force a refresh
γ€€

Keep Current with Rakesh Jain

Rakesh Jain Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @devops_tech

Jan 4
Linux Diagnostics and Troubleshooting Series -

Thread 1 πŸ‘‡

Understanding what Troubleshooting is!

#Linux #diagnostics #troubleshooting #security
What is troubleshooting?

Troubleshooting is the art of taking a problem, gathering information about it, analyzing it, and finally solving it.

While some problems are inherently β€œharder” than others, the same basic approach can be taken for every problem. PC: https://knowmax.ai/wp-content/uploads/2020/09/Troublesho
Not just fixing!

While fixing a problem is one of the major parts of troubleshooting, there are other parts that cannot be neglected: documenting the problem (and fix), and performing a root cause analysis (RCA). PC: https://knowmax.ai/wp-content/uploads/2020/09/Troublesho
Read 16 tweets
Dec 18, 2021
What are different Process states in Linux!

What is a Zombie Process!

How to Clean a Linux Zombie Process!

A Thread πŸ‘‡ PC: https://store-images.s-microsoft.com
What Is a Zombie Process?

Zombie processes in Linux are sometimes also referred to as defunct or dead processes. They’re processes that have completed their execution, but their entries are not removed from the process table. PC: https://totozhang.github.io/
What are different Process States?

Linux maintains a process table of all the processes running, along with their states. Let’s briefly overview the various process states: PC: https://miro.medium.com/max/642/1*IaPYYJt9tXFvDnLeWNuVbw
Read 20 tweets
Nov 30, 2021
What is systemd and why should Linux users care about it?

Everything about "systemd" !!

A Mega Thread πŸ‘‡ https://everyday.codes/
What is systemd ?

systemd is the glue that holds Linux systems together. systemd is a collection of building blocks, which handle services, processes, logging, network connectivity and even authentication. PC: https://images.techhive.com/ & ZDNet
systemd handles the boot process for Linux systems. As an init implementation, it has a PID of 1 like other init systems, such as System V, Upstart.

It was designed as a replacement for SystemV and LSB-style startup scrips, which were prevalent since 1980s.
Read 44 tweets
Nov 19, 2021
#Linux Boot Process Explained!

A Thread πŸ‘‡ PC: https://images.wallpapersden.com/
Every Linux Admin or DevOps Engineer should know what happens when a Linux system boots. It's a very popular Interview Question as well.
Every time you power on your Linux PC, it goes through a series of stages before finally displaying a login screen that prompts for your username or password.

There are 3 high level stages of a typical Linux boot process.
Read 20 tweets
Oct 29, 2021
Everything you need to know about Virtualization, VMs , Containers, Pods, Clusters ..

A Mega Thread πŸ‘‡ PC: production-cci-com.imgix.net
What is Virtualization?

Virtualization is the act of dividing shared computational resources: CPU, RAM, Disk, and Networking into isolated resources that are unaware of the original shared scope. PC: cloud4y
What is a virtual machine?

A VM is a virtual env that functions as a virtual computer system with its own CPU, memory, nw interface, & storage, created on a physical hw system (located off- or on-prem).

It uses sw instead of a physical computer to run programs & deploy apps. PC: nakivo
Read 26 tweets
Oct 27, 2021
Traceroute: A computer Network Diagnostic Tool πŸ› οΈ

How does it work! πŸ€”

Ping works fine but not traceroute! 🀨

What are the stars in traceroute output! *⃣*⃣*⃣

#Linux #Networking

A Thread πŸ‘‡ PC: n-able.com
What is traceroute ?

traceroute tracks the route packets take across an IP network on their way to a given host.

It assists you in troubleshooting nw connectivity issues from your Destination to a Remote destination by using echo packets (ICMP) to visually trace the route.
The syntax -

The cmd traceroute <x> (x here being an IP or hostname) is d most basic version & it will begin to send packets to d designated target. This result will allow u to trace d path of d packets sent from ur machine to each of d systems b/n u & ur desired destination.
Read 22 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us on Twitter!

:(