Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have one webserver and one Application server.

Webserver1 have FreeBSD 8.1, Apache, MySQL and PHP. Application1 server have Centos 5.5, Apache, Mysql and PHP.

Both server running fine independently. My webserver1 is hosting my company website which running good. Besides I have 2 online application which requires me to host them as a subdomains.

My questions is I want to make subdomains such as and is accesscible from Application1 server. Can anyone pls help me on this. What should I do on apaches configuration on both webserver1 and Apps1 server. I only have 1 NIC card on my Apps1 server.

Really appreciate anyone who got the solution. Thanks Azrim

share|improve this question
If you only have 1 NIC card, I'm not really sure what you can do. Can the server without the NIC card connect to the network at all? – jmort253 Jan 3 '11 at 4:26

You'll need to setup virtualhosts on the apache server The config will look something like this:

NameVirtualHost IP:80
<VirtualHost IP:80>
   ServerAdmin     EMAIL
   DocumentRoot    /PATH/TO/WEB/FILES
   ServerName      SERVERNAME

It won't be exact, but that should get you on the right path.

share|improve this answer
How does he get traffic to the machine that doesn't have a NIC card? – jmort253 Jan 3 '11 at 4:32
Nevermind, his question wasn't clear initially. 1 NIC card on the apps server should work for multiple domains. – jmort253 Jan 3 '11 at 4:33
@jmort253: I think you misread his question. Apps1 has only one NIC. – GregD Jan 3 '11 at 4:33
I sure did... now it's clear :) – jmort253 Jan 3 '11 at 4:35
Do I need to config that virtualhost on my webserver1 or apps1 server? – Azrim Jan 3 '11 at 4:49

  DocumentRoot /var/www/html/abc

  DocumentRoot /var/www/html/xyz
share|improve this answer
above is my code...kindly advise.. – Azrim Jan 21 '11 at 8:48

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.