Old 9th March 2013, 02:25
RioSif RioSif is offline
Join Date: Jan 2012
Posts: 31
Thanks: 7
Thanked 2 Times in 2 Posts
Default Single IP multiple websites

I have one ip lets say and lets say 3 websites example1.com, example2.com, example3.com.
Websites are created with this ip selected at the "IPv4-Address". DNS created. Websites working ok.
At /etc/httpd/conf/sites-enabled/ i have 000-apps.vhost, 000-ispconfig.conf, 900-example1.com.vhost, 900-example2.com.vhost, 900-example3.com.vhost .
As i checked when i try to access via the browser the ip it goes to example1.com. I think because of alphabetic sorting. How can i make the ip redirects to example2.com or example3.com?


PS: Centos 6.3, ISPconfig latest

Last edited by RioSif; 9th March 2013 at 03:43.
Reply With Quote
Sponsored Links
Old 9th March 2013, 18:52
falko falko is offline
Super Moderator
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,749 Times in 2,579 Posts

You must use domains/hostnames in your browser, not IP addresses.
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
Old 9th March 2013, 21:43
RioSif RioSif is offline
Join Date: Jan 2012
Posts: 31
Thanks: 7
Thanked 2 Times in 2 Posts

Yes, of course, you are right. That's the correct behavior but what if someone pings example3.com and finds it's ip address and then hits the ip address and sees example1.com instead of example3.com?
My question is is there a way to control via ispconfig or manually from the configuration of bind9 or httpd or it is just chosen randomly. I just want to know if there is a way. I know the right way to access a website.

Reply With Quote
Old 10th March 2013, 13:45
tahunasky tahunasky is offline
Join Date: Jul 2012
Location: Buenos Aires
Posts: 84
Thanks: 1
Thanked 9 Times in 9 Posts

Change the names of your vhost files:

902-example1.com.vhost, 900-example2.com.vhost, 901-example3.com.vhost

Apache will load the first one (900) and make it the default for the IP, then load 901, and 902, so if the IP is used it the web browser it will go to 900..

I myself usually put a _default.vhost file, to do this job.

You cant control this behavour using ISPConfig.

Last edited by tahunasky; 10th March 2013 at 13:49.
Reply With Quote
The Following User Says Thank You to tahunasky For This Useful Post:
RioSif (11th March 2013)
Old 11th March 2013, 00:23
RioSif RioSif is offline
Join Date: Jan 2012
Posts: 31
Thanks: 7
Thanked 2 Times in 2 Posts

You are right, i thought of this cheat too. I was just looking for a more formal way.
Anyway, i'll do like that. Thank you!
Reply With Quote


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Question: How to set up multiple websites in single IP hhhhhh Server Operation 2 5th March 2011 14:44
Multiple Websites Single Certificate rusty Installation/Configuration 1 19th January 2011 23:33
Single static IP with multiple websites/domains Happy_Gillmore General 4 28th June 2009 21:16
Multiple IPs on a single ISPConfig install? Craig Installation/Configuration 4 14th December 2006 19:22

All times are GMT +2. The time now is 08:59.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.