In this series of blog posts , I am going to write everything I know about IP addresses.
What the heck is an IP address?
Let me begin with an analogy. Everyone in a class room is given roll numbers ranging from 1 to the total number of students.
Suppose there are 40 students in a classroom. Class teacher might assign roll numbers to the students alphabetically or through other criteria.
Roll numbers are assigned to the students so that they can be tracked by the class teacher for better and efficient communication. It is used as an attendance mechanism to check if the particular student has come to the class or not. Or for various other reasons.
Consider students and teacher as a part of human network. Teacher is the one who assigns roll numbers to the students and students use that roll number to communicate with the teacher for various things like attendance, mark sheets and other stuff.
Similarly in a computer network every devices connected get an IP address. Here in this case router is the teacher who assigns IP addresses to its students or network devices(mobile phone, tablet , laptop, printer etc).
Router assigns IP addresses to all devices in a network so that those devices can talk to router in some ways or vice-versa.
To conclude the definiton , IP address is a unique number assigned to the devices connected in a network. Notice why I have used unique number. I will get back to it soon.
What does an IP address look like?
IP addresses look like
1) 192.168.1.1 (IP v4)
2) 0:0:0:0:0:ffff:d1ad:35a7 (IP v6)
There are different types of IP addresses which I will get back to in upcoming posts of this series.
Can two devices have a same IP address?
Getting back to the analogy what if two students are assigned the same roll number? There will be conflicts. Teacher asks if the roll number 5 is present or not and both of the students respond to the teacher. So two students can’t be assigned the same roll number. Similarly if the router happens to assign the same IP address to two different devices then there will be conflicts.
So, the answer is ‘NO’. Each devices get a unique IP address. However, a device can have multiple ip addresses assigned to it.
Does router also have an IP address?
Yes, router also has an IP address.
How does router assign IP addresses?
Router assigns IP addresses through a Dynamic Host Configuration Protocol(DHCP). I will cover about DHCP later.
In the upcoming blog post of this series , I will try to cover the types of IP addresses . I will try to cover more of technical portions in later posts.