I am using XAMPP for first time in Mac. Running out problems accessing other than root folder(htdocs).when I am placing my web application inside htdocs with default httpd.conf file it works when I try to point my web application url in httpd.conf it throws You don't have permission to access / on this server. error
I am aware that to modify the root folder I need to do changes to my XAMPP/etc/httpd.conf file
With Default XAMPP MAC Settings, I am trying to change Server root,Document root and Directory in XAMPP/etc/httpd.conf file the following
ServerRoot "/Applications/XAMPP/xamppfiles"
DocumentRoot "/Users/ravi/Documents/Development/Backbone/backboneboilerplate"
<Directory />
#Options FollowSymLinks
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order deny,allow
Allow from all
</Directory>
<Directory "/Users/ravi/Documents/Development/Backbone/backboneboilerplate">
Options Indexes FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
</Directory>
It was chmod problem. I tried giving chmod -r 777 to Development folder, backbone folder and Backboneboilerplate.. It worked.
Related
I was able to reach http://myip, it is redirecting me to apache page.
But when am trying to reach var/www/html/dashboard am having this problem forbidden dont have permissions.
My httpd.conf is as below:
<Directory />
Options Indexes FollowSymLinks
AllowOverride none
Require all granted
</Directory>
DocumentRoot "/var/www/html"
<Directory "/var/www">
AllowOverride All
# Allow open access:
Require all granted
</Directory>
# Further relax access to the default document root:
<Directory "/var/www/html">
I have already disabled the SELinux:
SELINUX=disabled
I have also tried:
sudo restorecon -r /var/www/html
Nothing is helping me to solve my problem, can somebody please help me:
Allow the apache user read and execute permissions at every level of your DocumentRoot using chown or chmod at each level that is restricting the apache user.
Or, FollowSymLinks Option must be enabled for your directory in httpd configuration.
<Directory "/var/www/html/dashboard">
Options Indexes FollowSymLinks
</Directory>
Or, to diagnose, check file permissions using namei:
namei -l /var/www/html/dashboard
Saw duplicate questions and solutions, does not seem to solve the below problem
I am trying to allow access to a folder through apache, and the /var/log/apache2/ throws the above error.
My httpd.conf is
# forbid access to the entire filesystem by default
<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Allow from all
</Directory>
I tried with Options +Indexes, Options All which doesnt seem to work. Tried to change permissions of the folder too. Added a dummy index.html in the folder as well
The folder is located at /srv/www/htdocs/testFolder.
Any ideas?
had to add files explicitly the files in the conf file
<Directory /srv/www/htdocs/HDP-UTILS-1.1.0.20>
Options +Indexes
</Directory>
<Directory /srv/www/htdocs/HDP>
Options +Indexes
</Directory>
I resolved a similar where Apache was throwing 403 error while trying to access the index.html file the issue was resolved by creating a index.hmtl in /srv/www/htdocs directory.
url: http://localhost:80/
The Suse Apache didn't create a index.html file by default don't know why.
Change your config to
Options -Indexes FollowSymLinks
AllowOverride All
Order allow,deny
allow from all
After that create an .htaccess file in your folder and add
Options +Indexes
to it. You probably need to reload your apache.
Though there are many similar questions here but I could not fix my problem from them.
I have installed Apache/2.4.7 (Ubuntu) in my ubuntu(14.04). I have changed two configuration files to change the default DocumentRoot of apache which is /var/www
to /home/name/www. The files I have changed are /etc/apache2/apache2.conf and /etc/apache2/sites-available/000-default.conf. In apache2.conf I put
<Directory /home/name/www>
Options Indexes FollowSymLinks
AllowOverride None
Require all granted
</Directory>
and in 000-default.conf I changed,
DocumentRoot /home/name/www
My /home/name/www file has necessary permissions.
drwxr-xr-x 3 www-data www-data www
But when I try to access localhost from browser I receive
You don't have permission to access / on this server. error. What have i missed?
For changing the default root directory of apache from /var/www to /home/<username>/www following changes worked for me.
I edited the following values of etc/apache2/apache2.conf file like this. Before editing the file it's a good practice to keep a backup of the original.
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /usr/share>
AllowOverride None
Require all granted
</Directory>
<Directory /home/<username>/www>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
Then I changed /etc/apache2/sites-available/000-default.conf file's DocumentRoot.
DocumentRoot /home/<username>/www
After that restart the apache server,
sudo service apache2 restart
I have installed Laravel 4 on my public_html folder locally, and I can access its public folder when declaring a vhost pointing to it, through the vhost url.
But, when I try to access Laravel public folder through its parent folders, I get an error in apache logs (error_log): $LARAVEL_HOME/public/.htaccess: Options not allowed here. Even if there is a AllowOverride All in $VHOST_CONF/site.
The first line in the .htaccess (Options Multiviews), is causing this error when I delete it, or put it in $VHOST_CONF/site, it works.
So, How do I do to I access through the hierarchy, without modifying the .htaccess file?
In the Apache configuration file for the website set AllowOverride to AllowOverride All similar to the following:
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
# changed from None to All
AllowOverride All
Order allow,deny
allow from all
</Directory>
I am having trouble getting virtual hosts to work in apache 2.2.22 on linux (and windows!). I can get vhosts working within the www/html folder, but I am unable to get it working if the website folders are elsewhere. The permissions I was using in the httpd.conf file are:
<Directory "/path/to/my/websites">
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order Deny,Allow
Allow from all
</Directory>