TCP/IP model is a set of protocols which lay norms of how the internet works. It basically specifies the thumb rules of computer networking in 5 different layers. That’s why it is often referred as the Internet protocol suite. Now there are in fact other kinds of models too like the 7 layered OSI model, which are widely accepted but not as much as tcp/ip. tcp/ip is not a concept. It is just a command standard of classifying processes.
Layers of a TCP/IP Model
Let me explain it how Victor Manuel Escobedo from his coursera course about computer networking explained it. Imagine connecting to a device as sending a package to someone by a delivery truck(remember networking is all about sending and receiving data). The physical layer is the delivery truck, road and any physical thing involved. You can say- it represents every physical devices that interconnect computers. From the specification about wired / non – wired signals along with the cables used.
Data Link Layer
The data link layer defines way how the data/signals can be interpreted by the devices whereas, at the physical layer, everything was all about cables and signals. So you might say its sole purpose is to convert radio signals and electric pulses into meaning full data than can be understood by the computer . Thought it is more than that. It also specifies which device the data is intended for in a simple network(LAN).
This is also where the first protocols are introduced- mainly ethernet, which specifies how mac address can be used in a LAN to transfer data. So while the physical layer was trucks and roads, the data link layer how the truck moves from one intersection to the other.
The network layer, also called the INTERNET layer does something very similar to what it sounds like. It uses protocols to find the target system in the internet mainly by IP address. You might remember that a collection of Networks formed by using many routers is called the internet. Using the IP address of the destined device, many router transfer the data by using their internal stored memory about that LANs and devices they are connected to. This is exactly hence the most important part of the tcp/ip model.
So the networks layer is the map the truck driver uses to deliver the package. If the destination is not in the town, he will have to pass it to another truck which is at the other town.
The destined device may be running a specific type of program or application from where it is expecting the data to be. Like it could be email application or whatsapp etc. While the network layer has successfully delivered the data to the device, the transport layer tells which application on the device it should reach.
So it basically makes sure your delivery driver knows the package should be kept in front of the door, not the trash can.
The last layer, the application layer as it sound like represents the application and the interface used to send / receive data request, and the data itself. These also include the protocols you might be most familiar with like ftp(file transfer protocol), https, http, ssh etc.
So it might be the box or whatever you used to pack the data and how the package is seen by the addressee.
Everything in action
Alright lets take a serious practical example and dissect it using out tcp/ip model. Lets say you are trying to open a video in Youtube. As you click the video, it send a request message to the youtube server . This request message is sent to the youtube server by using its ip address configured by something called dns server).
In addition to the diagram, you might also see a dhcp server. Well a dhcp server is nothing but a server which assigns your device an ip address. Well today, in most cases, dhcp(dynamic host configuration protocol) is already a thing in the home router. And that’s the same case with dns servers
The request data goes through many routers and finally reaches the YouTube server on its request application or something. Then it sends back the requested data( video) to you by seeing the client’s ip address. the same process repeats and you get your video in the youtube application.
Although this NOT exactly how it works, many other things are also involved in it. But I guess it will clear all the basics about tcp/ip.