1

I'm trying to set up multiple virtual websites for development using Apache2 on Debian jessie. I had it set up and working before I had to do a fresh install. Basically the system broke after an upgrade.

I can access "localhost" and even "localhost/phpinfo.php". So this tells me the server is installed "properly". When I try to access "rosebusch.local" (the name of the virtual-host) I get:

Forbidden

You don't have permission to access /index.html on this server.
Apache/2.4.10 (Debian) Server at rosebusch.local Port 80

The permissions for /home/jeff/public_html are :

drwxrwxrwx 5 jeff www-data 4096 Aug 30 21:41 public_html

The output of apache2ctl is as follows :

VirtualHost configuratin:
*:80                   is a NameVirtualHost
     default server rosebusch.local (/etc/apache2/ports.conf:9)
     port 80 namevhost rosebusch.local (/etc/apache2/ports.conf:9)
             alias www.rosebusch.local
     port 80 namevhost localhost (/etc/apache2/sites-enabled/000-default.conf:3)
     port 80 namevhost rosebusch.local (/etc/apache2/sites-enabled/rosebusch.conf:3)
             alias www.rosebusch.local
ServerRoot: "/etc/apache2"
Main DocumentRoot: "/var/www/html"
Main ErrorLog: "/var/log/apache2/error.log"
Mutex watchdog-callback: using_defaults
Mutex rewrite-map: using_defaults
Mutex default: dir="/var/lock/apache2" mechanism=fcntl 
Mutex mpm-accept: using_defaults
PidFile: "/var/run/apache2/apache2.pid"
Define: DUMP_VHOSTS
Define: DUMP_RUN_CFG
User: name="www-data" id=33
Group: name="www-data" id=33

The contents of /etc/hosts :

127.0.0.1   localhost rosebusch.local
127.0.1.1   debian-jeff.busch.org   debian-jeff

# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters

The contents of /etc/apache2/site-available/rosebusch.conf :

<VirtualHost *:80>
    ServerAdmin webmaster@rosebusch.local
    ServerName rosebusch.local
    ServerAlias www.rosebusch.local
    DocumentRoot /home/jeff/public_html/rosebusch
    <Directory /home/jeff/public_html/rosebusch>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Order allow,deny
       allow from all
    </Directory>
    ErrorLog /var/log/apache2/www.rosebusch.local-error_log
    CustomLog /var/log/apache2/www.rosebusch.local-access_log common
</VirtualHost>

I did enter a2ensite rosebusch.conf. What am I missing? I got this all setup (4 virtual hosts) with XAMP on Windows 8 just by modifying one file. I don't remember having so much trouble setting this up on Debian the last time I did this.

Thanks Jeff

TFotH
  • 181
  • 3
  • 6

1 Answers1

5
<Directory /home/jeff/public_html/rosebusch>
   Options Indexes FollowSymLinks MultiViews
   AllowOverride All
   Order allow,deny
   allow from all

   # New directive needed in Apache 2.4.3: 
   Require all granted
</Directory>

http://httpd.apache.org/docs/current/upgrading.html

Error message "Forbidden You don't have permission to access / on this server"

Community
  • 1
  • 1
bekt
  • 597
  • 4
  • 16