The OpenNET Project / Index page

[ новости /+++ | форум | wiki | теги | ]

Поиск:  Каталог документации / Документация по FreeBSD / Руководства по FreeBSD на английском

2.4. Creating the List of other LAN Hosts(/etc/hosts)

The final step in configuring the LAN side of the FreeBSD system is to create a list of the names and TCP/IP addresses of the various systems that are connected to the Local Area Network. This list is stored in the '/etc/hosts' file.

The default version of this file has only a single host name listing in it: the name and address of the loopback device ('lo0'). By networking convention, this device is always named "localhost" and always has an IP address of Section 2.2.

To edit the /etc/hosts file enter the following command:

     # ee /etc/hosts

Scroll all the way to the bottom of the file (paying attention to the comments along the way; there's some good information there!) and enter (assuming our sample network) the following IP addresses and host names:    curly  # FreeBSD System    larry  # Windows '95 System    moe    # Windows for Workgroups
    System    shemp  # Windows NT System

(No changes are needed to the line for the ' localhost' entry.)

Once you've entered these lines, press the 'Esc' key to invoke the control menu. Select "leave editor" and be sure to select "save changes" when prompted.

For questions about FreeBSD, e-mail <>.
For questions about this documentation, e-mail <>.

Inferno Solutions
Hosting by

Закладки на сайте
Проследить за страницей
Created 1996-2023 by Maxim Chirkov
Добавить, Поддержать, Вебмастеру