3

I have a website hosted on web application in SharePoint 2013 with two site collections:

  1. Root /
  2. /ar

The website is hosted on /ar. The problem is when anyone types the domain www.domain.com into a browser it goes to the root directly rather than the /ar site collection. I tried the following two methods:

  1. I have created a script web part in the Root site collection which redirects to "/ar" using the following javascript:

    window.location = "http://domain.com/ar"

    The problem in this method that the root site appears for a moment then redirects to "/ar"

  2. I tried to backup the "/ar" site using Backup-Spsite from powershell and the restore it to the root site but i always get the following error:

Restore-SPSite : The operation that you are attempting to perform cannot be completed successfully. No content databases in the web application were available to store your site collection. The existing content databases may have reached the maximum number of site collections, or be set to read-only, or be offline, or may already contain a copy of this site collection. Create another content database for the Web application and then try the operation again. At line:1 char:1

Any suggestion please?

3 Answers 3

2

For the 2nd method, you should follow the below steps.

  • take the backup of /AR site collection
  • Create a new Content Database
  • Delete the root site collection( i think its gone as operation failed)
  • Make sure it gone from the CA recycbin, to check run get-spdeletedsite -limit all see if it returnes any thing, if yes then user remove-spdeletedsite to remove it.
  • after this run the Restore command with database parameter and give the new db name
5
  • Comments are not for extended discussion; this conversation has been moved to chat.
    – Benny Skogberg
    Sep 2, 2016 at 20:41
  • Finally!! the restore command has been completed successfully after upgrading the original content DB but the original site collection is down now as well the newly created site collection giving me error Server error: go.microsoft.com/… Sep 3, 2016 at 16:41
  • i found a warning in event log : The following databases have versions that are older than the current SharePoint software, but are within the backwards compatible range: Search_Service_Application_AnalyticsReportingStoreDB_e788bc9d5a934005b0e34b69a2933114, SharePoint_Config, Search_Service_Application_CrawlStoreDB_7f4a6c0d728144d582795fd6495794d8, AppMng_Service_DB_f2598f195d8d4643959a8811738501a8, SharePoint_AdminContent_5423ac2f-9dc2-4642-b7fc-16b84eee9040, Search_Service_Application_DB_4cffd180c06d40c2b764e643eb86544c, Sep 3, 2016 at 16:42
  • Looks like your farm needs upgrade so that is causing issue, is it production or lower farm... I think you have to run the config wizard
    – Waqas Sarwar MVP
    Sep 3, 2016 at 17:37
  • i am installing Sharepoint 2013 SP1 right now Sep 3, 2016 at 17:38
0

The issue has been solved the problem was that the WSS_Content database was an old schema so i ran

Upgrade-SPContentDatabase

to upgrade it then i ran

Restore-Spsite

The restore has been completed successfully to the new site collection. Thanks to @wakas Sarwar

0

You can write Redirect URL rule in IIS on Web / App Servers

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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