Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I just installed the kubuntu 13.10 and did the full dist upgrade, apache2 was working normal in kubuntu 13.04, in the 13.10 i see some changes like the example.net is changed to the example.net.conf in apache2 configurations, now want to open the exmaple.net with apache2 server get this error:
Quote:
Forbidden
You don't have permission to access / on this server.
Apache/2.4.6 (Ubuntu) Server at example.net Port 80
The doument root /home/www permission is set to 755, this is the /etc/apache2/sites-enabled/example.net.conf:
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>
The host from /var/www is working fine, the problem is with the virtualhosts.
You docroot is outside of the default docroot (/var/www), so you need to add:
Code:
<Directory /home/www/example.net/htdocs>
Allow from all
</Directory>
Not to hijack this thread, but I am apparently having the same issue, though the default file the op shows is not the same as the one I have. What version of apache2 does kubuntu include?
The apache2 sites-available directory, part of the tasksel LAMP install under Xubuntu 13.10:
<VirtualHost *:80>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request's Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
#ServerName www.example.com
ServerAdmin webmaster@localhost
DocumentRoot /var/www
# Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
# error, crit, alert, emerg.
# It is also possible to configure the loglevel for particular
# modules, e.g.
#LogLevel info ssl:warn
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
# For most configuration files from conf-available/, which are
# enabled or disabled at a global level, it is possible to
# include a line for only one particular virtual host. For example the
# following line enables the CGI configuration for this host only
# after it has been globally disabled with "a2disconf".
#Include conf-available/serve-cgi-bin.conf
</VirtualHost>
All that I have been able to determine comes from the Apache2 site documentation, and it says that a2dissite and a2ensaite have been deprecated. I can not find how to enable a virtual host.
a2dissite and a2ensite are still present but will not enable the virutal site with any configuration of 000-<mysite>.conf.
Where do I put the docroot, and then what do I do?
How do I make /home/<user>/www the virtual site in Apache2.4.6 as I was able to do up to Apache2.2.22(Ubuntu) - up to and including xubuntu 13.04?
Having already checked the owner/group and permissions, I tried the above and am still getting the "Forbidden" error on my virtual site. It is now enabling the site, which it would not do before, but I still can not access it. (Can you wear out a service reloading it? Just kidding.)
and changed the permissions of /home/www to 644, all virtual hosts working now. to enable the site run the command a2ensite from the sites-available directory.
I added the lines below to the /etc/apache2/apache2.conf:
and changed the 000-default.conf to my virtual host:
and changed the permissions of /home/www to 644, all virtual hosts working now. to enable the site run the command a2ensite from the sites-available directory.
Following these recommendations has not made it work for me.
The user is in the www-data group (xubuntu 13.10), and I've tried both 644 and 755 permissions.
I tried using a duplication of the virtual site configuration file which works under 13.04/apache2.2.22(Ubuntu), and various changes of the file variables.
With everything I have done I get either "Forbidden" or "Not found". I am retracing my steps to learn under what configuration I get which, hoping that something will "click".
At present, the only way I can access the files which were my virtual site is by putting a symlink in /var/www which points to them.
(My need for a local server is simply to have a mirror of several remote websites which I maintain. So I do not think that security is a real concern for me, is it?)
Can you tell me specifically how to disable SELINUX? (If this is not the place to ask such a stupid question, then I must either dismiss the suggestion or go elsewhere to learn how to follow it. At this point I am not primarily interested in knowing what it is and what it does; I simply want a properly functioning local web server with my chosen os.)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.