Questions tagged as ['apache2']

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)
Score: 0
Sree avatar
Tomcat java consuming more Memory
in flag

enter image description herei am using aws in my tomcat application java eats more memory and more cpu utilization. my server configuration: 8 vcpu amd 16gb Memory i increased java heap size up to 10gb and i changed my apache2 mpm module event to worker with defauly values

Score: 0
stop from browser
ru flag

I have a mail server setup for a domain using postfix. For the ssl cert, I have created a virtual host for that mail server. The virtual host look like this

<VirtualHost *:80>
  DocumentRoot /var/www/roundcube/

  ErrorLog ${APACHE_LOG_DIR}/mail.domainX.net_error.log
  CustomLog ${APACHE_LOG_DIR}/mail.domainX.net_access.log combined

  <Directory />
    Opt ...
Score: 0
Finaria avatar
This site is missing a valid, trusted certificate || Apache2 webserver, Windows root CA
bh flag

I'm learning about certificates, HTTPS together and after 4 days I'm out of idea how to set up to become trusted. In my lab env. I have a Windows server with a CA role.

Previously I installed a VM-Dell OpenManage for my server. It has a graphical interface for requests and an import certificate for HTTPS access. I successfully generated a Certificate Signing Request and get a cert from my windows ...

Score: 0
Mort avatar
Apache: Allow Certain Users only from specified subnet
us flag

I have a requirement to change some Apache 2.4 authentication so that most users can access the website from anywhere, but certain users (who can be identified in a number of ways, but an LDAP group would be the easiest) can only be permitted access from a certain IP address subnet. (Authentication is via OIDC module plus ldap groups.)

(A simplified version of what) the current Apache config is

<Req ...
Score: 0
HTTP error 405 after moving from server to localhost
cn flag

I moved my login system code from a server (separate laptop on same network) to my main computer to use on a localhost database via XAMPP (apache and mysql server). When entering the credentials and submitting I get a 405 error: method not allowed. I did not get this when working on the server. XAMPP apache log doesn't offer me anything. I have tried using MAMP instead.

Score: 0
biscuit_ avatar
Why is my valid SSL certificate invalid on a particular site with the same host?
br flag

I have hosting set up with HostEurope. My SSL certificate seems to be valid (it has not expired etc.) and it works for one the domains I use on my server (the SSL certificate was purchased for this domain). Recently I set up another site with a different domain on the same server and supplied the same SSL certificate as HostEurope tells me it's possible to use my certificate as 'global', i.e. for all do ...

Score: 0
manifestor avatar
Apache web server: Kill process/thread automatically that consumes too much RAM
mp flag

We're running an Apache web server (version 2.4.51 on Debian 11) which delivers a huge website with lots of scripts, all written in Perl. The problem is that no one can can really figure out how the code works and the functionality is being continuously replaced by new software written in PHP. Sometimes though the old Perl code runs into a loop, starts consuming too much RAM and the Apache web server ...

Score: 0
How to configure Apache mod_proxy to select a URL from a table? E.g. via a script?
in flag

We've got Apache mod_proxy performing the function of a reverse proxy to a specific host:ip currently.

We would like to be able to take a url like https://domain/pathA and https://domain/pathB and look up the appropriate host:port in a table or via an HTTP rest service call. Each pathX will have a different place the proxy should get the information from.

We would like to avoid hard coding this informati ...

Score: 0
apache2 docker container writes logs on my host as root user
cl flag

I am running a apache2 docker container on my ubuntu box but it keeps writing logs to my host os. Details below:


FROM php:5.6.34-apache
COPY ./sites-available/mysite.conf /etc/apache2/sites-available/mysite.conf
RUN a2dissite 000-default.conf
#RUN a2dissite default-ssl.conf
RUN a2ensite mysite.conf



<Virtu ...
Score: 1
JDias avatar
Apache CustomLog directive failing - pipe
in flag

I have the following directive in my apache2_site.conf file:

        CustomLog "|/home/me/ %h \"%r\"" common

which should create a log in my MySQL server. starts with:

import pymysql
import sys


However, for each request to my site, the logging in my database isn't done.

