Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
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 have a server on Azure using RedHat, I made the installation of apache, I changed the folder in DocumentRoot, however when I try to access it via browser it presents the error: Forbidden You do not have permission to access this server File: / etc / httpd / Conf / httpd.conf
Can someone help?
Note: When I do not change the folder and leave default I can see the default Apache page.
Can you access the documentRoot as the same user as Apache is using?
Code:
su apache -s /bin/bash -
cd /mnt/sd/minhapasta
Also do you have selinux enabled?
Code:
# getenforce
Disabled
It will most likely be either of these two that is the issue, the easy route for selinux is to disable it but is less secure. You'd have to amend selinux itself however to fix that.
Can you access the documentRoot as the same user as Apache is using?
Code:
su apache -s /bin/bash -
cd /mnt/sd/minhapasta
Also do you have selinux enabled?
Code:
# getenforce
Disabled
It will most likely be either of these two that is the issue, the easy route for selinux is to disable it but is less secure. You'd have to amend selinux itself however to fix that.
Also not sure how this is a "networking" issue.
The file that holds the SELINUX configuration is disabled, but in the getenforce command it appears Enabled. System restarted.
Code:
su apache -s /bin/bash -
cd /mnt/sd/minhapasta
Sorry, but I do not understand these lines. Introduced 'apache' command not found
The file that holds the SELINUX configuration is disabled, but in the getenforce command it appears Enabled. System restarted.
Code:
su apache -s /bin/bash -
cd /mnt/sd/minhapasta
Sorry, but I do not understand these lines. Introduced 'apache' command not found
To disable selinux requires a restart, maybe it was set disabled and not restarted? Well if you have restarted now you can test.
Code:
su apache -s /bin/bash -
Switches you to the apache user, your configuration has the user down as "apache", as the apache user usually has a fake shell, the '-s' sets the shell to /bin/bash to enable login.
I have a server on Azure using RedHat, I made the installation of apache, I changed the folder in DocumentRoot, however when I try to access it via browser it presents the error: Forbidden You do not have permission to access this server File: / etc / httpd / Conf / httpd.conf
Can someone help?
Note: When I do not change the folder and leave default I can see the default Apache page.
The apache2 service/daemon on that host is deployed using /etc/httpd/conf/httpd.conf
In My Experience, there are few reasons to alter /etc/httpd/conf/httpd.conf
"To change the DocumentRoot so that it is not shared by the secure and the non-secure Web servers, refer to"Section 21.7, “Virtual Hosts”.
Leave /etc/httpd/conf/httpd.conf as it was, and in a terminal, issue
Code:
apache2ctl -S
Your output may be similar to this:
Code:
/etc/httpd/sites-enabled/000-default.conf
That is the correct file to add/or alter a DocumentRoot
I did not configure Virtual host because I have only to submit an application in php. Virtual host must be configured when I have more than one application that uses apache, correct?
When I put a file in var / www / html I can access, however my files can not stay in this location.
They should stay on another disk, so I want Apache to be started on this other disk.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.