Contents: MDGx HOSTS Files + Tools
HOSTS Guide
IMPORTANT
HOSTS Usage
HOSTS Links
The HOSTS file can be used to block adware, spyware, malware, viruses, trojans, worms + popups in all your ftp/web browsers/tools and internet/network tools by denying access to a list of internet domains/servers/web sites.
Here are my HOSTS files (updated frequently = April 27 2008) with > 128,000 host name entries:
MDGx HOSTS Files = Automated EXE Installers:
IMPORTANT:
You may need to be logged on with Administrative/Power User privileges to be allowed to
copy/delete/install/move/rename/replace/uninstall files/folders!
Both HOSTS0.EXE + HOSTS127.EXE copy the new HOSTS file to:
How to remove MDGx HOSTS file + restore your original HOSTS file from HOSTS.ORI (if
any):
Start button -> Settings -> Control Panel -> Add/Remove Programs -> select "Remove MDGx HOSTS +
Restore Original HOSTS" -> click Add/Remove button.
Both HOSTS0.EXE + HOSTS127.EXE can be opened and their contents can be extracted/viewed using any unZIPping tool that supports the ZIP format [most are free(ware)].
CREDITS:
Both HOSTS0.EXE + HOSTS127.EXE created with MakeSFX.exe ZIP self-extractor command line tool for all 32-bit Windows
(Win32) editions [free, open source].
MDGx HOSTS Files = ZIP Archive:
IMPORTANT:
You may need to be
logged on with Administrative/Power User privileges to be allowed to copy/delete/install/move/rename/replace/uninstall
files/folders!
How to install 1 of the HOSTS files from HOSTS.ZIP:
REN HOSTS0 HOSTS
or:
REN HOSTS127 HOSTS
After that, copy this new HOSTS file (overwritting the existing one, if any) to:
HOSTS.ZIP also contains HOSTS.HTM, which you can run to display MDGx HOSTS Files, Guides + Tools (this web page).
Useful HOSTS tools I recommend [100% free(ware)]:
HOSTS (case insensitive in Windows OSes) or hosts (must be lower case in *nix OSes) is an ASCII (plain text) file used by TCP/IP protocol for
BSD/FreeBSD/Linux/Solaris/UNIX, BeOS, MacOS, OS/2, Novell Netware + Windows Operating Systems.
Acts as TCP/IP (Transport
Control Protocol/Internet Protocol) host table and contains a list of address-to-name resolution mappings of numeric IP
(Internet Protocol) addresses (32-bit identifiers) resolved to valid host names.
Operates as a local DNS (Domain Naming
System) server by translating a UNC (Universal Naming Convention) domain name into an IP address, thus decreasing the time
necessary to reach a remote server.
Never map an IP to a host name already in use, for example your ISP (Internet Service
Provider) name or your favorite web site(s) name(s).
Never rename this file, it must be HOSTS or hosts without extension.
To properly use HOSTS in Windows 32-bit (Win32/x86) + 64-bit (Win64/x64) OSes you must make sure Enable DNS is turned ON: Control Panel -> Network -> your TCP/IP adapter name (if more than 1 must do this for ALL) -> TCP/IP Properties -> DNS Configuration tab -> check Enable DNS box -> click Apply/OK button.
Microsoft Windows Host Name Resolution over TCP/IP search order:
You can
view/edit your HOSTS file using Notepad or better text/ASCII editor/viewer, especially
if your HOSTS file is larger than 64 KB.
Each entry must be kept on its own (separate) line.
Entries are almost always
case sensitive.
Each IP address must be placed 1st separated by at least 1 space or Tab from corresponding host (machine)
name, which must be placed 2nd on the same line.
Insert any optional comments on the same line after the host name (or on
separate lines) preceded by a # symbol and followed (optionally) by at least 1 space or Tab (examples):
|
|---|
This must be the 1st HOSTS line:
127.0.0.1 localhost
If more than 1 localhost lines, the 1st one overrides all others.
Each host name entry is limited to a maximum of 255 characters.
NEVER rename/modify/delete/comment/remark this HOSTS line:
127.0.0.1 localhost
The hosts file must reside in: [%windir% = usually C:\WINDOWS (3.xx/95/98/ME + 2000/XP/2003/Vista/2008) or C:\WINNT (NT/2000)]
In Windows 2000/XP/2003/Vista/2008 DNS Client service (if
enabled) loads the entire contents of the existing HOSTS file (if any) into the DNS cache, which may slow down the computer,
especially if using a (very) large HOSTS file.
You have 2 choices here:
SC CONFIG DNSCache
START= demand
and:
SC STOP DNSCache
or:
NET STOP DNSCache
To set DNS Client to Disabled (if not needed), run these 2 commands from a DOS console or a batch file:
SC CONFIG DNSCache START=
disabled
and:
SC STOP DNSCache
or:
NET STOP DNSCache
To determine if you need to have DNS Client service enabled: Start button ->
Run... box -> type services.msc -> click OK or press Enter -> open DNS Client -> Status column
-> should state Started (if needed) or should be empty (if not needed).
More info:
CAUTION:
Stop/Disable DNS
Client service ONLY if NOT connected to/part of a network/domain.
If connected to/part of a network/domain, DNS Client
service may be necessary for proper operation.
More info:
IPCONFIG /flushdns
More info @ MSKB.
In
case you are running ANY network/server on your local computer, you MUST edit your HOSTS file using
Notepad or better text/ASCII editor/viewer and change ALL 127.0.0.1 entries
(except the 127.0.0.1 localhost line) to read 0 (or
0.0.0.0).
Restart or log back into your network/server when done.
Otherwise you might get a huge number of login
popup prompts while trying to access the local server/network, because localhost is always located at the
127.0.0.1 IP address.
In case you cannot access an internet site/server, and if your web browser/e-mail client/ftp client/network tool returns a message/page/screen similar to (depending on the web browser/client/tool used):
In case Internet Explorer web browser does NOT allow you to save a web page, and you get this error message (or similar):
this may be due to 1 or more 0 (0.0.0.0 abbreviated) or 127.0.0.1
entry/entries into your HOSTS file associated with 1 or more of the internet site(s)/server(s) you are trying to save that
web page from.
To temporarily access that/those particular internet site(s)/server(s) and be able to save it/them properly as web page:
FYI:
If you don't understand some of
these abbreviations/acronyms/terms, please look them up.
ping microsoft.com
which returns this screen:
Pinging microsoft.com [207.46.130.108] with 32 bytes of data...
Then add this IP followed by its host name to your HOSTS file (example):
207.46.130.108 microsoft.com # Microsoft
PING.EXE is installed by default by all Windows 32-bit (Win32/x86) + 64-bit
(Win64/x64) OSes in %windir% [95/98/ME = 9x OSes] or %windir%\SYSTEM32 [NT4/2000/XP/2003/Vista/2008 = NTx OSes].
Run:
ping
by itself to display all available command line parameters.
Some internet/network servers use dynamic IP addresses, meaning the numbers change periodically or every time you try to access them. Therefore you may need to ping the same server more than once at different times, and then add ALL IP numbers found for that server, followed by its host/web site name (see example above) on separate lines into your HOSTS file.
HOSTS as ad, malware + popup blocker:
STRONGLY RECOMMENDED:
Install + run a dedicated firewall, anti-spyware + anti-virus tools in order to monitor for, detect and remove any potential
malware/spyware.
Block (deny access to and from) any host (force that server to default to localhost IP) by preceding its name with 0.0.0.0 (null = can be abbreviated to 0) or 127.0.0.1 (localhost = loopback). This example:
0.0.0.0 microsoft.com
or abbreviated to (faster):
0 microsoft.com
or (slower):
127.0.0.1 microsoft.com
denies access to and from microsoft.com domain name.
See MDGx HOSTS
files for a list of blocked servers.
Rename all your HOSTS file 0.0.0.0 (or abbreviated to 0)
instances to 127.0.0.1 (or the other way around) if too slow or if not working.
NEVER rename/modify/delete/comment/remark this HOSTS line:
127.0.0.1 localhost
Surf the internet safely... ![]()
HOSTS Guides + Free(ware) Tools on the Internet: