Apache IP question


 
Thread Tools Search this Thread
Special Forums IP Networking Apache IP question
# 1  
Old 06-15-2014
Apache IP question

Hey everyone. Ok I have a question..well a few questions actually, but I'll try to have them make sense.

Ok, I work in a data center and we manage people's servers. One client has an apache server. This apache server has 1 single IP address. When I do ifconfig, it's inet address is 1 address.

That being said, he has multiple different, independent sites on the sever. When I do a dig command to each individual site that's hosted by this one sever, I get a different IP. None of the IP's for those sites match the main IP of the server.

With that in mind when I look at the virtual host directives for each individual site, I see the :<VirtualHost *:80>
Meaning that it's listening for any IP. But most of the sites have this "Listen to all" directive.

So with all of that knowledge, my main question is thus. Where are the individual sites's IP's coming from? Again when I do a dig for these sites, they definitely have an IP address, all of them unique as well. But I see no reference to them in the vhost files. The only thing in their vhost files is the 'listen for all addresses" directive


What's interesting is that when I type in the individual site's IP address, I get an apache page that says site is under construction etc.... but when I type in it's domain name, the site loads properly. So if the VirtualHost directive to listen to all IP's is in play, why does the site's IP's not work when typed into a browser?

Thanks everyone in advance!
# 2  
Old 06-15-2014
If the IP's you're getting from "dig" aren't associated with the server running Apache, then HTTP requests sent to that domain aren't routed to the Apache server directly.

So if they are getting to that Apache server, then the IP's from "dig" are probably for a load balancer or some other front-end. As long as the right HTTP headers are presented, specifically with "Host:" headers that match the VHOST definitions, the fact that there's only one IP address doesn't make a difference.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

Process not running: /opt/java15/jdk/bin/java -classpath /opt/apache/apache-ant-1.7.0-mod/lib/ant-la

Have no idea on what the below error message is: Process not running: /opt/java15/jdk/bin/java -classpath /opt/apache/apache-ant-1.7.0-mod/lib/ant-launcher.jar org.apache.tools.ant.launch.Launcher -buildfile build.xml dist. Any help? (3 Replies)
Discussion started by: gull05
3 Replies

2. Web Development

Apache module development on apache 2.2

Hi, I'm new to developing modules for Apache. I understand the basics now and can develop something simple which allows a 'GET' request to happen, but what I want to do is actually 'POST' information to my site. I know the basic POST Request works and I can see that it is post by looking at... (2 Replies)
Discussion started by: fishman2001
2 Replies

3. Red Hat

Apache question - virtual host related

Hi folks, I recently read about Apache virtual host and was able to configure that as well. I used name based virtual host (lets say http://vhost1.example.com) and it worked just fine. Then I configured another named based virtual host on same apache server (lets say http://vhost2.example.com)... (2 Replies)
Discussion started by: freebird8z
2 Replies

4. UNIX for Advanced & Expert Users

Question regarding Apache

How can I know which Multi-Processing Module does my Apache use or implement. Module Index - Apache HTTP Server I also wish to know what is the maximum number of clients can my apache process at a given instance of time. Please help me calculate the same. Also, wanted to know if the... (0 Replies)
Discussion started by: mohtashims
0 Replies

5. UNIX for Advanced & Expert Users

Double question: Apache mod_proxy and force connection over specific interface

Double question here ... Running on Debian Etch and Apache 2.0 1) Using mod_proxy and/or mod_proxy_http in apache 2.0. The basics of using mod_proxy are pretty simple so long as you're using a static config. I'm trying to figure out how to do it dynamically - that is, allow the entry of a... (4 Replies)
Discussion started by: Halfwalker
4 Replies

6. UNIX for Dummies Questions & Answers

Apache question

Folks; What's is the risk of running 2 Apache servers on the same machine, one for testing & the other for Production? (using 2 different ports of course) Thanks (1 Reply)
Discussion started by: moe2266
1 Replies

7. Solaris

Installing APACHE - simple question

Ok, this may be a simple question, but I am unable to find an answer. I am trying to install apache 2.2 on a Solaris 9 box (sparc). I downloaded it from sunfreeware, and under /usr/local/apache2/doc/apache2/INSTALL they describe the installing procedure as: $ ./configure --prefix=PREFIX ... (4 Replies)
Discussion started by: fidodido
4 Replies

8. Cybersecurity

Apache Question - Securing against unwanted use with cable modem

I have built a Linux machine in my home using Mepis Linux and I'm running Apache on it. I want to use Apache on my machine and use it as testing area for web pages and other applications. I use a cable modem to connect to the internet. The Linux box is connected to a router, which connects... (3 Replies)
Discussion started by: Doctor_Morbius
3 Replies

9. Solaris

Apache web server question

Hi - Maybe not the right forum for this but I will ask anyway.. I recently installed apache on my ultra 10 - solaris 9... Working okay - and I have some docs in my htdocs directory that I can access through a web browser.. Now I want to get a bit fancy and change the home page so I can... (2 Replies)
Discussion started by: frustrated1
2 Replies

10. UNIX for Advanced & Expert Users

Apache auth question

While not technically a unix question, I was hoping for some help from you all- I've got an Apache 1.3.x server, and I am using basic auth from the pam_auth module and winbind on the back of that. What I get is a relaly sleek authentication for my Windos domain users, however, as they are wont... (1 Reply)
Discussion started by: loadc
1 Replies
Login or Register to Ask a Question