Проблема с VirtualHost

Рейтинг: 0Ответов: 1Опубликовано: 31.05.2011

Вообщем поставил свой сайт на VPS, теперь проблема с конфигом VirtualHost.

Вот собственно и он:

<VirtualHost *:80>
     ServerAdmin webmaster@localhost

     DocumentRoot /var/www/
     <Directory />
          Options FollowSymLinks
          AllowOverride All
     </Directory>
     <Directory /var/www/>
          Options Indexes FollowSymLinks MultiViews
          AllowOverride All
          Order allow,deny
          allow from all
     </Directory>

     ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
     <Directory "/usr/lib/cgi-bin">
          AllowOverride All
          Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
          Order allow,deny
          Allow from all
     </Directory>

     ErrorLog /var/log/apache2/error.log

     # Possible values include: debug, info, notice, warn, error, crit,
     # alert, emerg.
     LogLevel warn

     CustomLog /var/log/apache2/access.log combined

    Alias /doc/ "/usr/share/doc/"
    <Directory "/usr/share/doc/">
        Options Indexes MultiViews FollowSymLinks
        AllowOverride All
        Order deny,allow
        Deny from all
        Allow from 127.0.0.0/255.0.0.0 ::1/128
    </Directory>

</VirtualHost>

А на самом сайте написано:

You don't have permission to access the requested directory. There is either no index document or the directory is read-protected. You don't have permission to access the requested object. It is either read-protected or not readable by the server.

Друзья, в чем ошибка? Помогите..

Ответы

▲ 1

Вот мне кажется, у вас прав нет на чтение папки с сайтом. Попробуйте так:

chmod 700 -R /path/to/website/rootdir
chown www-data -R /path/to/website/rootdir