您的位置:首页 > 运维架构 > Apache

apache虚拟主机配置文件

2012-07-22 22:09 489 查看
修改http.conf文件 修改用户名与用户组

<Directory />
Options Indexes FollowSymLinks
AllowOverride none
# Require all denied
# Deny from all
</Directory>

<VirtualHost *:80>
ServerAdmin gbyukg@163.com
DocumentRoot "/home/gbyukg/www/sugar/"
ServerName www.sugar.com
ServerAlias www.sugar.com
ErrorLog "/home/gbyukg/www/logs/error_log"
CustomLog "/home/gbyukg/www/logs/access_log" common
<Directory />
Options FollowSymLinks IncludesNOEXEC Indexes
AllowOverride All
# Order deny,allow
Deny from all
Allow from all
</Directory>
</VirtualHost>

/etc/hosts配置文件修改

127.0.0.1 www.sugar.com
127.0.0.1 www.test.com


apache安装问题:

Permission denied: make_sock: could not bind to address 0.0.0.0:80

apache/bin/httpd文件需要给普通用户增加权限才能打开1024以内到端口,修改权限:增加s为4

chmod 4755 httpd
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: