Jump to content

USE HOSTS FIRST: Difference between revisions

From EDM2
Created page with "If USE_HOSTS_FIRST is set up, TCP/IP will first look in the local file ..\Etc\Hosts for the dotted IP address for a specific Hostname on the internet. Whenever you connect to..."
 
Ak120 (talk | contribs)
mNo edit summary
Line 1: Line 1:
If USE_HOSTS_FIRST is set up, TCP/IP will first look in the local file ..\Etc\Hosts for the dotted IP address for a specific Hostname on the internet.
{{DISPLAYTITLE:USE_HOSTS_FIRST}}
If USE_HOSTS_FIRST is set up, TCP/IP will first look in the local file <tt>%[[ETC]]%\HOSTS</tt> for the dotted IP address for a specific hostname on the internet.


Whenever you connect to the internet and you access a host (for example http://www.netlabs.org), your browser must know the dotted IP address (for example 195.65.67.48) for the host. So the browser contact a Domain name Server (DNS) and ask for the IP address. This takes some time, to speed up internet connection you can define in the Hosts file the hostnames and the IP addresses.
Whenever you connect to the internet and you access a host (for example http://www.netlabs.org), clients must know the dotted IP address (for example 195.65.67.48) for the host. So clients contact a domain name Server (DNS) and ask for the IP address. This takes some time, to speed up internet connection you can define in the Hosts file the hostnames and the IP addresses.


OS/2 will only use Hosts file if USE_HOSTS_FIRST is set to 1. You can define all kind of hosts www-server, mail-server, news-server, ftp-server or whatever else. To get the IP address for a host type "host" and the hostname in an OS/2 window. The actual Path for the host file is defined by the ETC environment variable.
OS/2 will only use Hosts file if USE_HOSTS_FIRST is set to 1. To get the IP address for a host type "host" and the hostname in an OS/2 window. The actual search path to the HOSTS file is defined by the ETC environment variable.


  SET USE_HOSTS_FIRST=<value>
  SET USE_HOSTS_FIRST=<value>
;Parameter
;;Value: 1 will check the HOSTS file first.


;Example:
;Example:
  SET USE_HOSTS_FIRST=1
  SET USE_HOSTS_FIRST=1
==Parameters==
;Value: 1 will check the host files first.


[[Category:Environment variable]]
[[Category:Environment variable]]

Revision as of 01:06, 21 November 2017

If USE_HOSTS_FIRST is set up, TCP/IP will first look in the local file %ETC%\HOSTS for the dotted IP address for a specific hostname on the internet.

Whenever you connect to the internet and you access a host (for example http://www.netlabs.org), clients must know the dotted IP address (for example 195.65.67.48) for the host. So clients contact a domain name Server (DNS) and ask for the IP address. This takes some time, to speed up internet connection you can define in the Hosts file the hostnames and the IP addresses.

OS/2 will only use Hosts file if USE_HOSTS_FIRST is set to 1. To get the IP address for a host type "host" and the hostname in an OS/2 window. The actual search path to the HOSTS file is defined by the ETC environment variable.

SET USE_HOSTS_FIRST=<value>
Parameter
Value
1 will check the HOSTS file first.
Example
SET USE_HOSTS_FIRST=1