none
Move a site collection to another site collection as a new sub-site RRS feed

  • Question

  • Hi

    I have three site collection ( 1-http://automation , 2-http://automatin/sites/rd , 3-http//automatin/sites/hr). I want to move /sites/rd and /sites/hr to the main collection as a sub site. like this: http://automation/rd or http://automation/hr

    what am i do?

    Tuesday, January 17, 2017 5:58 AM

All replies

  • Hi,

    The sites 2-http://automatin/sites/rd , 3-http//automatin/sites/hr. I guess you are trying to correct the typo in the site collection name , is it correct ?

    If yes, You can use the below PS command to backup the site 2 and 3.
    Backup-SPSite -Identity "http://automatin/sites/rd" -Path "C:\backup\automatinRD.bak"

    Second, Create the new site collection under automation webapplication, and set the name http://automation/sites/rd

    Third, Overwrite the newly created site collection with your backup file.

    Restore-SPSite -Identity "http://automation/sites/rd" -Path C:\backup\automatin.bak -Force –Verbose

    If you are getting max site collection count error, while doing this operation then you need to extend the site count on the same database using this below commandGet-SPContentDatabase http://automation | Set-SPContentDatabase -MaxSiteCount desired site count


    Murugesa Pandian | MCPD | MCTS | SharePoint 2010 |


    Tuesday, January 17, 2017 8:23 AM
  • Hi yuzarsiv,

    You need to create two managed path hr and rd using explicit inclusion. Below are the link for same(You have to follow the same steps in sp 2013.)

    https://technet.microsoft.com/en-us/library/cc261845.aspx 

    http://www.c-sharpcorner.com/UploadFile/sagarp/site-collection-for-root-explicit-inclusion-wildcard-inclu/ 

    Once you create your managed path you should take the backup of existing sites http://automatin/sites/rd,  http//automatin/sites/hr and restore them to the path that you created using explicit inclusion that is http://automatin/rd, http//automatin/hr. Follow the below link for backup and restore-

    https://technet.microsoft.com/en-us/library/ee748617.aspx 

    Tuesday, January 17, 2017 9:38 AM
  • Hi

    NO, Like I explained that bad!

    In fact, I was wrong configuration structure. I was created three Site Collection but it's very bad these are separate sites. so I want to move that two sites in the initial site collection such as sub site.

    Tuesday, January 17, 2017 11:09 AM
  • Hi

    excuse me. can I use export and import  or using the "Save site as template" have you any link for help me?

    Tuesday, January 17, 2017 11:13 AM
  • Hi,

    What do you mean "subsite" ? In SharePoint site and subsite has its own definition and limitation.

    How you want to see the site under http://automation

    The above link is the site collection with rootsite.

    Here you can create the site with URL http://automation/sites/hr or  http://automation/hr

    Let us clear this doubt and we can help you on resolving this.


    Murugesa Pandian | MCPD | MCTS | SharePoint 2010 |

    Tuesday, January 17, 2017 1:52 PM
  • you may try several approaches:

    1. iterate through all sub sites in source site collections (http://automatin/sites/rd and http//automatin/sites/hr) and for each sub site use Export-SPWeb and Import-SPWeb cmdlets. Here are several useful details about these commands: How to export the Site and import the another server in Sharepoint 2013.

    2. if you mainly need to move content from doclibs and lists check this example: Moving a SharePoint Document library to a new SiteCollection via PowerShell. It iterates only through lists and doclibs and copies their content to another site collection also using mentioned PowerShell cmdlets.


    Blog - http://sadomovalex.blogspot.com
    Dynamic CAML queries via C# - http://camlex.codeplex.com

    Tuesday, January 17, 2017 2:43 PM
  • Hi

    I want to have for example http://automation/hr.

    now I have http://automation/sites/hr or http://automation/sites/rd with document libraries and lists, I want to move with all content and document libraries and lists to new site (http://automation/hr) or (http://automation/rd)

    Wednesday, January 18, 2017 5:47 AM
  • Hi Yuzarsiv,

    This is what backup and restore will do, it will move all content of your site to another site where you will restore.

    Wednesday, January 18, 2017 6:03 AM
  • Please refer my answer to this case.


    Murugesa Pandian | MCPD | MCTS | SharePoint 2010 |

    Wednesday, January 18, 2017 7:26 AM
  • Hi

    have you any efficient link for this?

    Wednesday, January 18, 2017 8:59 AM
  • Hi,

    Authentic and you can confidently rely on this MSDN links on Site back and restore.

    Backup-SPSite and Restore-SPSite


    Murugesa Pandian | MCPD | MCTS | SharePoint 2010 |

    Wednesday, January 18, 2017 3:57 PM
  • Hi

    that not work!! the site collection can not restore to the sub site!!

    Saturday, January 21, 2017 12:18 PM
  • Hi

    that not work!! the site collection can not restore to the sub site!!

    Saturday, January 21, 2017 12:18 PM
  • Hi,

    Have you created the site collection http://automation/arg before you use the restore the site ? It looks no site collection at http://automation/arg

    Otherwise first create the site collection http://automation/sites/arg and then use the restore command with force overwrite parameter.


    Murugesa Pandian | MCPD | MCTS | SharePoint 2010 |

    Sunday, January 22, 2017 4:10 AM
  • Hi

    yes. I was created http://automation/arg and then restore. but have that error.!!!

    Sunday, January 22, 2017 6:08 AM
  • Hi,

    The error message is very explanatory. You created the subsite "arg" under the root site collection "http://automation/"

    If you want http://automation/arg , then you have to create the Managed Path based site collection.

    Here is the link for you to create the new managed path "arg".

    SharePoint Managed Path

    KumarMohiT already suggested you to do in his early reply,


    Murugesa Pandian | MCPD | MCTS | SharePoint 2010 |

    Monday, January 23, 2017 4:09 AM