Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [apache-2.4]

Version 2.4 of the Apache HTTPd Server. When asking questions about virtualhosts, please include the output of the following command: "apache2ctl -S" (or "httpd -S" depending on your OS)

90
votes
2answers
187k views

What does Apache's “Require all granted” really do?

I've just update my Apache server to Apache/2.4.6 which is running under Ubuntu 13.04. I used to have a vhost file that had the following: <Directory "/home/john/development/foobar/web"> ...
66
votes
5answers
110k views

How do I redirect subdomains to a different port on the same server?

I have some subdomains I want to redirect to specific ports on the same server. Say I have dev.mydomain.com I want dev.mydomain.com to transparently redirect to mydomain.com:8080 and I want to ...
56
votes
3answers
59k views

How to fix 'logjam' vulnerability in Apache (httpd)

Recently, a new vulnerability in Diffie-Hellman, informally referred to as 'logjam' has been published, for which this page has been put together suggesting how to counter the vulnerability: We ...
31
votes
12answers
79k views

Apache 2.4 + PHP-FPM + ProxyPassMatch

I recently installed Apache 2.4 on my local machine, together with PHP 5.4.8 using PHP-FPM. Everything went quite smoothly (after a while...) but there is still a strange error: I configured Apache ...
30
votes
2answers
125k views

Apache is OK, but what is this in error.log - [mpm_prefork:notice]?

My apache server is running OK without any problems. It also doesn't issue any warning during restart. However, if I examine error.log I can see the following lines repeating from time to time: [Wed ...
29
votes
3answers
47k views

Using Https between Apache Loadbalancer and backends

I am using an apache (2.4) server configured as loadbalancer in front of 2 apache servers. It works fine when I use http connections between loadbalancer and backends, however using https does not ...
25
votes
5answers
46k views

How can I install Apache with a specific version?

Because of Ubuntu updating, I made the mistake to upgrade Apache 2.2 to 2.4—many things went wrong. I have no idea how to specify the version after apt-get remove apache2. apt-get install apache2 ...
25
votes
3answers
48k views

What is the meaning of “AH00485: scoreboard is full, not at MaxRequestWorkers”?

