Search code examples
apache2lamp

Getting Error "You don't have permission to access / on this server. Apache/2.2.22 (Ubuntu) Server at localhost Port 80


I changed my Document above error when trying to access the localhost.

DocumentRoot /home/kunal/Development/sites
<Directory /home/kunal/Development/sites>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order allow,deny
    allow from all
</Directory>

I ran the a2ensite for new file and restarted the apache server. I have my sites folder permission set to 777 permission. Still I am getting this error. Can someone please help me here?


Solution

  • I got the same error, my path was similar to yours like this /home/user/Dropbox/WebDev/ServerRoot. I made the same mistake as you by setting permissions on the last folder or your site folder.

    Set your permissions at from the 3rd folder of your file path for me I had to set permissions to the /Dropbox folder then it started to work I recommend you set your permissions on the /Development folder and it will start to work.

    Hope this helps you.