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

I am developing my intranet portal in office and created the same environment at home even the domain name and the users I am working with.

I have taken the backup of site collection through central admin (dont remember if I have selected with security or without) but I did and it created a .bak file.

Later I came home and I went into central admin, created a web application and tried restoring the site using cmdlet.

Restore-SPSite -identity http://mycompany -path "D:\PortalBackup\MyCompanySiteBackup.bak"

After typing Y in Yes it started restoring...but when I tried accessing the site by http://mycompany

It's giving me unexpected error. I guess there are permission issues.

Please guide what are the steps I should take to restore site collection from one environment to another.

share|improve this question
add comment

3 Answers

up vote 0 down vote accepted

Have you deployed any customisations to the farm in your office? They'll need redeploying in your home environment.

share|improve this answer
    
nahhh no customization...the environment is ditto. –  user342944 Dec 3 '11 at 22:07
    
Even the 3 service accounts I am using there are also being created in home environment. is it something with the content database and the users associated with it? I even turned on the customErrorMode in inetpub 80 app but not showing the exact error even after iisreset –  user342944 Dec 3 '11 at 22:08
    
Ok, try using the Export-SPSite Powershell cmdlet rather than backing up in Central Admin. Restore-SPSite is designed to work with the products of Export-SPSite rather than backups. –  James Love Dec 3 '11 at 22:13
    
you mean to say this way ? blogs.technet.com/b/heyscriptingguy/archive/2010/09/21/… –  user342944 Dec 3 '11 at 22:20
    
Yup exactly. Give that a blast. It's used on my current project to ensure all developers have latest versions of the site content as it's being authored. Works rather well. –  James Love Dec 3 '11 at 23:35
show 4 more comments

If your site collection was restored correctly, if it is really permission issue, you can try to give you permissions of site collection administrator through the central administration. Anyway it is usually enough to get site collection backup by Backup-SPSite and restore it by Restore-SPSite, if you don't have permissions after that, just give it yourself in central administration.

share|improve this answer
    
Well ive tried restoring through Import-SPWeb but it imported only the root site which is HOME. The "About Us" site was created as subsite which is not imported as it says "Import-SPWeb : The file cannot be imported because its parent /AboutUs does no t exist." Please guide how to take backup of Parent and subsites also or do I need to take backup at individual level like HOME, then About US then Departments then Depart A, Department B and so on.... –  user342944 Dec 11 '11 at 11:55
    
As I know there are no possibility to grab all webs in one piece by Import-SPWeb, but there are some options in SharePoint content deployment to grab child sites with parent. Read little bit about that, may be it will be helpful for you. Check this post as a starting point khdraft.blogspot.ru/2011/04/… There is C# code, but you also can implement it using PowerShell. –  Anton Khritonenkov Nov 9 '12 at 17:35
add comment

After you restore in another environment... Try to change the site collection administrator... As it may be a problem... if you are on a different environment...

share|improve this answer
    
Hi Paddy, this would server better as a comment on the question. If it is the correct answer you can either make this answer more verbose now, or after the effect. –  Hugh Wood Dec 4 '12 at 9:24
add 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.