Let's say you have a brand new 192.168.1.0/24 network that consists of a router, switch and two hosts (H1 and H2).
H1 would like to communicate with H2, but since this is a brand new network and no communication has never taken place before, how does H1 even know that H2 exits?
I understand that initially, the two hosts would not be aware of each other's IP addresses. I also understand that after a host becomes aware of another host's IP address and determines that it is on the same LAN, it can simply ARP to discover another host's MAC address. I'm just struggling to grasp how one host initially discovers the existence of other locally connected devices.
The answer to the question Found Here talks about the role of DNS, but I still don't understand how H1 would know the name of H2 to even ask the DNS server about what IP address belongs to a given name. Is there some sort of protocol/service that enables hosts existing on the same LAN/VLAN to know about all other hosts connected to that same LAN/VLAN?
In smaller networks that don't utilize a local DNS server, is this accomplished by NetBIOS? I'd be interested to also understand how this 'discovery' process works in this type of environment as well.
Thanks head of time!