[HELP] Multiple domains on one ip showing different index.html

megamidge11

Honorable
Jun 1, 2013
50
0
10,630
Hi, i'm not sure where to put this so i put it here.
I have a dedicated server with apache2 on it (it's a Ubuntu based system), and i assigned 3 domain names to the one ip:
ssgc.uk.to
shadowstalkersgc.uk.to
shadowstalkersgamingcommunity.uk.to

They all point to the same address.
When i'm changing web content (so far, there is no website, just an index), it seems to change only for one. I'll explain.
I changed what index.html was and looked at it on ssgc.uk.to, it updated to a template i had downloaded, but i realised it was the wrong template, so i changed what index.html was, so the previous version no longer existed on the server. I refreshed the page, and no change. I refreshed a few times. So i checked shadowstalkersgc.uk.to, and the change had happened, so i went to work modifying the page. Everything was working fine, (though ssgc.uk.to still hadn't updated). I then changed an image as the last thing i did, refreshed the page and no change, so i checked ShadowStalkersGamingCommunity.uk.to, and the change had happened there.

The next day (day of writing this) i have checked the first two domains to see if they have set their ways, and they have not (of course). I'm stumped as to why its happening because as far as i know, the first two domains are showing up content that doesn't exist. I checked with my friends to see if they were getting the same, and they said yes.

TL;DR:
Content on domains are not updating on one domain, but on another. All domains are on the same ip.

Any help appreciated, cheers.
~mega
 

McHenryB

Admirable
Without looking at your apache configuration files it's not possible to give a definitive answer. But, by design, different domain names can lead to different web sites even if they are hosted on the same IP address. The advantages of this are fairly obvious.

If you want multiple domains to point to the same site it would probably be best to set index pages on the subsidiary domains that do an html redirect to the master index page.
 

megamidge11

Honorable
Jun 1, 2013
50
0
10,630
This didn't help me that much. I'm fairly new to using dedicated servers and such.
Here's my apache2.conf and 000-default.conf (located in sites-enabled)
apache2.conf:
http://pastebin.com/L9GMaru1

and 000-default.conf:
http://pastebin.com/2rnm33H2

To be clear, when i have added index.html, i've only put it in /var/www/html, and i have done zero configuration to do with apache2, ever (i bought the server and apache2 and other important things were pre-installed), and when i registed the domains, i pointed them all at the same place.
 

megamidge11

Honorable
Jun 1, 2013
50
0
10,630
All i am doing when updating the index.html is editing it and then saving it in /var/www/html, then looking on my domains to preview what i have done. It updates on a domain _sometimes_ and not others, when it doesn't update i check the next domain and it will have updated there.
I honestly don't understand.
 

McHenryB

Admirable
OK. Here's an alternative way to achieve what you want to. In the 000-default.conf file place the following lines after the commented-out line:

#ServerName www.example.com

and then restart the web server. New lines:

ServerName ssgc.uk.to

# These are alternative names for this same vhost.
# We put the other domains here. They will all go to the same place.
ServerAlias shadowstalkersgc.uk.to
ServerAlias shadowstalkersgamingcommunity.uk.to
 

megamidge11

Honorable
Jun 1, 2013
50
0
10,630
I placed this after the line commented out that says:
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

and to restart the webserver i did:
/etc/init.d/apache2 restart

With no luck, the issue still persists.
I'm going to assume what im doing wrong is something seemingly stupid?