I am setting up a rather large site that is going to have subdomains. The subdomains are going to share templates and xslt so I am going to use 1 instance to host the site and 4 sub domains. Can someone walk me through all of the steps to do this? In my mind I figure I have to configure the iis for each site and then point them all to the same umbraco instance. Then in umbraco assign each of them a hostheader and set the umbraco config file to use domain prefixs....is this right? A walk through of this would be very appreciated.
Sounds like you've already got all the right items on your checklist. We run dozens of domains in the same instance (sub domains too) and our list looks something like this:
Create site in IIS, adding host headers as appropriate - all sites should point to the single Umbraco instance
- you can also create a single site with multiple host headers
Make entries in Umbraco for 'Manage Hostnames' mapping to the IIS host headers
If you're using sub domains, set useDomainPrefixes to true in umbraco.config
You'll probably also want to set ensureUniqueNaming to true in case you have multiple 'home' pages
That's it. It's worked beautifully for us over the last 2+ years.
Quote: "- you can also create a single site with multiple host headers"
I think you shoud be a little careful about this one. I know it is a posability and it is handy when you are doing development with test-domains and so on. But if you use this option in production-environment, you might be facing dublicate content problems when the search engines index your site.
Of course... if DC-problems does'nt matter because of the application at hand, then just go for it :-)
Ok I have everything set up, now new error is happening, I have copied my contact us from the main site and placed it in each of the sub domain. Now when I navigate to contact-us.aspx from any of the sub domains it gives me this error:
Page not found
No umbraco document matches the url 'http://design.carbintech.com/contact-us.aspx?iframe'
umbraco tried this to match it using this xpath query'/domainprefixes-are-used-so-i-do-not-work')
This page can be replaced with a custom 404 page by adding the id of the umbraco document to show as 404 page in the /config/umbracoSettings.config file. Just add the id to the '/settings/content/errors/error404' element.
now, I know the page is published and the same error occurs when I try to view the page by clicking the link in the properties section from the back end. What do I need to do to have this work?
Ok problem not solved, when I make a change to any of the sections managed by hostnames, I have to physically go into VS and rename the web.config file, then rename it back so that the cache will clear and the changes will take effect. No visible changes are made when I publish anything that is managed by the hostnames, only when I physically clear the cache. What am I doing wrong, this is very inefficient....
SOLVED!!! I had it set up as individual sites, once I deleted those in IIS and added the host headers to the original site everything seems to work fine! Thanks for all the help, you guys rock!
Need some help managing hostnames...
I am setting up a rather large site that is going to have subdomains. The subdomains are going to share templates and xslt so I am going to use 1 instance to host the site and 4 sub domains. Can someone walk me through all of the steps to do this? In my mind I figure I have to configure the iis for each site and then point them all to the same umbraco instance. Then in umbraco assign each of them a hostheader and set the umbraco config file to use domain prefixs....is this right? A walk through of this would be very appreciated.
Evan -
Sounds like you've already got all the right items on your checklist. We run dozens of domains in the same instance (sub domains too) and our list looks something like this:
Create site in IIS, adding host headers as appropriate - all sites should point to the single Umbraco instance
- you can also create a single site with multiple host headers
Make entries in Umbraco for 'Manage Hostnames' mapping to the IIS host headers
If you're using sub domains, set useDomainPrefixes to true in umbraco.config
You'll probably also want to set ensureUniqueNaming to true in case you have multiple 'home' pages
That's it. It's worked beautifully for us over the last 2+ years.
-Paul
Hi Evan & Paul
Quote: "- you can also create a single site with multiple host headers"
I think you shoud be a little careful about this one. I know it is a posability and it is handy when you are doing development with test-domains and so on. But if you use this option in production-environment, you might be facing dublicate content problems when the search engines index your site.
Of course... if DC-problems does'nt matter because of the application at hand, then just go for it :-)
Ok I have everything set up, now new error is happening, I have copied my contact us from the main site and placed it in each of the sub domain. Now when I navigate to contact-us.aspx from any of the sub domains it gives me this error:
Page not found
No umbraco document matches the url 'http://design.carbintech.com/contact-us.aspx?iframe'
umbraco tried this to match it using this xpath query'/domainprefixes-are-used-so-i-do-not-work')
This page can be replaced with a custom 404 page by adding the id of the umbraco document to show as 404 page in the /config/umbracoSettings.config file. Just add the id to the '/settings/content/errors/error404' element.
For more information, visit information about custom 404 on the umbraco website.
This page is intentionally left ugly ;-)
now, I know the page is published and the same error occurs when I try to view the page by clicking the link in the properties section from the back end. What do I need to do to have this work?
Stupid cache problem it seems, problem solved...
Ok problem not solved, when I make a change to any of the sections managed by hostnames, I have to physically go into VS and rename the web.config file, then rename it back so that the cache will clear and the changes will take effect. No visible changes are made when I publish anything that is managed by the hostnames, only when I physically clear the cache. What am I doing wrong, this is very inefficient....
could it be a permissions issue?
That is what I am thinking, Paul is helping me out and he mentioned that as well, what permissions do I need to change for this to work?
I am using win server 2008 and iis 7.0 if that makes any difference...
SOLVED!!! I had it set up as individual sites, once I deleted those in IIS and added the host headers to the original site everything seems to work fine! Thanks for all the help, you guys rock!
is working on a reply...