我为服务器PC安装了ubuntu 12.04服务器版本。我已经安装了灯泡服务器。我需要将var / www位置更改为我的辅助硬盘位置。我在gedit中配置了很多时间/ etc / apache2 / sites-available / default这是我的代码
<VirtualHost *:80>
ServerAdmin webmaster@localhost
#DocumentRoot /var/www
DocumentRoot /media/myserver/
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
#<Directory /var/www/>
<Directory /media/myserver/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>
并且也使用了
sudo chown -R var/www /media/myserver/
和
chmod -R 755 /media/myserver/
仍然我无法连接我的/ media / myserver并且我的浏览器显示以下消息
Forbidden
You don't have permission to access / on this server.
请告诉任何人如何在我的var / www上挂载myserver,谢谢