Stack Exchange Network

Stack Exchange network consists of 174 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 [httpd.conf]

httpd.conf is a typical name for a web server configuration file. Historically this is the main Apache configuration file.

-2
votes
1answer
64 views

Multiple websites on same server

When running multiple websites on same server: root/website1 root/website2 root/website3 What should be done to make these websites run intependently - I mean to completely restrict access of PHP (...
-1
votes
0answers
443 views

mysqli_real_connect(): (HY000/2002): No such file or directory

Well i'm facing this issue which happened after i installed httpd-mpm-itk and i tried googling and i couldn't find a similar issue as my problem. Here is my config.inc.php: $cfg['Servers'][$i]['...
0
votes
1answer
69 views

How do I use a custom variable in an If-Else statement inside an Apache config?

Here's my code (I've commented out the if-else part as it's not working) snippets/contents of my config files /etc/httpd/conf.d/staff.vhost Define host_domain "staff" Include /etc/httpd/conf.d/...
3
votes
1answer
68 views

How to exclude RewriteMap if REQUEST_URI is not found

I have an old site wordpress site I am in the process of migrating. There are about 50000 urls that need to be redirected. For this I am using DBM files which seem to be working fine, however during ...
0
votes
0answers
37 views

Invalid command 'DeflateCompressionLevel', perhaps mis-spelled or defined by a module not included in the server configuration

Iam trying to run apache http server in my linux device when I am giving httpd start command to run apache server I am getting an error " Syntax error on line 1043 of /usr/conf/httpd.conf: ...
0
votes
1answer
28 views

Proxy directory to another url with httpd proxy

Currently Im trying to forward a directory in my domain to domain with port. The reason I'm trying to do this is because my server is apache but I need to access just one node file. I'm posting some ...
0
votes
1answer
42 views

Apache24u / phpinfo: still showing old version

Ive upgraded the server from default apache 2.4.6 to the apache24u (https://centos.pkgs.org/7/ius-x86_64/httpd24u-2.4.34-1.ius.centos7.x86_64.rpm.html). when I check it via shell, I get the correct ...
0
votes
0answers
151 views

Upgraded httpd 2.2 to 2.4, server generated directory index forbidden by options directive

I keep getting the 500 internal error when going to my website's IP address. I haven't set up a domain name for it yet. Upon checking for error's on the apache error log at /var/log/httpd/error_log I ...
1
vote
1answer
273 views

Apache: No matching DirectoryIndex

I'm newbie in apache, i have the following directory structure: html |-- moodle |-- singapur |-- app |-- public |-- js |-- css |-- img |...
0
votes
1answer
1k views

Apache 2.4 updated, now throws: Cannot define multiple Listeners on the same IP:port

I've just updated Apache to 2.4.3 on my AWS instance (running Linux AMI). After the update finished, Apache crashed with the following: Starting httpd: AH00526: Syntax error on line 5 of /etc/httpd/...
0
votes
2answers
15 views

Including 2 CAs in VirtualHost in Apache using httpd for https phone/server handshake

Please bare with me, I'm new to configuring SSL. I'm trying to load a server cert from godaddy so have xxxxxxx.crt, and bundle.crt, I've made a key/csr which we used to create the certs. I'm now ...
0
votes
1answer
39 views

httpd.conf redirect / to 8080 and redirect /index.html to /app/index.html

How can create this conf on httpd.conf: user access http://site and see content from http://site:8080 but when they access http://site/index.html, it should redirect to http://site/app/index.html ...
1
vote
1answer
44 views

How to force Apache to skip binding to failed interface? [closed]

I run Apache inside VirtualBox on a laptop. I also used IP based VirtualHost-s. I want to be able to have LAN access whenever I move about, to certain pre-known networks. The IP, however, is not "...
0
votes
2answers
362 views

How to configure <Location> Directive specific to a Location/Directory on Apache Server and not on Server Level?

I am new to Apache Server Configuration. I went through the Apache Documentation and tried to understand the Basics as well as the Directives. But still, I am not able to figure out a configuration ...
0
votes
0answers
23 views

how to make HTTP/2 server push work with all directories in Apache

How do I make server push header links work with all websites/apps regardless of where the file is located? Header add Link "</main.css>; rel=preload; as=style" Header add Link "</main....
0
votes
2answers
217 views

Apache with PHP running CGI mode: The php executable processes itself, what do I need to change in the config

I'm trying to install a pre-Iraq-Surge 4.4.9 PHP in a modern Apache 2.4.6 and want to run it in CGI mode. The current configuration is as follows: The PHP executable is /usr/local/php-4.4.9/bin/php ...
-1
votes
1answer
56 views

Multiple websites on single bind dns server

I am using CentOS 6, BIND and HTTPD I have created 3 machine: DNS Server, HTTPD Server, Client Machine - All are working in a virtual environment under VMWare. IP of DNS server is: 10.0.2.16 IP of ...
0
votes
1answer
93 views

Apache on SLES only starts https with -D SSL arguments

I've been hacking up this server for a few days trying to convert a new installation of apache to HTTPS with the plan to convert it to NSS once I have SSL running properly. This server is not ...
0
votes
1answer
174 views

Apache httpd configuration: sysconfig/apache2 and apache2/httpd.conf

I'm new to Apache and Linux, and I'm reading through httpd.conf. I've come to a line in default-server.conf where it says: # UserDir: The name of the directory that is appended onto a user's home ...
0
votes
1answer
30 views

Apache config precendence

If I set a configuration option in httpd.conf which is not used again in any of our vhosts, will it be in effect for each of the vhosts or will each one need to have the option set? Specifically, I ...
0
votes
1answer
59 views

reverseproxy to connect multiple backened server from single virtual host

I have a apache http server that acts as proxy to connect to backened app servers. e.g. MachineA(https) -> MachineB(reverseproxy) -> MachineCn(App) Here MachineA(Public_lb) port 9002 is mapped with ...
1
vote
0answers
54 views

Why access control and authorization dont work together in Apache

I have a Centos Linux server with Apache 2.4 and having multiple virtual sites. I spent a lot of time implementing access control on the basis of ip but failed. I now realized that access control ...
1
vote
0answers
1k views

HTTPS to HTTP SAML SSO using mod_auth_mellon

I have a simple HTTPS to HTTP reverse proxy using Apache HTTPD (CentOS) I have enabled mod_auth_mellon for SAML SSO, it works fine if I have a simple http proxy without any virtual host. When I ...
0
votes
1answer
178 views

Which HTTP header maps to Apache's %u log format token?

We have an httpd.conf that contains the following log format and uses the %u token for logging the remote user: LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %D" combined ...
1
vote
0answers
50 views

Is there a more verbose version of the command `httpd -S`?

The command httpd -S displays your VirtualHost's and Configuration Files, and the IPs and Ports they are listening on. Is there a similar command that also shows you the directives applied to teach ...
-2
votes
1answer
109 views

Apache LoadBalancer URL rewrite

I have one URL http://ip:port/Parameter (apache LoadBalancer), If I hit this URL, apache LB should rewrite URL as http://ip:port/application/Adaptor/Parameter. Parameter this value will change ...
0
votes
1answer
454 views

reverse proxy with multiple sessions in same browser

My reverse proxy seems to be mostly working, though when I open sessions to different backend servers, within the same browser, I get this message from the browser (tested with Chrome and IE): ...
0
votes
0answers
51 views

Run Apache macro for initial loading of config file only

I had hoped to define a simple Macro that only gets executed during the first-time loading of httpd.conf. I moved this macro to the top-level of the conf file, and noticed it gets executed frequently,...
1
vote
0answers
44 views

Transmission web UI and ERROR 405

I have transmission-daemon listening on port 9091. This is proxied by a virtualhost site in apache2 using ssl. I managed to get through the infamous ERROR 409 due to my a missing / in the last part ...
0
votes
0answers
52 views

correct php-fpm + httpd configuration to provide individual user permissions and denying all other

I tried a lot of tutorials found on the web to implement the above mentioned configuration but was unsuccessful ,even though the php handler changed to php-fpm i can't implement the individual vhost ...
0
votes
1answer
1k views

Apache conditional config with if-else directives

Rather than commenting/uncommenting alternative configuration settings in my httpd.conf file, I would like to use something like this: <If "0"> # ... </If> <Else> # ... </...
0
votes
1answer
159 views

Apache Redirect Loop on Drupal Installation in VHost SubDirectory on Root URL only

I am currently having an issue with our Production site Home Page of a Drupal installation failing with "ERR_TOO_MANY_REDIRECTS". A little background to our set up: On our server, we have different ...
1
vote
0answers
46 views

How to pass part of URL to ProxyPass in Apache

I am hitting the URL http://example.com/ws/abc. Now I need to proxy a server with URL https://server.com/abc. I have tried the 2 methods below to proxy. But it is not working. RewriteRule ^/ws/(.*) "...
1
vote
1answer
725 views

Apache Conditional Redirect HTTP to HTTPS

all. I have a syntax problem. I've tried following other sources, but It's just not working. I've successfully created an unconditional HTTP to HTTPS redirect. Go to http://www.robjvargas.com, ...
0
votes
1answer
478 views

Do httpd/conf.d/* files override httpd.conf

If there is different configuration for the same parameter in both conf/httpd.conf and a /conf.d/* file, which will take precedence? I can’t find this explicitly stated in any official documentation.
0
votes
1answer
2k views

Redirect http to https return double slashes

My System is Centos 7 and Apache 2.4.6 I need to redirect http to https using Apache httpd.conf, I googled hundreds pages and I found some codes but this is good and not hard coded from DigitalOcean ...
1
vote
3answers
404 views

Htaccess Require expr Apache 2.4 works on osx-sierra not on debian-jessie

On my development machine osx-sierra / apache 2.4.10 (from brew) I have a restriction in a VirtualHost that allow access to /api/ without password, and all others pages need the password with this ...
0
votes
0answers
134 views

Python app not working with Apache + Passanger

I have a python app, and I'm trying to deploy it to a production server. I have a CentOS 6.9 VPS Server version: Apache/2.4.29 (cPanel) Server built: Jan 17 2018 14:02:24 I followed this tutorial:...
0
votes
2answers
681 views

Apache httpd serve a 200 response with static resource if requested file is not found

I am looking for a way to configure httpd server to respond with an image if requested file is not found. I know it can be simply done by: ErrorDocument 404 "/static/thumbnails/404.png" This one ...
0
votes
2answers
56 views

CentOS / Apache - Virtual Hosts Port Not Loading

What I've Tried I will begin by saying that i've looked across this site at a few questions and answers and have not found a solution. Most of the solutions i've come across, the fix has been to ...
0
votes
2answers
45 views

Apache access.log: unauthorized user able to request files on my localhost dev machine

I have Apache2.4 installed on my dev PC (windows 10) Viewing my Apache24\logs\access.log file, I noticed suspect entries such as: www.-----.com - - [01/Jan/2018:10:45:19 -0200] "GET /SOME-PERSONAL-...
0
votes
1answer
683 views

Reverse proxy for wildcard domains - apache linux

I am trying to setup reverse proxy for wildcard domain, but my configuration don't simply work after I login to the application. This server is running Apache aka httpd service with port 80, 443 on ...
5
votes
1answer
6k views

Can't restart httpd.service on CentOS 7 (Apache server)

I used the command "service httpd restart" on my centOS apache server, and the following error occurred: Job for httpd.service failed because the control process exited with error code. See "...
0
votes
1answer
470 views

RemoteIPInternalProxy / RemoteIPTrustedProxy [duplicate]

I guess I'm stupid or what but I don't get this: I'm using the RemoteIPHeader X-Forwarded-For within a VirtualHost configuration in order to determine GEO location of our users within our PHP ...
0
votes
1answer
114 views

Apache 2.2 conf file multiple directives

I have an infrastructure on AWS, and yesterday, it presented intermittence with the message that CloudFront attempted to establish a connection with the origin, but was unable to. Apparently, but I ...
0
votes
3answers
5k 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 ...
0
votes
1answer
33 views

Matching domain structure on staging server on LAN?

When we develop websites on the staging server (CentOS) on the LAN, we end up storing it in something like: /var/www/html/project1.com And to access it through a web browser on the LAN: http://...
3
votes
1answer
273 views

Apache 2.2 / CentOS: Denying Bad Bots

I'm having all kinds of problems trying to restrict bad bots on my Apache 2.2 server, and am hoping somebody can assist. I have banged my head on the wall for days trying to get this working, and ...
1
vote
1answer
964 views

403 forbidden in httpd on Fedora 27

My server returns the following error over and over with the permissions set as below. This is the virtual host running on Fedora 27. From /etc/httpd/conf/httpd.conf at the bottom of the file: ...
0
votes
2answers
1k views

Web server showing IP address instead of domain name

I'm running a web server (Apache2) on CentOS 7. I have the following virtual host file. The site is being served as it should. However, the URL is changed in the browser (any browser) from the domain ...