Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I have a domain name and a live website. I want to create some subdomains so that they appear as separate websites in Search engines.

For Example take Blogspot. x.blogspot.com and y.blogspot.com are separate websites.

share|improve this question

migrated from serverfault.com Apr 11 at 5:29

This question came from our site for professional system and network administrators.

add comment

1 Answer 1

up vote 6 down vote accepted

This is normal behavior. I am not sure what your question is exactly. But here goes.

I am going to assume you are using Apache and host your DNS.

Create the sub-domain on your server however you need. For Apache, this would be almost exactly like any other domains website. You can find the configuration files in /etc/apache2/sites-available or /etc/local/apache2/sites-available. If there is a website already on the web server, you will see the configuration file named something like mydomain.com.conf. Use this file as an example and create your sub-domains. Create a file for each sub-domain like sub-domain.domain.com and cut and paste the contents of your original domain configuration into each. You will need to change some directives.

1] Change your ServerName to something like sub-domain.domain.com to reflect your sub-domain.

2] Remove ServerAlias.

3] Create a root directory for your sub-domain change DocumentRoot and .

4] You may need to change your log file locations as well.

You may have a control panel for this.

Create an entry in your DNS server for the sub-domain. Using the same IP address as the parent domain is fine depending upon your set-up. I am sure it will work okay assuming that all of the sites will be hosted on the same system. You will need an A record for each sub-domain. I cannot tell you how to create the record for your system. I am assuming you will have a control panel for this.

That is it.

Search engines treat all sub-domains websites as separate sites and separate from the parent domain.

share|improve this answer
    
I think I got it! Thanks –  Buntu Linux Apr 11 at 6:02
    
Good luck with it! Add a comment if you have any issues. –  closetnoc Apr 11 at 6:11
    
Google does not treat subdomains as separate websites –  John Conde Apr 11 at 13:15
1  
With respect John- each web site on a sub-domain is a separate site from the parent domain site and any other sub-domain site. This is well known. –  closetnoc Apr 11 at 14:17
    
Hi! I followed Closetnoc's instructions, Thank you very much! Now I have both mydomain.com and sub.mydomain.com indexed in Google and I'm managing them in Google Webmaster tools as two seperate websites. –  Buntu Linux Apr 13 at 15:21
show 1 more comment

Your Answer

 
discard

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.