Wednesday, July 27, 2011

DNS and DNS flushing in Ubuntu

The Domain Name System (DNS) is a hierarchical naming system built on a distributed database for computers, services, or any resource connected to the Internet or a private network. Most importantly, it translates domain names meaningful to humans into the numerical identifiers associated with networking equipment for the purpose of locating and addressing these devices worldwide. (Wikipedia)

Translating URL's to point at the IP addresses of servers is an important portion of the Internet browsing. There could be multiple levels of DNS resolutions happening to expedite the browsing experience of users.

On a GNU/Linux machine, if the user is aware of the URL and IP address of a host, he/she can make a manual DNS entry on the /etc/hosts file.


To view and add the DNS servers the host machine is using, the file to look at is
/etc/resolv.conf

Further, caching the DNS entries ( mapping of URL's to IP addresses) is a feature used to avoid the repeated Domain Name resolution iterations. But sometimes, when a single URL points to multiple servers ( like google mail etc..), and when secure sessions on different servers are established the chances that one of the servers would not resolve might occur.


During such instances, the DNS cache has to be flushed. The first and simple command which has to be manually run to flush the DNS cache is dns-clean.
It can be invoked by the following command:

raghu@fossphosis:~$ sudo /etc/init.d/dns-clean


But, repetitive invoking of this command might get on to the nerves of the users, and a daemon to automate this task is NSCD (Name Server Cache Daemon).
NSCD automates the DNS table flushing and refreshing process at the back end.
NSCD on Ubuntu can be installed by the following apt-get command.

raghu@fossphosis:~$ sudo apt-get install nscd

Fine tuning of the refresh rate and time-to-live of the DNS entries can be altered by changing the values in the configuration file /etc/nscd.conf

Wednesday, July 6, 2011

FSMK Newsletter Revamped and back!

FSMK Newsletter is back, and will get better.


Please share and spread this Newsletter to as many people as possible.
For, Sharing is Growing :)

Do send in your articles for the coming editions...

http://www.fsmk.org/node/79

http://fsmk.org/sites/default/files/FSMK_Issue8_July_2011.pdf