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)

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 ...
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 ...
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/...
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 ...
4
votes
1answer
3k views

Two separate PHP-FPM sites seem to be using the same code?

I have two websites with two codebases, yet when I change one codebase, I see the change in both. I have two checkouts of the same website. They are set up to use PHP-FPM through Apache2 with FastCGI....
3
votes
1answer
847 views

Can I view the resolved config Apache is using?

Is there a way to view the final "effective" config a running Apache instance is using after resolving any/all includes and the like? I'm looking at a config that has a web of includes and suspect ...
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 ...
2
votes
2answers
2k views

dynmap through mod_proxy on a external webserver

My setup consist of two servers, one for hosting websites and one for doing the heavy lifting (for example Minecraft). I am using Spigot to power some plugins and one of the plugins is dynmap (which ...
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 ...
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 ...
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 ...
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 ...
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 ...
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 /...
7
votes
3answers
8k views

Understanding apache 2.4 mod_proxy_fcgi and RewriteRules in htaccess

We've recently switched one of our web servers to apache 2.4 and running PHP via php-fpm and mod_proxy_fcgi. Most everything works quite well, but there is one problem that I don't understand yet. One ...
6
votes
1answer
7k views

How to stop nginx 301 auto redirect when trailing slash is not in URI?

Every time I try foobar.com/test in browser, nginx seems to redirect (301) the client to foobar.com/test/. This behaviour is unacceptable. The proxied server is a remote Apache web server. I have ...
5
votes
3answers
1k views

How can I use Let's Encrypt (letsencrypt.org) as a free SSL certificate provider?

I have a few sites running with a StartSSL free certificate (CJSHayward.com, JobhuntTracker.com), and Firefox rejects StartSSL and displays an error page saying that my server is not properly ...
4
votes
1answer
7k views

ProxyHTMLURLMap not working in apache2.4

I am using apache2.4 on ubuntu 14.04. And I have enabled mod_proxy_html.But my URL are not getting replaced by a new one. Same thing I did in apache2.2 and it was working perfectly. This is my ...
5
votes
3answers
10k views

Catch-All HTTPS Vhost on Apache 2.4

Is it possible to configure a catch-all (default) HTTPS Vhost on Apache 2.4? I currently have 4 domains, and an HTTP catch all but as soon as I try to add any sort of configuration my other vhosts ...
3
votes
1answer
551 views

Catch-all rewrite rule for apache that doesn't cause duplicate urls from .htaccess

You can make a catch-all rewrite rule for apache that acts somewhat like an alias, but can be implemented in a .htaccess file while an alias can't. As an example, assuming your document root is a ...
2
votes
4answers
8k views

Apache doesn't log remoteIP when RemoteIPHeader X-Forwarded-For is present

I'm using Apache/2.4.27 Within the VirtualHost I'm forwarding the remote client IP header from the Loadbalancer with: RemoteIPHeader X-Forwarded-For Which is needed by the application served by ...
1
vote
1answer
1k views

How to allow to change php version via .htaccess in Apache?

I've a Centos 7 with Apache, I want to compile php 7.0 and 5.6 and configure that as PHP-FPM. How can I configure Apache to allow users to change php version using .htaccess? Example .htaccess entry: ...
1
vote
1answer
494 views

SetEnvIfExpr with response header

I want to set a environment variable when a specific response header has a value. But when I make this it doesn't set the variable. Header add X-foo "bar" <If "resp('X-foo') == 'bar'"> ...
0
votes
1answer
2k views

Reducing Apache Memory usage and Average Process Size Value

I know that question is little long but i choosed to describe each and every aspect which i observed from my end. I am using a Linux server, OS used is Ubuntu 14.04, all rest configurations are ...
4
votes
1answer
4k views

Debugging a timeout with ldap auth on apache

I'm trying to debug a timeout problem I have with Apache, for some months now. The pattern looks like this: On every first request of a new session (or after some time after the last request) the ...
3
votes
2answers
1k views

PCI Compliance: install Apache 2.4.17 on Ubuntu 14.04.3?

I have a VPS running Ubuntu 14.04.3. The latest Ubuntu-supported version of Apache for this release is Apache 2.4.7. But the company for which I configured the server is seeking PCI compliance, and ...
2
votes
3answers
902 views

How do I conditionally set the SSLCertificateFile when the file exists?

I am using Let's Encrypt (certonly) to generate SSL certificates for several websites hosted on an Apache server. The file location of these certificates is determinate before they are created, so I ...
2
votes
3answers
2k views

Apache 2.4 - 403 HTTP status code

I'm getting a 403 error message with Apache, in Debian Testing. Apache version: # aptitude show apache2 | grep -i version Version: 2.4.9-1 # ls -la /home/ total 28 drwxr-xr-x 4 root root ...
2
votes
1answer
6k views

Sendmail: DSN: Service unavailable

I've been having trouble getting my server to send email and I haven't for the life of me figured out how to fix it. If anyone could give me some simple pointers, that would be muchly appreciated! ...
2
votes
2answers
2k views

Redirecting www to non-www (apache, letsencrypt )

Ubuntu 14.04 Apache 2.4.18 I have set up a SSL certificate using letsencrypt. It works well but in order to work, I cannot have multiple vhost defined in one virtualhost configuration file. Each ...
1
vote
1answer
1k views

Invalid argument: AH03139: ap_queue_pop failed

Short version, I upgraded from Fedora Server 23 to Fedora Server 24, and now my apache (httpd-2.4.23-4.fc24.x86_64) error_log is filling up with these messages: [Mon Nov 28 20:30:39.486187 2016] [...
1
vote
1answer
368 views

Creating new users using PHP not recognized by Apache 2.4

I have a server setup where new linux users are created using (PHP) shell_exec ( '/usr/sbin/useradd ' . $username ); exec ('usermod -a -G ' . $username . ' '. $username); #add user into the usergroup ...
1
vote
1answer
34 views

Serving http data from two servers

I have an Ubuntu server behind a NAT router / firewall. I would like to add another server, serving content from both servers over http(s). As I understand it I can have the "main" server request data ...
-2
votes
1answer
42 views

Why can't I set two vhost in my apache?

Apache was installed on my debian,i want to bind two domain name with different directroy. cat /etc/hosts 127.0.0.1 hwy.local www.hwy.local 127.0.0.1 test.app www.test.app Two domain name ...
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"> ...
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 ...
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 ...
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) ...
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 ...
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 ...
2
votes
2answers
2k views

KeepAlive in Apache 2.4 interfering with form submissions

I have just upgraded a server to Debian Jessie, which includes Apache 2.4.10 (was 2.2), and PHP 5.6. Now, SSL sites won't submit forms in some circumstances on IE11 and iPad Safari (not sure about ...
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 ...
8
votes
2answers
6k views

Apache's deprecated SSLCertificateChainFile directive (AH02559)

Recently I've upgraded Apache from 2.2 to 2.4 and I cannot figure out how to deprecate a SSLCertificateChainFile directive. The error: me@jessie:~$ sudo apache2ctl configtest AH02559: The ...
7
votes
2answers
12k views

HTTP/2 on CentOS 7 on Apache with PHP7

After some research I cannot find answer for: How to update Apache/httpd to newest version to use HTTP/2 protocol on my VPS. I'm using PHP7 & my server based on Apache - CentOS 7. No package ...
6
votes
4answers
5k views

Let's Encrypt SSL Certificate File Not Found Error, but still working

I'm running SSL Certificates from Let's Encrypt. I've got them installed on my Ubuntu machine running Apache. The setup works fine and I can launch the website, see the green padlock and even got an A+...
6
votes
1answer
3k views

Memory leak on Apache

I have a light memory leak apparently due to semaphores which are not released by Apache (configured as a reverse proxy). When the platform gets more loaded with additional traffic this leak gets more ...
6
votes
4answers
11k views

Apache: “File Not Found” after setting up php-fpm chroot

I'm struggling with the final step in implementing a chroot on php-fpm with Apache 2.4 running on CentOS 7. I've successfully setup and tested the php-fpm connection without the chroot. But as soon ...
5
votes
3answers
7k views

DefaultType directive in apache 2.4

We have just migrated from Apache 2.0.53 to Apache 2.4 Everything works perfectly for html/js/css files etc. But we have a number of endpoints on our servers which return plain text. For example - ...
4
votes
1answer
5k views

apache mod_authnz_ldap - 500 error when blank username used

I've got Apache 2.4 running on Windows Server 2012. I've got mod_authnz_ldap working except if users put a blank username. This results in a 500 internal server error. this is the entry in httpd....
4
votes
1answer
3k views

Exclusion of a protected sub-url does not work on Apache 2.4?

I try to exclude a sub-url "/shop/api" from my protected website. It worked fine on different server on Apache/2.2.15 but now not with Apache/2.4.7? It always asks for the basic authentication. Any ...