My Environment CentOS 6.4 X86_64 Apache 2.4.4 PHP 5.4.16 (FPM) 2 Intel Xeon E5-2620 @ 2.00GHz (8 core, 16 threads in each processor) 48GB RAM registered memory. 3 Hard Disk 15RPM 145GB in RAID0 (by ...
24
votes
4answers
73k views

How can I disable TLS 1.0 and 1.1 in apache?

Does anyone know why i can't disable tls 1.0 and tls1.1 by updating the config to this. SSLProtocol all -SSLv2 -SSLv3 -TLSv1 -TLSv1.1 After doing this, i reload apache I do an ssl scan using ...
22
votes
6answers
3k views

Why is response time exploding when request frequency drops?

Correction: response time (%D) is μs not ms! 1 This doesn't change anything about the weirdness of this pattern but it means that it is practically way less devastating. Why is response time ...
19
votes
4answers
57k views

Switch from PHP 7.2 to 7.1 on Ubuntu 16.04, Apache

I need to downgrade PHP on one of my VMs from 7.2 to 7.1 on Ubuntu 16.0.4. The last time I tried to remove just PHP and replace it with a different version, I had all kinds of issues with Apache and ...
17
votes
2answers
59k views

How To Tune Apache on Ubuntu 14.04 Server

Currently on my Apache 2 (Apache 2.4.7 to be exact) on Ubuntu 14.04, I have this setting: /etc/apache2/mods-enabled/mpm_prefork.conf <IfModule mpm_prefork_module> StartServers ...
14
votes
5answers
59k views

How do I require an IP range instead of 1 IP?

My IP changes do a different D class, so I want to set a range: 123.123.123.xxx where the last segment can be 0-255. Right now, Apache says: <RequireAny> Require ip 127.0.0.1 Require ip ...
13
votes
1answer
30k views

Configuring Apache 2.4 mod_proxy_wstunnel for Socket.IO 1.0

I'm trying to configure Apache 2.4 for proxying the websocket connection for socket.io to a node.js websocket server, using mod_proxy_wstunnel. We had this working fine with socket.io 0.9, but with ...
13
votes
4answers
9k views

Is it possible to set an SSLProtocol in Apache for a single VirtualHost (poodle)?

I'm trying to test a patch for the poodle vulnerability that involves disabling SSLv3 on my web server. In order to test this on a non-production environment first, I'm setting the SSLProtocol on a ...
13
votes
1answer
30k views

Confused about DFOREGROUND with Apache

So I just installed Apache on a new CentOS 7 server, using Yum. I've installed Apache many times before, but never have I seen this: When I run ps aux now, it always shows /usr/sbin/httpd -...
13
votes
3answers
19k views

SSLCertificateChainFile Deprecation Warning on Apache 2.4.8+

We have an SSL Certificate for our website from Network Solutions. After upgrading Apache/OpenSSL to version 2.4.9, I now get the following warning when starting HTTPD: AH02559: The ...
13
votes
1answer
9k views

Why is logrotate causing Apache to seg fault each time?

Every time logrotate runs Apache/2.4.7 (Ubuntu) experiences a seg fault and does not restart: [Wed Sep 10 06:35:54.266018 2014] [mpm_event:notice] [pid 20599:tid 140630283466624] AH00493: SIGUSR1 ...
12
votes
3answers
87k views

How to generate .key and .crt file from JKS file for httpd apache server

I have the mycert.jks file only. Now i need to extract and generate .key and .crt file and use it in apache httpd server. SSLCertificateFile /usr/local/apache2/conf/ssl.crt/server.crt ...
12
votes
5answers
23k views

Apache 2.4 proxy_balancer and lbmethod_byrequest

I'm trying to build my Apache server with static modules. But run into some problems with the proxy_balancer module. I get an error: [ssl:info] [pid 11863] AH01876: mod_ssl/2.4.10 compiled against ...
12
votes
2answers
3k views

SSL not working with Apache on Windows

I are using a product from a vendor that has to use Apache on Windows. We have our own CA. For naming purposes: AppServer - Server2012r2 - Apache 2.4 OldCertsha1 - Server2012r2 NewCertsha2 - ...
12
votes
2answers
1k views

How can I set up Certificate Transparency if my CA doesn't support it?

I think many of you have actually heard of Google's Certificate Transparency initiative. Now the initiave involves a public log of all certificates issued by some CA. As this is some amount of work, ...
11
votes
3answers
12k views

SELinux preventing Apache from writing to a file

SELinux is preventing the apache user from writing to a log file which it owns. When I do setenforce 0 it works. Otherwise it shows this error IOError: [Errno 13] Permission denied: '/var/www/webapp/...
11
votes
5answers
7k views

Apache 2.4 is unkillable and can't be stopped on Windows Server

We have two Windows Server, one in 2012 R2 and the other in 2008 R2 which uses Apache HTTP Server (httpd) 2.4 in proxy/reverse-proxy mode (usage of ProxyPass, ProxyPassReverse and Virtual Hosts ...
11
votes
3answers
11k views

Is it possible to replace content on every page passed through a proxy similar to how mod_rewrite is used for URLs?

Is it possible to replace content on every page passed through a proxy similar to how mod_rewrite is used for URLs? The documentation on substitute is not clear. I have some pages I am reverse ...
11
votes
2answers
25k views

Certbot letsencrypt on different port than 443

I want to set up certbot for a webserver on a different port than 443. I got the following error when running certbot --apache -d <sub>.<domain>.<ext> Failed authorization ...
11
votes
4answers
34k views

Apache2 “Require all granted” doesn't work

I have a fresh install of Apache2 on Debian testing and configured a virtual host in a directory like this: <Directory "/path/to/project"> Options Indexes FollowSymLinks MultiViews ...
11
votes
2answers
26k views

Correct Apache reverse proxy config with SSL for Jenkins and Sonar

I am running two services behind an Apache server: Jenkins (Port 8080) and SonarQube (Port 9000). My apache config looks like this: <VirtualHost *:80> ServerName server Redirect permanent /...
11
votes
1answer
855 views

How can you gracefully restart Apache without disconnecting SSL connections?

We are trying to reload Apache gracefully using a command such as: apache2ctl -k graceful This works as expected for HTTP users and the Apache config is reloaded without affecting users of the ...
10
votes
3answers
2k views

After enabling HTTPS on my Apache2 server - I get 404 errors on every request [closed]

Okay, so I've had no experience with SSL/HTTPS ever before, I've only ever dealt with standard HTTP. Recently I've started work on a site which will need SSL. So of course, I've gone out and ...
10
votes
3answers
34k views

Apache 2.4 restrict URL to certain IPs

I am trying to restrict a specific URL to be available outside the network only to specific IP addresses. When a user outside tries to access that URL and not from the list of IPs he should be ...
10
votes
2answers
2k views

How to serve different robots.txt for http and https on same site?

I got a small site which served by Apache (I can't put Nginx in front nor change Apache to anything), and it is set up to serve the same site both over http and https (no redirects http->https is ...
10
votes
2answers
4k views

Use FallbackResource even if directory exists

I've set up my virtual host on Apache 2.4.7 with a very basic configuration: <VirtualHost *:80> ServerName foo.example.com DocumentRoot /var/www/html DirectoryIndex index.php ...
10
votes
3answers
5k views

Apache's PidFile directory is removed every boot

Every time the server is rebooted, the directory /run/httpd is removed. /run is a tmpfs filesystem, therefore, mounted in RAM. /run/httpd is created only during installation. When I start httpd after ...
10
votes
3answers
8k views

Why does Apache send 200 OK while Last-modified matches If-modified-since?

I'm trying to have a basic behavior regarding my caching strategy: files should be cached, and revalidated with server each time. So I would like Apache to send a 304 back. Here is the dialog that ...
10
votes
3answers
17k views

Invalid command 'SSLOpenSSLConfCmd', perhaps misspelled or defined by a module not included in the server configuration

Like every other admin, I"m working through the Logjam fix. I've upgraded to Apache 2.4.12 and openssl 1.0.2a on my centos 6.6 box. When I start apache, I'm seeing this error message returned: ...
9
votes
8answers
1k views

Multi-site hosting - important vulnerability being missed to secure sites from each other?

EDIT #2 July 23, 2015: Looking for a new answer that identifies an important security item missed in the below setup or can give reason to believe everything's covered. EDIT #3 July 29, 2015: I'm ...
9
votes
1answer
52k views

apache ssl - unable to get local issuer certificate

Somehow just today suddenly my seafile client throwed this error. I don't believe its a seafile issue, because my openssl throws the exact same error: user@nb-user:~$ echo |openssl s_client -connect ...
9
votes
2answers
21k views

Why is enabling the rewrite log in .htaccess not working?

I want to enable rewrite logging so that I can debug a rewrite rule but adding the RewriteLog directives is causing a 500 error. Version information: Ubuntu 14.04 Server version: Apache/2.4.12 (...
9
votes
2answers
324 views

Can't figure out a htaccess rule

I have this in my htaccess but can't figure out what its for. Because of the nature of rule, searching doesn't help either. RewriteCond %{REQUEST_URI} !(/$|\.) RewriteRule (.*) %{REQUEST_URI}/ [R=301]...
9
votes
2answers
2k views

Break up a long line in a .htaccess file

I am setting a Content-Security-Policy header in my .htaccess file, and it has grown to be an extremely long single line, which is a bother to manage. Is there some way to break up this line into more ...
9
votes
3answers
11k views

apache2.4 mod_rewrite exclude specific alias directroy/uri

I have the following setup on one of my vhosts: ...<VirtualHost *:80> ServerName cloud.domain.de ServerAdmin webmaster@domain.de ServerSignature Off Alias "/.well-known/acme-...
9
votes
1answer
313 views

Apache2: allow/disallow access to a directory by time on day

Let's say I have a directory I want to restrict access that way, so that users can access the directory only on like 6am to 6pm. I know how to do this by using PHP (using time()%86400). But can I do ...
9
votes
3answers
31k views

Failed to load resource: net::ERR_CONNECTION_RESET

Since I started using an application behind a reverse proxy (Apache2's mod_jk), I've noticed some pages won't load (They would without the reverse proxy settings). It was a subtle error which I had ...
8
votes
4answers
2k views

Is it possible to serve specific pages based on IP address?

I've been the target of a brute force attack on two WordPress sites I own. The attacker is using the good old XML-RPC thing to amplify brute-force password attacking. Luckily we have extremely well-...
8
votes
3answers
5k views

CA Certificate not trusted by Firefox

My domain bytecode77.com (analytics) is using a RapidSSL certificate. Firefox doesn't trust that one, so I installed a CA certificate. I used the one below. I placed it in /usr/local/share/ca-...
8
votes
3answers
5k views

Difference between “Redirect permanent” vs. mod_rewrite RewriteRule

This is an Apache httpd 2.2 server. We require that access to this webserver be encrypted by HTTPS. When web clients visit my site at http://www.example.org/$foo (port 80), I want to redirect their ...
8
votes
4answers
11k views

I'm getting error: SSL3_GET_RECORD:decryption failed or bad record mac

I have my own server (where I'm running Apache/2.4.27), and today I realized that from (Brave and Google Chrome - different computers) I'm getting from my websites this error; This site can’t provide ...
8
votes
3answers
680 views

Upgrade HTTP connection to SSL/TLS

I currently have a server which automatically redirects all HTTP requests to the equivalent HTTPS site. The problem is that is seems like some browsers do not accept the SSL certificate (StartSSL.com) ...
8
votes
2answers
12k views

switch apache from prefork to event in Ubuntu 16, get php 7 working

Apache was running slow in production. After searching for answers for some time, I finally went to #apache IRC channel and the pros had me check the apache mode with this command: sudo apachectl -V ...