0 votes
79 views
in Domain and DNS by
How to do host entry method in Windows system

1 Answer

0 votes
by

To add a host entry in Windows, you can follow these steps:

  1. Open Notepad or any other text editor with administrator privileges. To do this, right-click on the text editor application and select "Run as administrator".

  2. Open the "hosts" file, located at "C:\Windows\System32\drivers\etc\hosts". You can open it in Notepad by going to "File -> Open" and navigating to the file location.

  3. Add the host entry to the bottom of the file in the following format:

    [IP address] [hostname]

    Replace "[IP address]" with the IP address of the host you want to add, and replace "[hostname]" with the hostname or domain name you want to assign to that IP address.

    For example, if you want to add an entry for a local web server with an IP address of 192.168.0.100 and a hostname of "mylocalserver", you would add the following line to the hosts file:

    192.168.0.100 mylocalserver
  4. Save the hosts file and exit the text editor.

After adding the host entry to the hosts file, you should be able to access the host using the assigned hostname or domain name in your web browser or other applications. Note that the changes may take a few moments to take effect, and you may need to clear your browser's cache or restart any affected applications for the changes to be recognized.

...