What appears in /var/log/apache2/error.log is:

AH00106: pip ...
Score: 0
Apache2 writes to /dev/stdout instead of /var/log/apache2/access.log (using docker)?
cl flag

I am running apache2 2.4.10 in a debian docker container using below docker-compose file:

version: '3.8'
    container_name: apache2-php-container
    image: apache2-php-image
      context: ./docker/apache2
      - "8082:80"
      - ./docker/apache2/index.php:/var/www/index.php

with this site.

<VirtualHost *:80>
    ServerAdmin  ...
Score: 1
OpenLitespeed vs. Apache difference for WordPress?
pe flag

What is the biggest difference and concerns about OpenLitespeed (not premium Litespeed) and Apache?

About speed, security and management issues, what should newbies understand? This is not about web hosting service, I mean to install by myself? thank you

Score: 0
How to debug intermittent apache 502s with no error/access log entries?
vu flag

Logs external to us show that requests to our Apache server are occasionally responded to with 502 status. However, there are no corresponding entries in the site or apache-wide access or error logs. I have verified that these files have the correct permissions and ownership and that other content is being written to them.

Our setup is that requests come into Apache and are reverse proxied to doc ...

Score: 0
Ana Mal avatar
Debian web access apache2 for mail server
bo flag

i am responsible for my mail server i am new to Debian and mail server aswell i am facing issue after install the ssl certificate the page still shows http:// not https:// i use to see this command root@mail:/# apachectl -S

the output comes like this

*VirtualHost configuration:

