Questions tagged [apache2]

Apache (HTTP Server) /əˈpætʃiː/ is a modular cross-platform web server software with a large variety of features(called modules) including SSL, compression, log, proxy and server-side programming language interfaces like Perl, Python, Tcl, and PHP.

Filter by
Sorted by
Tagged with
3
votes
2answers
482 views

Multiple PHP versions on one Digital Ocean droplet

Is there an easy way of using multiple php versions on one single digital ocean droplet. Basically, I want something like what we have for cPanel (https://documentation.cpanel.net/display/68Docs/...
0
votes
1answer
284 views

Accessing phpmyadmin on ec2 leads to “This site can’t provide a secure connection”

i run a single aws ec2 instance (apache2) behind an elb which gives me a free ssl cert from amazon. I have redirected all port 80 traffic to 443 in config and everything runs smoothly. But, when i ...
3
votes
1answer
5k views

500 internal server error when trying to implement reverse proxy under Apache. How do I forward the requests to another server without errors?

I want to forward a request from one server to another. Here is my problem: hr.example.com - port 80 - Server A support.example.com - port 80 - Server B All requests on port 80 are forwarded to ...
3
votes
1answer
368 views

Possible to match special characters with mod_alias and `Redirect` directive?

I’m using Apache 2.4.6 with mod_alias and have a website which is receiving traffic from a link on another website that I have no control over. The other site’s link is poorly formed and it causes ...
1
vote
0answers
249 views

Set default file and folder permission for new files and folders - apache , ubuntu

I checked the file and folder permission of /var/www/html/ using stat -c '%A %a %n' * Folders : 775 Files: 664 drwxrwxr-x 775 includes -rw-rw-r-- 664 index.php -rw-rw-r-- 664 maintenance.html ...
2
votes
0answers
316 views

Specify the order and priority of LocationMatch directives from different Apache conf files

I have custom modules loaded in Apache HTTP Server that handles different URL's i.e each module handles a specific URL depending upon the LocationMatch directive defined in each of these modules. The ...
3
votes
1answer
2k views

SSL Labs Cipher Strength < 100%, why? How do I make it?

I am in a progress of trying (again) to get maximum (or almost maximum) score on SSL Labs with my site. I currently do not understand, why it does not give me full Cipher strength score. Now, it ...
2
votes
3answers
51 views

Does redirecting http to https using RewriteEngine preserve my site's link equity?

Running an Apache web server, if I use an .htaccess file to redirect all my http:// traffic to https:// using something like RewriteEngine On RewriteCond %{HTTPS} off RewriteRule ^(.*)$ https://%{...
1
vote
2answers
3k views

Forcing https causes all folders to redirect

I have quite a large site that consists of some regular web pages in the root and a lot of Joomla sites in folders. So it looks a little like this: - index.php (root) - about.php (root) - product....
8
votes
2answers
1k views

Explicit differences between <Directory> and <DirectoryMatch> (and other <*Match> directives)

Preface I'm very much a neophyte regarding webservers. I'm setting up an Apache2 server and currently poring over the documentation. I noticed that the <Directory>, <Location>, and <...
0
votes
2answers
211 views

Google site verification of www https site redirected from domain

I have an Apache Tomcat 8 web app correctly running on my website that is reverse proxied to the Apache2 server which serves up the web app at my domain name. I then provided alias' in my site's conf ...
2
votes
2answers
1k views

How can the index.html file be served from a sub directory of the DocumentRoot without using system level links?

How can the index.html file be served from a sub directory of the DocumentRoot without using system level links? For example: Let the document root of an apache 2.4 virtual host be dirA Let the the ...
0
votes
2answers
3k views

Why doesn't Apache allow access to files outside the web root --from within index.html?

As the title states.. I have the following organization to my project but am unable to access the related CSS and JavaScript files from within my HTML code --unless I create symbolic links from the ...
4
votes
3answers
463 views

Rewrite to SEO friendly URLs for language negotiation with type-map files on plain html files using .htaccess

When visiting the website www.example.com/ the visitor should be redirected to the correct language version, e.g. www.example.com/en for english and www.example.com/es for spanish. My current ...
2
votes
1answer
165 views

Why does switching php versions from 56 to 71 in httpd.conf give me a 403 access denied error? (MacOS localhost)

Recently installed php71 on my local test environment. I have an index.php file with phpinfo() in the web root directory. When I LoadModule php5_module /usr/local/opt/php56/libexec/apache2/libphp5....
1
vote
1answer
281 views

Apache 2.4: Symlinks to CIFS mount are served, but not seen by PHP or mod_autoindex

I'm trying to run the Piwigo image gallery/DAM on a Raspberry Pi via Arch Linux ARM with Apache 2.4 and PHP7. Piwigo is running happily. For a chain of reasons outside the scope of this question, my ...
0
votes
1answer
568 views

Apache FollowSymlinks works in DocumentRoot but 403s in subdirectories

I'm trying to run the Piwigo gallery/digital asset manager on a Raspberry Pi using Apache 2.4 on Arch Linux ARM. Piwigo's running happily. For Windows file naming and CIFS reasons, I need to make ...
2
votes
1answer
3k views

How do I configure gzip to work on External Resources

In order to do this I put code to .htaccess: <ifModule mod_gzip.c> mod_gzip_on Yes mod_gzip_dechunk Yes mod_gzip_item_include file .(html?|txt|css|js|php|pl)$ mod_gzip_item_include handler ^cgi-...
1
vote
1answer
39 views

What could cause my site to redirect to its IP address using Apache2?

I've been playing around with various web configurations in Debian for about a year now. I've set up DNS for a fow domains in the process and have never really had an issue. I: Go to Google domains ...
2
votes
1answer
830 views

How can I redirect example.com/username to Instagram app directly open from deep link?

I'm trying to redirect from example.com/username​ to Instagram deep link instagram://user?username=anyusername Here is my htaccess code RewriteEngine On RewriteBase / RewriteCond %{HTTP_HOST} ^(www\...
2
votes
1answer
41 views

Asked to authenticated WebDav twice when connecting to HTTPS

I'm having the problem of double authentification on my Apache server like he has: Properly Force SSL with .htaccess But I want to do this via the conf files. He says he knows how to do it via conf ...
3
votes
1answer
1k views

HOWTO log only slow requests in apache httpd

Is there a way to specify a condition in apache httpd access_log to persist only requests which took longer than 500ms to process?
2
votes
1answer
7k views

Disable TLS1.0 and TLS 1.1 through cPanel

I am using Apache and i have access of cPanel. I want to disable TLS1.0. I have no idea how to do this. Can this done via cPanel? Is there is any option how to do that? Where do I need to change ...
1
vote
2answers
52 views

Make local requests from webapp to header and footer files work without redirects for the default website

We have a server that is configured to serve several sites. One of these sites is a WordPress site, and some of its pages are really Java web applications hosted by Tomcat. The Java web applications ...
2
votes
1answer
543 views

.htaccess ErrorDocument directive does not catch 404 errors triggered by PHP http_response_code(404)

Apache 2.4.10 on Windows. I have a stable Zend Framework 1 PHP application. I just decided to add an ErrorDocument directive to .htaccess. I'm completely baffled by the three different behaviors I get ...
1
vote
1answer
63 views

With several sites on the same server and different rules for HTTP/HTTPS a non-secure site is getting redirected to a different secure one

I have an Apache server that will be serving up a few sites (all from the same IP address). Site A must be accessible via HTTP and HTTPS. Site B must only be accessible via HTTP - it cannot be ...
3
votes
0answers
441 views

Running Nodejs application and wordpress in same server

I am using one EC2 instance of AWS, I have two domains which I will connect with ec2 elastic ip but one domain will have wordpress running on it and other will have nodejs application running on it. ...
2
votes
1answer
3k views

What does “Require all granted” on Directory / (root) REALY means? (Apache 2.4 on CentOS7

im sure, this question looks really stupid first. but i need a "second opinion" on this, even i did some research on my own but i am still unsure about this. By default the Apache Configuration on ...
1
vote
1answer
17 views

With page load speed being a ranking factor, what speed optimizations do you recommend to prioritize? [closed]

My website has been becoming slow somewhere during development, according to visitors who emailed me, what speed optimizations do you recommend to priotize? Caching? CDN? Any input is very appriciated!...
3
votes
1answer
64 views

Phantom vhost forwarding from example.com to example.net

I'm running apache2 on Ubuntu 16.04 LTS, and Let's Encrypt Certbot for SSL certificates. I have two domains. Regardless of http or https, www or non-www, I want them to land at https://example.com ...
1
vote
1answer
50 views

Apache based Web sites show a dir listing instead of site content

All websites points to a directory listing ("Index of") of /var/www/html and when I click on any sites of the list, I see a duplicated domain and tld. A Syntax error is given, regarding: line 219 ...
1
vote
1answer
74 views

SSL Protect Unlimited Sites Under a Single vHost Without Server Restarts

I am creating a platform similar in concept to Wix for hosting websites. I wish to ensure that all the sites (except where specific issues prevent this on a site by site basis) will be protected by ...
5
votes
0answers
326 views

Ubuntu 14.04 can't enable .htaccess

I'm developing a website local and just switched from Windows to Ubuntu 16.04 - Sadly my .htaccess doesn't seems to work since rewrite rules don't apply and sources can't be found. I activated: sudo ...
2
votes
0answers
73 views

multiple virtual host in apache 2.22 on debian 7 … very strange and inexplicable behavior … someone can try to help me? [closed]

I'm facing a configuration issue that's really diving me nuts ... Basically I'm working as a sysadmin for a customer who use a single server to host many different site, to be more specific: Server ...
7
votes
1answer
793 views

Browser cache persistently expires for images in mod_pagespeed cache

Recently installed Google's plugin mod_pagespeed and I want to use it exclusively to address image optimization. So far the result frim Pagespeed insights has been hit or miss. Half the time it does ...
1
vote
1answer
809 views

How to issue .htaccess for Laravel?

I have just launched a Laravel 5.3 project on a live server and all is going well except one. But my issue is, my websites are running on all 3 different URLs: example.com example.com/public/index....
1
vote
1answer
944 views

CGI with Reverse Proxy Settings (Apache)

I have two VMs running two webapps. We want to use example.com/foo for accessing VM1, and example.com/bar for accessing VM2. For both VMs I need to call a cgi script for downloading. So I have ...
2
votes
0answers
501 views

How to proper configurate mod_proxy_uwsgi

I got uwsgi running behind nginx. All is working fine, but I want to change from nginx to Apache2 with mod_proxy_uwsgi. I cannot get a connection (access and error.log of appache are blank) My uwsgi....
-1
votes
2answers
130 views

Apache2 subdomain to domain [SSL]

I have domain with SSL and 4 subdomains like: ftp.example.com, server.example.com etc. I'm trying to redirect from subdomain to domain. Example: if someone goes to https://server.example.com they will ...
3
votes
3answers
2k views

Apache2 Ubuntu 16.04 Impossible To Get CORS Working

When visiting my website I get an error in console tab (using Firefox). The error is: Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at somewebsite. (...
2
votes
1answer
4k views

How to use X-Content-Type-Options for .css and .png file?

I have this code in my initialization file. header("Content-Security-Policy: default-src 'none'; script-src 'self'; connect-src 'self'; img-src 'self'; style-src 'self' 'unsafe-inline';"); ...
17
votes
2answers
11k views

StartSSL certificate gives SEC_ERROR_REVOKED_CERTIFICATE in Firefox and ERR_CERT_AUTHORITY_INVALID in Chrome

My existing HTTPS certificate is expiring soon so I bought a new one. I'm having a very hard time installing it properly though. I have a wildcard certificate from StartSSL for *.deadsea....
1
vote
1answer
724 views

How to determine what caused directory url to get access denied?

Using Apache 2.4.10 on two different Linux hosts. The server configurations are very similar, and running very similar php web applications. With one server, the uri /uploads produces: Access ...
2
votes
1answer
104 views

How much SEO risk is there having a 500 error for a few milliseconds during deployment?

I'm writing a deployment script that works like this: Copy the current document root site.current in a new folder at the same level. /web/site.current copied to /web/site.new Update the new ...
1
vote
1answer
122 views

Access resources of secondary server running different port apache2

I'm currently running a main server from a raspberry pi (32 GB) and a secondary server (4 TB) running as the file storage server. Both servers are running Debian Linux with Apache2 installed. I've ...
3
votes
1answer
864 views

Apache 2.4, trying to turn off DirectorySlash

My dev server (Debian 8.5) has DirectorySlash Off in the conf file for a site, and it works - no trailing slash added, and no redirect on requests for an existing directory. The same directive is in ...
2
votes
1answer
885 views

apache rewrite rule set for “whitelist or catchall” in .htaccess

On the dev version of a LAMP site (Apache 2.4 on Debian 8.5), my Apache rewrite rules implement a "whitelist then catch-all" concept. Specifically, images from images/, stylesheets from css/, ...
3
votes
1answer
175 views

suexec policy violation error for a javascript file

I deployed a web-app on DreamHost shared hosting. During tests, I got the "500 Internal Server Error" on one of the JavaScript files called jquery.timeago.pl.js (the jQuery timeago plugin locale ...
2
votes
0answers
80 views

How to host 2 webapps on the same server

I'm working on a VPS with Ubuntu and I configured a webapp called Pathfinder, it's a third party app for a game called EVE Online. Now I need to add another app to the server but I don't want to mix ...
2
votes
1answer
893 views

MediaWiki not creating a log file and cannot access the database

I'm trying to set up MediaWiki on an Apache2 server. Currently, when I navigate to the directory where the wiki is stored in my web browser, I see the contents of LocalSettings.php dumped on the ...