2

We have a multi-site instance of Sitecore 8.2 and we have patched the <sites> section to include each site. This all seems fine and every site can be accessed by its unique domain/subdomain.

Curiously, one of the sites will resolve fine (it's home page), but when we try to access Sitecore, instead of loading the login page, we get a 404 page.

Here's the config line for a site that works -

Sitecore login page is reachable

Note I only changed the hostnames to generic values (e.g site1 and oursite.com):

<site patch:after="*[@name='modules_website']"
    name="site1_authoring"
    targetHostName="authoring.site1.oursite.com"
    hostName="authoring.site1.oursite.com"
    virtualFolder="/"
    physicalFolder="/"
    rootPath="/sitecore/content"
    startItem="/Sites/site1"
    database="web"
    enableAnalytics="false"
    domain="extranet"
    allowDebug="true"
    cacheHtml="true"
    htmlCacheSize="100MB"
    registryCacheSize="0"
    viewStateCacheSize="0"
    xslCacheSize="5MB"
    filteredItemsCacheSize="2MB"
    enablePreview="true"
    enableWebEdit="true"
    enableDebugger="true"
    disableClientData="false"
    forceSSL="false" />

And here's the config line for the site that does not work -

CANNOT access Sitecore login page

Note I only changed the hostnames to generic values (e.g site2 and oursite.com):

<site patch:after="*[@name='modules_website']"
    name="site2_authoring"
    targetHostName="authoring.site2.oursite.com"
    hostName="authoring.site2.oursite.com"
    virtualFolder="/"
    physicalFolder="/"
    rootPath="/sitecore/content/Sites/site2"
    startItem="/Home"
    database="web"
    domain="extranet"
    enableAnalytics="false"
    allowDebug="true"
    cacheHtml="true"
    htmlCacheSize="100MB"
    registryCacheSize="0"
    viewStateCacheSize="0"
    xslCacheSize="5MB"
    filteredItemsCacheSize="2MB"
    enablePreview="true"
    enableWebEdit="true"
    enableDebugger="true"
    disableClientData="false"
    forceSSL="false" />

When trying to access the Sitecore login on the second site via: http://authoring.site2.oursite.com/Sitecore/login, we get the following error:

http://authoring.site2.oursite.com/error/pagenotfound?item=&user=sitecore%5cAnonymous&site=login

I am not seeing anything significant in the site config definitions?

4
  • The rootPath and start item is not consistent between the two of them.
    – Chris Auer
    Commented Dec 6, 2016 at 16:28
  • Do you have sitecore/login folder on that server? Do you have the <site name="login" virtualFolder="/sitecore/login" physicalFolder="/sitecore/login" enableAnalytics="false" database="core" domain="sitecore" disableXmlControls="true" /> on that server also? Commented Dec 6, 2016 at 17:37
  • Are there any log errors? Commented Dec 7, 2016 at 7:37
  • 1
    Please go to /sitecore/admin/ShowConfig.aspx, find the <sites> section and attach its contents to your question. Commented Dec 7, 2016 at 7:43

2 Answers 2

3

The clue here suggests that the login site is resolving correctly. The error message is forwarding to the pagenotfound using the site context of login. This tells me that the SiteResolver is picking up the correct site.

Something else is going on preventing access to the login page.

Things to Check:

  • Make sure something funky isn't going on in IIS preventing access to the file structure of /sitecore/login for that domain.
  • Try clearing cookies, cache, or using Incognito to make sure there isn't some strange cookie getting in the way.
  • Ensure that your site definitions are properly ordered:
    • Order Includes:
      1. shell
      2. login
      3. admin
      4. service
      5. modules_shell
      6. modules_website
      7. SITE DEFINITIONS HERE
      8. scheduler
      9. system
      10. publisher
2
  • These are all great ideas and I did check each of these. It turned out that the site in question's DNS record had been pointed to the wrong server. One that didn't have a Sitecore login folder.
    – Sirius_B
    Commented Dec 7, 2016 at 15:51
  • ahhh pointed to a hardened CD instead! Commented Dec 7, 2016 at 15:58
0

If you find that something like this is happening and the <sites> configuration seems valid, consider, as I eventually did, that all sites are pointing to the same server.

When I pinged the working sites, I saw that they all had the same IP but the site throwing the 404 was pointing to a different IP, and therefore a different server altogether; one that did not have the Sitecore login folder as TRNKTMS alluded to.

Not the answer you're looking for? Browse other questions tagged or ask your own question.