Возникла проблема.
K:~ K$ sudo /opt/local/apache2/bin/apachectl start
(48)Address already in use: make_sock: could not bind to address [::]:80
(48)Address already in use: make_sock: could not bind to address 0.0.0.0:80
no listening sockets available, shutting down
Подскажите где я ошибся в настройках.
httpd.conf
ServerRoot "/opt/local/apache2"
Listen 80
LoadModule authn_file_module modules/mod_authn_file.so
.................................
LoadModule rewrite_module modules/mod_rewrite.so
<IfModule !mpm_netware_module>
<IfModule !mpm_winnt_module>
User www
Group www
</IfModule>
</IfModule>
ServerAdmin you@example.com
DocumentRoot "/opt/local/apache2/htdocs"
<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
</Directory>
<Directory "/opt/local/apache2/htdocs">
Options Indexes FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<IfModule dir_module>
DirectoryIndex index.html
</IfModule>
<Files ~ "^\.([Hh][Tt]|[Dd][Ss]_[Ss])">
Order allow,deny
Deny from all
Satisfy All
</Files>
<Files "rsrc">
Order allow,deny
Deny from all
Satisfy All
</Files>
<DirectoryMatch ".*\.\.namedfork">
Order allow,deny
Deny from all
Satisfy All
</DirectoryMatch>
ErrorLog "logs/error_log"
LogLevel warn
<IfModule log_config_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common
<IfModule logio_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
</IfModule>
CustomLog "logs/access_log" common
</IfModule>
<IfModule alias_module>
ScriptAlias /cgi-bin/ "/opt/local/apache2/cgi-bin/"
</IfModule>
<IfModule cgid_module>
#Scriptsock logs/cgisock
</IfModule>
<Directory "/opt/local/apache2/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>
DefaultType text/plain
<IfModule mime_module>
TypesConfig conf/mime.types
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz
</IfModule>
# Server-pool management (MPM specific)
#Include conf/extra/httpd-mpm.conf
......
# Virtual hosts
Include conf/extra/httpd-vhosts.conf
....
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
httpd-vhosts.conf
#
# Virtual Hosts
#
NameVirtualHost *:80
<VirtualHost *:80>
ServerAdmin your_email@example.com
# Path to index file
DocumentRoot "/Users/K/ws/www/"
# Server URL. Must be present in /etc/hosts file
ServerName test.dev
<Directory /Users/K/ws/www/test>
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
# Logs
ErrorLog "logs/test.log"
CustomLog "logs/test-access.log" common
</VirtualHost>
hosts
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
127.0.1.1 test.dev
255.255.255.255 broadcasthost
::1 localhost ogoltsov test.dev
fe80::1%lo0 localhost ogoltsov test.dev
.....
Собственно Apache, который я установил через MacPorts не запускается -> хосты тоже не работают.
При запросе localhost, ogoltsov, test.dev выводит одну и ту же страницу.