How do servers communicate with only one other server at a time?

195 views

It’s my understanding that when a computer or a server needs to connect to another server connected to the internet, a ‘handshake’ needs to be performed so that they can share data, but how are two servers able to communicate without broadcasting all of their data to every other server connected to the internet as well?

In: 1

5 Answers

Anonymous 0 Comments

They have the address of the server they want to communicate with. This Internet address is known to the Internet service providers and they will route the data package containing the handshake one step closer to the server. When each router does this it eventually end up at the server. In addition to the destination address the package also contains the source address. So the server knows where to send the response to. And the ISPs will then know how to get the data back.

Anonymous 0 Comments

Routers.

Each server has an IP address. When server A wants to send a message to server B, it actually sends a message with B’s IP address to its nearest router. The router has a routing table – a list that says where to route each message according to the destination IP address. For example, it might say “if the IP address starts with a number between 0 and 127, send it to router X, and if it starts with 128-255 sends it to router Y”. The message is then bounced around between routers until it reaches the destination address.

And yes, the routers along the way can see all the data. That’s why, if the servers wants to communicate securely, they will create a secure session using TLS and encrypt the actual data.

Anonymous 0 Comments

it’s like this…

there’s a huge room and everyone has a bullhorn and everyone is able to hear everything. Initially, to communicate with another server, you just broadcast it via your bullhorn and everyone hears it. This slowed communications down because everyone would hear it, consider it’s message, and then decide if it’s applicable for them. So, instead, they setup a procedure in broadcasting the messages, with a “hey you, this is me, and this is my message, and this is the end of my message”. This way, everyone that hears the message can immediately dismiss it once they hear it’s not for them. Further more, for encrypted messages, they say ‘hey you, it’s me, lets start a secure line’ then he chunks a can & twine to the other guy, then they an talk securely with the cans & twine assembly.

That’s the basic gist of it. With each person being servers. Made more complicated, less of an accurate analogy if you consider that everyone actually has interconnecting wires that doesn’t always connect to each other directly, and the ‘hey you, its me’ standard also incorporates the direct path to the destination by each server having a ‘phone book’ of who is directly connected to who and a path can be determined as the most efficient path

Anonymous 0 Comments

Each server has an address on the network.

Each computer on the network has a list that says “if I get data meant for computer X, send it on to computer Y”. This list is called a “routing table”.

What’s more, the addresses are, like normal human addresses, broken into parts. So if the server is at [53.38.60.1](https://53.38.60.1), my computer doesn’t need to have the full routing table for the whole internet, it’s enough to know “right, anything starting with 53. gets sent in *that* direction.”, just like your local postal service doesn’t have to know where “P Sherman, 42 Wallaby Way, Sydney” is, they can just look at the “Sydney” part and say “right, that gets sent to the sorting centre at Los Angeles Airport.”

Yes, *some* computers besides the server get to see the message (which is why connecting to websites via https, rather than http, is important), but only about a few dozen instead of billions.

Anonymous 0 Comments

The Internet is almost exactly like the real-word physical postal system sending letters. Everything from the way mail is addressed to how it is carried to how it is processed through sorting facilities is uncannily similar to how the real Internet system functions.

When one server talks to another, they don’t broadcast their message for the entire Internet to hear for the same reason the whole world doesn’t read their mail when one business sends a letter to another. The message is a private letter. Barring the chance that someone on the inside of the “Internet postal system” (i e. the ISP) is intercepting the messages and reading them, that letter only gets sent to its intended recepient (the other server) and no one else opens it. With modern encryption, opening the message to peek probably wouldn’t even be helpful to an eavesdropper anyway. The little padlock in your web browser’s address bar is evidence of this kind of protection at work.

A server is not a special machine. At least, not from the perspective of the Internet. Sure, a rack server in a datacenter will be specially built to help it do the job of being a server, but to the Internet, every server is just another computer. They connect to and handshake with other servers the exact same way your computer would. Just like how, to the postal system, a business is just another address that can send and receive mail the same exact way you do at home.