Windows XP Domain name resolution File

Source: Internet
Author: User

c: \ windows \ system32 \ drivers \ etc \ hosts

# copyright (c) 1993-1999 Microsoft Corp.
#< br> # 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 shoshould be kept on an individual line. the IP address shocould
# be placed in the first column followed by the corresponding host name.
# the IP address and the host name shocould 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.
#< BR ># For example:
#< br> #102.54.94.97 rhino.acme.com # source server
#38.25.63.10 x.acme.com # X client host

127.0.0.1 localhost

127.0.0.1 activate.adobe.com

192.168.0.250 www.fish.com

 

it is a domain name resolution file.
you can open it directly in notepad. Redirects an IP address.
Format: IP address-space-domain name
You can redirect a domain name to an IP address.
the following can be achieved:
1. accelerate domain name resolution
for websites that require frequent access, we can configure the ing between the domain name and IP address in hosts so that when we enter the domain name computer, we can quickly resolve the IP address, instead of requesting DNS servers on the network.
2. convenience for LAN users
in the LAN of many organizations, servers are provided to users. However, because DNS servers are rarely set up in Lan, it is quite troublesome for many people to access these services to enter hard-to-remember IP addresses. Now we can give these servers an easy-to-remember name, and then create an IP ing in hosts. In this way, we can enter the name of this server for future access.
3. blocking websites
many websites install various plug-ins on your computer without your consent. Some may be Trojans or viruses. For these websites, we can use hosts to map the Domain Name of the website to the wrong IP address or the IP address of our computer, so that no access is required. For example, if you do not want to access www.xxxx.com, write the following content in hosts:
127.0.0.1 www.xxxx.com # blocked website
0.0.0.0 www.xxxx.com # blocked website
in this way, the computer resolves the domain name to the local machine or wrong IP address, achieving the purpose of blocking.
4. Smoothly connect to the System
for Lotus servers and some database servers, if you enter an IP address directly during access, it cannot be accessed. Only the server name can be entered for access. Then we configure the hosts file so that the server name can be successfully connected.
it should be noted that the hosting configured in the hosts file is static. If the computer on the network changes, update the IP address in time. Otherwise, the host cannot be accessed.
5. force a domain name to correspond to an IP address
In addition, virus often blocks some anti-virus software websites by modifying it, or stop the anti-virus software upgrade (some anti-virus software upgrades are to download the Program package from a specified website, so that the download fails). Therefore, numerous security software also provide hosts repair functions (such as Kaka)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.