Skip to main content

Questions tagged [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)

Filter by
Sorted by
Tagged with
0 votes
1 answer
367 views

Apache2 how to generate random string for subdomain

I want to issue a redirect to a new randomly generated subdomain name for every request I get. Below you can find my vhost configuration. I want to do a redirect towards a subdomain containing some ...
Mnemosyne's user avatar
  • 131
0 votes
0 answers
446 views

Apache halts with error: Invalid argument: AH00146: couldn't release the accept mutex

My webserver running Debian Bullseye has been running for years without any problems. Everything is up to date. The apache version is 2.4.54. Yesterday I noticed none of my websites were up so I ...
Zippy1970's user avatar
  • 289
1 vote
0 answers
80 views

nftables and OCSP stapling

My apache error log shows: AH01972: could not resolve address of OCSP responder ocsp.usertrust.com Main reason is my server's nftables blocks any requests to the Internet. In my opinion web server ...
gorek's user avatar
  • 11
0 votes
1 answer
515 views

Application slows down (SOMETIMES) at peak times, running on tomcat with a reverse proxy from apache server, deployed on AWS

Just for preface: I'm a software developer and at first no one knew what's going on, so I did some testing and reading, and would like to help my colleagues fix this problem. The issue: The issue is ...
Stefan Horvath's user avatar
-1 votes
1 answer
61 views

I'm in trouble with .htaccess RewriteRule

I'm trying make to a social platform like Instagram or Facebook and I wanna to show users, username like that examplesite.com/usernamehere so in the url. I'd been researching how to do this and I ...
Zafer İnci's user avatar
1 vote
1 answer
187 views

How Can We Do 301 Redirect Of Over 200 Pages To Corresponding 200 Pages At New Location?

I need help and need it fast. We recently migrated a subdomain to integrate with the domain. Eg. https://blog.example.com to https://www.example.com/blog https://blog.example.com has a ton of traffic ...
user18571's user avatar
0 votes
1 answer
145 views

Apache not serving local hosts

I have set up an Apache Server on an a VMWare hosted Linux Mint 21 Server, I have followed the instructions at this blog to run multiple PHP versions (7.4 and 8.1). Apache is running fine and serving ...
deep64blue's user avatar
0 votes
2 answers
1k views

I get directory listing instead of the website index.php

Ubuntu 20.04, Apache 2.4, PHP5.6 I have website with the following vhost config <VirtualHost *:80> ServerAdmin [email protected] ServerName website.com ServerAlias www.website....
igalsc's user avatar
  • 11
0 votes
2 answers
804 views

After setting up Apache it's not serving PHP files, but showing the contents of the files instead

The error I got is in this url: url in browser: http://localhost/ error in browser: https://justpaste.it/d82bd What am I missing here? I copied the file ipconfig.php (given below) from ipconfig.php....
Love Grover's user avatar
0 votes
1 answer
267 views

Apache2 non-default root directory multiple websites 403 forbidden

I have Ubuntu 20.04 servers on AWS in autoscaling group with EFS mounted at /mnt/efs/fs1 I use codedeploy for deployment of a non-default website. The bitbucket pipeline creates a zip file containing ...
igalsc's user avatar
  • 11
0 votes
2 answers
134 views

How to show an internal static page to IP addresses list? [closed]

I have a ubuntu 22.04 server, a list of ip addresses of users on my local network and I want to redirect http/https traffic from this list to a local informative html page. Similar to how a hotspot ...
acgbox's user avatar
  • 398
-2 votes
1 answer
48 views

How to configure a sites-available entry for mediawiki on RPi behind firewall?

I am trying to define a sites-available .conf entry for a mediawiki scratch installation on a Raspberry Pi 4 running Raspbian in my local network (behind the firewall). No DNS or domain name ...
Juan Jimenez's user avatar
0 votes
1 answer
181 views

Apache include value of %{TIME_YEAR} variable in an HTTP response header

I'm trying to do something like the following: <If "%{IPV6} == 'off'"> Header always set Attention "you are using still using IPV4 in %{TIME_YEAR}, please blahblah etc" <...
Displayname71's user avatar
1 vote
1 answer
1k views

Nextcloud installation broken after upgrading to Ubuntu server 22.04

I'm currently running Nextcloud on Ubuntu server. After upgrading from 20.04 LTS to 22.04 LTS, I couldn't log into Nextcloud. I switched the PHP modules from 7.4 to 8.1 as recommended in this forum ...
David Chidester's user avatar
1 vote
1 answer
257 views

How to **keep** my SSLCipherSuite list for my LAMP stack current?

I have been running several LAMP servers for 5+ years with Let's Encrypt certs. Today, I did the SSL test by Qualys https://www.ssllabs.com/ssltest/index.html to learn that I had lost my coveted A+ ...
wruckie's user avatar
  • 697
0 votes
0 answers
2k views

How to use environment variable in apache config condition?

In my apache config file I'm trying to set a virtual host on port 443 IF my environment variable is not dev I have a docker container running via docker-compose which specifies the environment ...
David's user avatar
  • 11
0 votes
1 answer
295 views

Exclude specific URL from HTTP to HTTPS redirect in apache2 virtual host

