Question : Not able to Ping / Connect by host name but can connect using IP

I am not  able to Ping / Connect by hostname but can connect using IP.
I have planced all entries in C:\WINDOWS\system32\drivers\etc\hosts file.

My Host file is as below

# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
#      102.54.94.97     rhino.acme.com          # source server
#       38.25.63.10     x.acme.com              # x client host
127.0.0.1       localhost
10.1253.27.15       DEVConfigurationWS  

can anyone  figure out what could be wrong  ?

Answer : Not able to Ping / Connect by host name but can connect using IP

Though it will work the Hosts file is for DNS names like
10.253.27.37       DEVConfigurationWS.local
You are best to use the LMHosts file, in the same location for NetBIOS names.
Below are explained some of the oddities of the file and how to use it. For the record any line starting with # can be removed if you like it is just a comment.

Let us know if you have a domain, as LMHosts/Hosts files should not be needed, perhaps there is an other issue we can help with.

Setting up an LMHosts file.
-Lmhosts file is useful for NetBIOS name resolution where other solutions are not available.
-LMHosts is located in the Windows directory under c:\Windows (or WINNT)\System32\Drivers\Etc\LMHosts.sam , instructions are included within the file. Any line starting with # is just a comment and is ignored. Open the file with Notepad and add entries for your computers as below;
192.168.0.101      CompName       #PRE
-Hit enter when each line is complete (important), then save the file without a file extension. To be sure there is no extension ,when saving enclose in quotations like "LMHosts".
-PRE has to be capitalized, however you do not need it, though should give you faster resolution where it is "pre-loaded"
-use a Tab between entries in a line rather than spaces (recommended but not necessary)
-if adding the domain and or domain controller the # of spaces used is even critical. See:
http://support.microsoft.com/kb/q180094/

see also:
http://www.microsoft.com/technet/prodtechnol/windows2000serv/reskit/cnet/cnfd_lmh_qxqq.mspx?mfr=true
ps- To check your LMHosts file entries are accepted at a command prompt enter
  nbtstat  -R
which will purge and reload the local name cache
then enter
  nbtstat  -c
to display the current name cache which should include your LMHosts file entries.
Note; the nbtstat "switches" R & c are case sensitive.
The names will only show up if you used the 'PRE' option, or if not, if you have used the name with a ping or similar command enabling them to be cached.
Random Solutions  
 
programming4us programming4us