944,129 Members | Top Members by Rank

Ad:
Nov 1st, 2006
0

Muitiple domain names to multiple websites on Linux and Apache

Expand Post »
Hi,

I am a very beginner and have been told to sort this out for my company as the person that created the system has gone into the military.

We currently have one domain with many sub-domains which is forwarded from domain company A to our Linux server which then deals with the correct folder and website to display. Also, one domain is a https which gets sent to a windows server.

We now have a second domain name with a second domain company and will be forwarded to the same Linux Server. The two domains only differ with .com and .fr .

In Linux or apache how do I send traffic for this new domain and sub-domains including the one to the windows server to there own totally separate folders.

I really need step by step simple instructions as I have never really used Linux or Apache before.

Any help would be greatly appreciated as I do not know where to start.

Nigel
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
nrobinson is offline Offline
2 posts
since Nov 2006
Nov 1st, 2006
0

Re: Muitiple domain names to multiple websites on Linux and Apache

What you'll need is virtual hosts. They're added to the Apache configuration file (usually httpd.conf), and you can specify what domain/subdomain to use, and which folder to display. For more information, check out the Apache documentation, or check out this article on Devshed about virtual hosts.

Hope this helps
Team Colleague
Reputation Points: 2240
Solved Threads: 338
Vampirical Lurker
John A is offline Offline
5,055 posts
since Apr 2006
Nov 2nd, 2006
0

Re: Muitiple domain names to multiple websites on Linux and Apache

I have found the httpd.conf file and copied one of the virtual hosts that was there but changed the .com to .fr. It still points to the same files so it should work when I type the url but show the existing website.

When I type the URL it just shows TEST. I have pinged the url and it goes to our ip address.

Do I have to re-start the apache server and how do I do that in Linux

Thanks

Nigel
Reputation Points: 10
Solved Threads: 0
Newbie Poster
nrobinson is offline Offline
2 posts
since Nov 2006
Nov 2nd, 2006
0

Re: Muitiple domain names to multiple websites on Linux and Apache

Click to Expand / Collapse  Quote originally posted by nrobinson ...
Do I have to re-start the apache server and how do I do that in Linux
Yes, you'll have to restart the Apache server after any changes to httpd.conf. You have 2 options:
  • Restarting the entire machine, which is more complete and should be done if you're having problems with the server, etc..
  • Restarting just the Apache service. To do this, you usually run /etc/init.d/apache2 restart with root privalges on the command line. You can also replace restart with start if Apache isn't already running, and stop to completely halt the service.

Hope this helps
Team Colleague
Reputation Points: 2240
Solved Threads: 338
Vampirical Lurker
John A is offline Offline
5,055 posts
since Apr 2006

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Getting Started and Choosing a Distro Forum Timeline: sendmail $ rules
Next Thread in Getting Started and Choosing a Distro Forum Timeline: Making a distro





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC