Error in Export in sharepoint 2013 - powershell

I am trying to move a subsite of 100Gb by using Export and import commands. But I am getting error when I try this command
Export-SPWeb http://dc/sites/Coms –Path "//servername/W$Backups/cops.cmp" -IncludeVersions ALL -includeusersecurity
In the above command W is the Drive name and Backups is the folder name in that server. Can anyone help? Is this correct or is there any solution? Thanks

Are yo trying to store backup in some other server? In no, then your syntax should be like follow:
Export-SPWeb http://dc/sites/Coms –Path "W:\Backups\cops.cmp" -IncludeVersions ALL -includeusersecurity
Please refer this MSDN link on export web if you want any more guidance on it:
https://technet.microsoft.com/en-us/library/ff607895.aspx

Related

Can't read migration file using golang-migrate

After running the up command, my database doesn't seem to be recognizing the SQL contained inside relative/path/000001_init_schema.up.sql.
So far:
Verified I have a connection to the database
Successfully executed the SQL inside my database manager (TablePlus)
Relative path is correct (-path db/migration)
Full command:
migrate -path relative/path -database "postgresql://root:secret#localhost:5432/dbname?sslmode=disable" -verbose up
After running the command, I receive confirmation that "no changes have been made", but my database only has a schema_migrations table.
Any other ideas?
Thanks,
Connor
I solved the issue by replacing -path relative/path with -source file://relative/path
Alternatively, you can use -source file:///absolute/path

How to Export and Import sharepoint subsite documnet library in Sharepoint 2013?

Please help me, for this i'm using power shell command as
Export-SPWeb "http://iicss89:5555" -itemurl "/HelpFiles" -path "c:\helpdocument.cmp" -IncludeVersions All
it is working for main site document library properly but for subsite it is not working.
for subsite i used below command but it shows error
Export-SPWeb -Identity "http://iicss89:5555/Physics" -itemurl "/HelpFiles" -path "c:\helpphydocument.cmp" -IncludeVersions All
Thanks
ItemUrl parameter must be server relative url. You need to remove the leading slash.
So it should be like this;
-itemurl "HelpFiles"

Restore Full/Differential backup to a new web application in SharePoint 2013

I was creating a Full and differential backup of a web application with Backup-SPFarm command. Backup thing is working fine for me.
Can anyone have idea how to restore this full backup to a new web application with Restore-SPFarm command ?
I have tried with powershell and SharePoint central administration, but no success and it is not giving any error as well it saying it is successfully completed.
Using these commands for backup and restore
Backup-SPFarm -Directory 'c:\bkp' -BackupMethod full -Item 'SharePoint - 80' -Verbose
Restore-SPFarm -Directory C:\bkp -RestoreMethod Overwrite -Item "SharePoint - 41434" -BackupId e7e7b9a5-355e-4f6c-b340-c453274b129a -Verbose
Anyone have any idea ?
Thanks
Have you checked the restore-log? Are you restoring it to the same server/environment? I'm not sure you can restore it to the same servers since the content-database will be the same. Have you tried to restore it to a dev-environment?

Enable XA Transactions through a batch file or script

Im trying to create a batch file or a script that enables this option in Windows 7x64
The reason for this is that when running a silent installation I get en error pointing to this. If I do it manually all works fine.
Im not sure how to create this batchfile/script/powershell...?
Any ideas?
Thank you all
The option 'sits' in the registry according to MSDN - http://msdn.microsoft.com/en-us/library/cc224817.aspx
With PowerShell it will be like this:
Set-ItemProperty "HKLM:\\SOFTWARE\\Microsoft\\MSDTC\\Security\\" -Name "XaTransactions" -Value "1"
Note that you need admin rights. Tried it on Windows 8.
You may want to experiment with reading the value first - here's the way:
Get-ItemProperty "HKLM:\\SOFTWARE\\Microsoft\\MSDTC\\Security\\" -Name "XaTransactions"

Export SPWeb SharePoint 2010 weird dll error

Ik get a weird error when running the following command:
PS C:\> Export-SPWeb -Identity http://dfz-85:81/ -Path "C:\temp.cmp"
This is the error i get, the .dll file keeps changing every time i try the command.
Export-SPWeb : Could not find file 'C:\Users\cmsadmin\AppData\Local\Temp\mlilsk
gt.dll'.
At line:1 char:13
+ Export-SPWeb <<<< -Identity http://dfz-vm85:81/ -Path "C:\tmep.cmp"
+ CategoryInfo : InvalidData: (Microsoft.Share...CmdletExportWeb:
SPCmdletExportWeb) [Export-SPWeb], FileNotFoundException
+ FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletExportWeb
Any help is appreciated.
I faced the same error. Could not find the reason but could successfully export from central admin > backup restore option.
Came across this issue and eventually resolved it. Not sure what the actual solution was but the steps I took were:
Add logged in user as SP Shell Admin on the content database you're exporting/importing from/to
Close the SharePoint 2010 Management Shell window
Reopen the SharePoint 2010 Management Shell window with the Import system modules option (right click on the icon in Windows 7)
I ended up avoiding the issue and exporting/importing with SharePoint designer.
This can only be done under "All Files" and on each individual file, afaik.