Устанавливаем Apache Главная

Устанавливаем через sysinstall порты

http://www.freebsd.org/doc/ru_RU.KOI8-R/books/handbook/ports-using.html
,
потом Apache


Вставьте ваш CD-ROM с FreeBSD в привод. Смонтируйте его в каталог
/cdrom.


либо поместите копию дистрибутивного файла в каталог
/usr/ports/distfiles


Установка порта из Интернет производится точно так же, как если бы вы делали
е¸ с CD-ROM. Единственным отличием является то, что дистрибутивный файл
загружается из Интернет.


Чтобы начать установку, перейдите в каталог с нужным вам портом:


# cd /usr/ports/russian/apach13


# make


# make install


получим дерево:


но при первом запуске


# apachectl start


машина выдает


/usr/local/sbin/apachectl  Could not determine the server's fully qualified
domain name, using 127.0.0.1 for ServerName start: httpd could not be started


это надо настроить конфигурацию веб-сервера, так:


# ee /usr/local/etc/apache/httpd.conf




 L: 334 C: 21 ============== ===========================

# your server if it's different than the one the program would get (i.e., use


# "www" instead of the host's real name).

#

# Note: You cannot just invent host names and hope they work. The name you

# define here must be a valid DNS name for your host. If you don't understand


# this, ask your network administrator.

# If your host doesn't have a registered DNS name, enter its IP address here.


# You will have to access it by its address (e.g.,
http://123.45.67.89/)

# anyway, and this will make redirections work in a sensible way.

#

# 127.0.0.1 is the TCP/IP local loop-back address, often named localhost. Your


# machine always knows itself by this address. If you use Apache strictly for


# local testing and development, you may use 127.0.0.1 as the server name.

#

#ServerName www.example.com

# добавляем запись ServerName localhost ( см. без решотки)

ServerName localhost


далее правим файл hosts


# ee /etc/hosts




L: 16 C: 35 =============== ===========================

# # Host Database #

# This file should contain the addresses and aliases for local hosts that

# share this file. Replace 'my.domain' below with the domainname of your

# machine.

#

# In the presence of the domain name service or NIS, this file may

# not be consulted at all; see /etc/nsswitch.conf for the resolution order.

#

#

#::1 localhost localhost.my.domain

#127.0.0.1 localhost localhost.my.domain


127.0.0.1                 localhost            .home


запускаем Апача


# apachectl start

/usr/local/sbin/apachectl start: httpd started


вот, а  в браузере набираем http://localhost 
и смотрим тестовую страничку!

Комментариев (0)
01 Jul 2007 • Автор: shaman

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216

Warning: Division by zero in /home2/awebdrug/public_html/inc/functions.inc.php on line 216