Explain the concept of local DNS caching in terms of perform
Solution
Even though the communication only takes up a few hundred milliseconds each time a message is sent, these can add up over time, as the number of requests can easily reach hundreds or thousands of DNS queries. DNS servers can sometimes be unavailable and the responses to queries can be very slow.
An easy way to speed up this process is to cache the information locally thereby eliminating the need for repetitive queries to the remote DNS server. This is done by telling PostCast Server to contact a local database on your computer, rather than the remote DNS server. This local connection can be performed much faster and does not depend on the response time of the remote DNS server across the Internet.
PostCast Server contacts the remote DNS server once, and then caches (memorizes) the addresses returned from the query. So the next time you are requesting the same domain.com address, it instantly returns the answer, without having to contact your ISP\'s DNS server to ask it for the translation. The process is much faster, since it does not have to connect to any remote servers every time.Almost every request a computer sends over over the internet relies on DNS to resolve a hostname to an IP address.
Performance -As a result internet performance can be severely reduced if the computers on your network use slow, or overloaded DNS servers.
Local DNS caching improve performance by acting as a local caching DNS server.The local cache has the ability to respond to DNS queries faster than any server outside of your network.
Flexibility-The advantage of this system is that it can give you the advantage of a locally accessible cache while not having to do the recursive work (which can result in additional network traffic and can take up substantial resources on high traffic servers). This can also lead to some interesting flexibility in splitting your private and public traffic by forwarding to different servers.
Timeout-When you visit a website or access another computer on the network, the Windows Operating System will use a DNS Server to translate the hostname into an IP address. Since you may be accessing that resource more than once, the hostname and IP address information is stored in your computer’s DNS Resolve Cache to speed up the process the next time you access that resource.
- The amount of time that the hostname and IP address is stored in cache on the local computer is dependent on two things. The first is the TTL, or Time-To-Live value that was assigned to the record stored in the DNS authoritative zone, and the other is the default maximum value that your operating system is configured cache the results. Both of these numbers are compared and the smaller of the two is the one that is used to timestamp the record in your cache. For example, the default maximum time that Windows XP uses is 24 hours
2)TCP uses 4 tuples (src ip, src port , dest ip, dest port) to perform the multiplexing/demultiplexing The destination ip/port is needed for obvious reasons on the source machine because that defines where the packets are to go. You could close one TCP connection and open a new outbound one from the same local port but to a different destination so it\'s important to be able to differentiate them.
As for the destination machine, remember that it can have multiple network interfaces. The IP address of each interface is different even though the \"port space\" is likely the same. A connection to one interface is distinct from a connection to another interface even if they access the same port.
From a TCP point-of-view with it\'s stateful sessions, there is some redundancy. You could probably omit the destination IP from the tuple and still uniquely identify the established session. The tuple, though, is used for routing at the network layer and there is no guarantee that other protocols will not need the added disambiguation.
In TCP, the receiver host uses all of source IP, source port, destination IP and destination port to direct datagram to appropriate socket.