*:80          (/etc/apache2/sites-enabled/000-default.conf:1)
*:443         (/et ...
Score: 0
Tom avatar
Apache Mod_RemoteIP Support
bf flag

I currently have an old Apache 2.4.18 server on Ubuntu 16.

Does this version of Apache support mod_remoteip?

I looked in the mod_remoteip documentation, but I haven't found about the minimal version of Apache that it is supported.

Score: 0
RewriteMap not working as expected
cn flag

I am trying to block access to certain url :

I have a blacklist.txt file that contains the following :

questions/topic deny

and then I have the following in the configuration :

 RewriteMap access txt:path_to_blacklist.txt
 RewriteCond ${access:%{REQUEST_URI}} deny [NC]
 RewriteRule .* - [F,L]

but I found that I still can open ...

Score: 0
Returning custom HTTP status apache2
ru flag

I'm hosting a webpage with apache and would like to be able to return custom HTTP status codes on a certain page. PHP does this just fine with http_response_code($code) but once it gets to apache it fails with HTTP 500. I have found where the http responses are defined in the apache source, but is it possible to modify this in configuration and without recompilation?

E.g. what's the easiest way to get c ...

Score: 0
Difference between a filter and a handler in Apache
cn flag

I am trying to understand Apache architecture, but I struggle to understand the difference between filters and request handlers. It seems that filters are run immediately to handle any bytes received from the client (so it is basically L4), then Apache parses the request (to decide if it's a valid GET, POST etc) then calls all the request handlers, then it calls output filters. Is this understanding cor ...

Score: 0
How to redirect all subdirectories to a specific directory?
es flag

Say I have that redirects to

RewriteEngine  on
RewriteRule "^/$" "/app/" [END,NE,R=permanent]

I also want to redirect everything to

So, or or redirects to

RewriteEngine  on
RewriteRule    "^/$" "/app/" [END,NE,R=permanent]
RedirectMatch  permanent "^(/(?!app/).*)" "/app/" 

It works for the root to ...

Score: 0
O'Niel avatar
Apache2 serves PHP as plain text after updating to PHP 8
in flag

I just updated from PHP7 to PHP8. Now my Apache2 is going crazy. The server is or not accessible, or shows my PHP as plain text.

php -v

iel@MacBook-Pro-van-Niel apache2 % php -v
PHP 8.0.12 (cli) (built: Oct 21 2021 14:38:26) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.12, Copyright (c) Zend Technologies
    with Zend OPcache v8.0.12, Copyright (c), by Zend Technologies

cat /var/log/apac ...

Score: 0
How to limit who can upload to my webdav server
cn flag

I have a linux server (ubuntu 20.04) with apache2 and webdav setup so I can PUT my live output from a media encoder (MPEG DASH and HLS). This same server also hosts the media then for users (small user base), I feel a little exposed with webdav is there any way to just set it so that only specific IP addresses can upload whilst still offering open web access for downloading?

Score: 0
farroh avatar
htaccess match all words until last slash and redirect 301
cn flag

I'm trying to escape everything until the last slash, even if there's a slash in between. Example:






How could I achieve this with Nginx or Apache?

Score: 0
Apache Redirect for HTTPS (Nextcloud) leads to redirect loop
co flag

How can I correctly configure Nextcloud and Apache, to have correct URL redirection?

I have configured Apache for redirection of HTTP to HTTPS, using a simple Redirect directive:

<VirtualHost *:80>
    ServerName ""
    Redirect permanent "/" ""
</VirtualHost>  # *:80

<VirtualHost *:443>
    ServerName ""
    ServerAdmin "webmaster@exampl ...
Score: 0
Hacked file regenerates whenever it is deleted - ubuntu/apache2
ph flag

Have just had a hacked website flagged by Sucuri

There were a number of backdoor PHP files flagged, which I HAVE been able to delete

However, the index.php file has a spam link injected in to the bottom of it.

I've tried deleting it - which DOES work, but file instantly regenerates.

I've tried changing permissions (it is set to -rw-r--r-- www-data:www-data) to root and editing the file - it instantly cha ...

Score: 0
Ubuntu 18.04: PHP stopped working after I tried to fix phpmyadmin
in flag

I have a problem with a Ubuntu 18.04.6 Ubuntu server. I was trying to fix a problem with phpMyAdmin (a lot of errors appearing on screen, and preventing me to use it, pointing to some authorization error). What I did is:

  • I tried to reinstall phpMyAdmin (failed because of this error access denied for user 'debian-sys-maint '@' localhost using password 'yes')
  • I fixed the authorization issue
  • I reinstal ...
Score: 1
Apache configuration doesn't update on restart
in flag

I'm running a LAMP development server with Apache/2.4.41 on Ubuntu 20.04.3 LTS (5.11.0-38-generic).

When I modify apache or php configuration files such as apache2.conf or php.ini and then run
service apache2 restart
systemctl restart apache2
I'd expect the changes to apply, but they don't.

I've also tried service reload apache2 just in case and also tried just waiting a few minutes, but the only thin ...

Score: 0
Bix avatar
Does certbot mask apache2?
cn flag

I recently ran a certbot command using --webroot on a server. Everything worked fine for 8+ hours.

This morning my frontend went down. Upon investigation I discovered that the apache2 service was down. It was masked for some reason so I unmasked it. It restarted but did not work. I tried to run a configtest but apache2ctl was not found. I ran sudo apt install apache2. Now everything is working ag ...

Score: 0
apache2 vnc proxy to proxmox (with intermidiate php application)
mx flag

he have a php application that has access to proxmox and display the vnc console by sharing the token. this is in a apache2 server. We try to proxying the vnc requests behind apache so the end user has no direct access to proxmox. The issue based on the logs that there is no handler for apache:

AH01144: No protocol handler was valid for the URL /api2/json/nodes/server/qemu/vmid/vncwebsocket (schem ...
Score: 0
mod_evasive: DOSPageCount and NAT
bm flag

When configuring mod_evasive am I correct in the assumption that only the potential attacker's IP address is considered and nothing else? If that's the case I find it strange that everywhere for DOSPageCount a value of 2 is suggested (With DOSPageInterval 1). It's quite common for any website that say two colleague or even a group of classmates are in the same network (say WiFi) and browse to the same w ...

Score: 0
Apache web page on local network accessible from iPhone and another computer on same network. Why can't I reach it from a third?
cn flag

I have looked at the Similar Questions and searched on the web. Most answers are for very specific instances of Rails, or using Eclipse, or trying to access from outside the local network to a server on the local network or often there is no answer.

I am running a simple webpage 'index.html' on a mac mini with a fixed ip on my local area network of The webpage can be accessed from out ...