I'm looking for an easy configuration to exclude a specific URL(pattern) from my apache2 HTTP to HTTPS redirect and failed so far. Background is an API with typical authorization mechanics which ...
StarFighter's user avatar
0 votes
0 answers
45 views

How do you set up multiple virtualhosts on apache2 using only the server ip and server alias?

I'm trying to set up apache with multiple virtual hosts "filebrowser.com" and "videos.com" however, I'm only able to access filebrowser.com and not videos.com. I also have to enter ...
Brenden Delong's user avatar
0 votes
1 answer
609 views

git-http-backend on apache2 can pull but not push: remote: fatal: not a git repository: '.'

(I had to replace 'http' with 'hxxp' everywhere because otherwise I couldn't post it because apparently this looks like spam) I have set up git on my server (Debian, arm). I use the git-http-backend ...
bicyclesonthemoon's user avatar
1 vote
1 answer
67 views

Apache2 is serving "download" document instead of website

I updated my Ubuntu server this morning from 20.04 to 22.04. Apache2, PHP, Mysql all got updated in the process. I have Cacti installed on this server to monitor a few of our switches and firewall. ...
FACTORY909's user avatar
1 vote
1 answer
162 views

How to use puppet-apache mod (v8.3.0) with hiera?

Queston: Using the roles & profiles method, is it possible to use 'puppetlabs-apache', '8.3.0' with a hiera lookup? Context: I am using mod 'puppetlabs-apache', '8.3.0' to configure an apache ...
John-H's user avatar
  • 11
0 votes
1 answer
701 views

Openstack Glance Configutarion on HTTPS RESTAPI + Nginx Reverse Proxy

I am trying to install openstack Using ssl certs i am able to run keystone (on port 5000) but when i try to connect to glance api (port 9292) it fails it is only accessible with http not https i feel ...
Hoodad Tabibi's user avatar
0 votes
1 answer
222 views

Fix virtualmin domains to use individual php ini files

My server is setup to use virtualmin for managing configurations. In trying to resolve a php issue when a wordpress plugin installation, I inadvertently broke the settings on my domains so they no ...
Mark's user avatar
  • 331
1 vote
0 answers
185 views

Set Apache to Block HTTPS Requests to a Certain Subdomain

I have these domains domain.com www.domain.com srv.domain.com pointing to the same server IP, but want my website to be accessible only via domain.com and www.domain.com which have SSL certificates. ...
UM-Li's user avatar
  • 31
0 votes
1 answer
215 views

Host multiple websites on AWS Auto-Scaling Group with EFS

I hope this is a simple question. Currently I have an Apache2 webserver on Ubuntu with multiple websites. The basic structure of the Apache is /etc /apache2 /sites-available --> the .conf ...
igalsc's user avatar
  • 11
3 votes
2 answers
1k views

SSL_ERROR_RX_RECORD_TOO_LONG after installing Certbot on Apache2

I'm trying to set up a web server on a raspberry pi, it's running a debian based system. I installed and set up apache (following this guide), set up port forwaring on my router and created 3 html ...
Simone's user avatar
  • 31
2 votes
1 answer
2k views

Redirect part of a URL parameter to the URL-Path

I used a module that created links like this: https://example.com/login?create_account=1&back=https://example.com/product/2164/?ets_rv_add_review=1 I need to redirect them to: https://example.com/...
Ehsanai's user avatar
  • 21
3 votes
1 answer
2k views

apache 2.4.54 (httpd) require not ip not blocking ip addresses

So I am running apache 2.4.54 on a redhat centos 7 machine. I am using the below configuration to run my django application with mod_wsgi: # create new #LoadModule wsgi_module modules/mod_wsgi.so ...
Shmack's user avatar
  • 141
1 vote
1 answer
368 views

.htaccess redirect if param value not portuguese-pt (FORCE WHMCS ONLY ONE LANG)

I need help to redirect URLs with multiple language codes to one with .htaccess. The following URLs should redirect: https://example.com/cp/cart.php?a=add&pid=7&language=us https://example....
Pouyan Danesh's user avatar
2 votes
1 answer
315 views

How can Apache log whether requests are using HTTP2 or not, in a manner that can't be easily spoofed by the client?

According to this, including %H in your LogFormat is supposed to log the HTTP protocol version, however, it appears to be unreliable. As an example, one can telnet to port 80 of the web server and ...
Displayname71's user avatar
1 vote
0 answers
151 views

Enable Brotli for Apache on Google Cloud Compute Engine website

I installed and enabled the Brotli module just fine through SSH. Then, I added this to my port 80 VirtualHost config: <IfModule mod_brotli.c> SetOutputFilter BROTLI_COMPRESS ...
JimmyTheCuck's user avatar
1 vote
0 answers
22 views

Redirect docroot for specific URI path by .htacess

Is it possible to redirect a specific URI path to a specific docroot within the original docroot using the .htaccess? For example: example.com > docroot Where example.com/path > docroot/subdir
Eng7's user avatar
  • 137
0 votes
0 answers
159 views

unable to load files in /var/www on localhost

I don't know why, but until recently, I could load files located in /var/www/ by typing the folder name in my browser, and I could load files located in /var/www/html by using localhost/<> Now, ...
dsb27's user avatar
  • 1
1 vote
0 answers
377 views

Automatically remove Set-Cookies

I have a php web application. This web application sets some cookies. I want to write a .htaccess which remove on the fly this cookies. Here is what I've done, with mod_header: Header unset Set-Cookie ...
Bob5421's user avatar
  • 429
0 votes
1 answer
76 views

Way to save apache losgs with IP Info

i use this command to live see apache logs: sudo tail -f /var/log/apache2/access.log I use a Ubuntu 18 VPS wich i have root access. this logs are also saved to the access.log file true? (because when ...
Diego's user avatar
  • 1
0 votes
1 answer
1k views

modsecurity wont start with an apache server

I have a Debian server where apache2 is running. I want to use modsecurity for throttling. apache2 info $ apache2ctl -v Server version: Apache/2.4.29 (Debian) Server built: 2018-01-14T11:01:58 I ...
Hussain Nagri's user avatar
1 vote
1 answer
144 views

HTTPD different vhost & reverse proxy settings for subfolders on same host&port

Please, I have been trying to configure httpd with no luck. I need following behavior: if I access https://example.org/, https://example.org/anything/.../... -> I need proxy to localhost:8080 (...
tomas's user avatar
  • 133
1 vote
1 answer
478 views

Apache 2.4 - allow access from same IP and from curl Request

I want to provide access to requests from the same server that apache is running on and to curl requests, but this section does not work, neither the first nor the second match. What am I doing wrong? ...
Lokomotywa's user avatar
0 votes
0 answers
228 views

Apache2 not working with PHP

I have Apache2 running on a Debian 11 box (x64). It was installed with an Openmediavault ISO, with nginx and PHP 7.4 installed already (for the web UI) I try to install the PHP connector for apache2 (...
EnderSlayer7692's user avatar
0 votes
1 answer
264 views

apache2 with PHP-FPM truncating error_log messages

I have an apache2 server configured to serve multiple websites with php-fpm. Each websites has a custom error_log file ErrorLog "/var/log/apache2/error_log-example.com" using the following ...
Luca Ricci's user avatar
2 votes
1 answer
2k views

Get Url Parameter from Request and store it in variable in apache config

In my apache config, I want to allow access only when a specific url parameter matches a specific cookie. I imagine a solution looking similar to this (in pseudocode): param = ...
Lokomotywa's user avatar
0 votes
1 answer
117 views

What should be in mysql replication MASTER_HOST='source_host_name'

I am trying to setup replication across two servers on AWS. I am following the documentation and I am up to this point. https://dev.mysql.com/doc/mysql-replication-excerpt/5.7/en/replication-howto-...
user1794918's user avatar
1 vote
1 answer
1k views

How to serve static images from /tmp in Apache

How do you serve images from Apache that exist outside the document root? I have a devops process that runs builds for a UI testing build, which generates screenshots and stores them to /tmp/images. ...
Cerin's user avatar
  • 3,670
0 votes
0 answers
34 views

IF-Directive in Apache Config that calls bash script

How can I make an If-Directive in apache config that is executed in case of an external bash script returning true, like this example: <If call_bash_script.sh > Require all granted </If>
Lokomotywa's user avatar
3 votes
2 answers
1k views

SEO friendly URL not working

I have a folder structure like the below www.exampe.com/distributor/index.php and I want to access the file via an SEO friendly www.example.com/distributer/abcinc and then in the index.php want to ...
Jayreis's user avatar
  • 145
1 vote
0 answers
1k views

Error 503 Service Unavailable

We have a debian based reverse proxy server which is under testing for product scanning for a store and all of a sudden it didn't connect and started showing 503 service unavailable. The next day it ...
sameer's user avatar
  • 19
1 vote
1 answer
298 views

Requests with lager than 1GB data fail after upgrading to Apache 2.4.54

Sending requests with larger than 1GB data always fail after upgrading to Apache 2.4.54. In Apache 2.4.53 and older versions, the LimitRequestBody limit was set to unlimited. It seems that this has ...
5t111111's user avatar
  • 111
1 vote
1 answer
300 views

if a domain does not have an ssl certificate, load the certificate from another page in apache

I have an apache server configured as a virtual host (name-based), suppose that the ip is 186.54.251.57, if I enter that ip address the apache home page will be displayed... if I enter example1.com ...
Andrés Alvarez's user avatar
1 vote
0 answers
60 views

rewirterule in apache conversion to nginx equivalent rewrite rule

Apache server rewrite rule has been written below: RewriteEngine on RewriteRule "^/cesop(.*)$" "http://LSVCHN-EPAP01/cesop$1" [P] In Internet browser, type below: https://...
Radhakrishnan Meiyappan's user avatar
0 votes
1 answer
69 views

Can apache return multipe ErrorDocuments for the same response code depending on a header value?

So let's say I have a 403 page but if the request header has a custom value in it - I want to return a different 403 with a bit more information in. So the normal 403 location may be /error_403 and ...
overrrflowww's user avatar

1
3 4
5
6 7
36