Solved

Robocopy Files to New Domain without Permissions

Posted on 2013-06-14
2
7,368 Views
Last Modified: 2013-07-12
I need to copy files to a new server in a new domain - there is not and will not be a trust established between domains.  We will be creating new user accounts and new NTFS permissions in the new domain.  I just want to copy files on the 2008 file server from the old domain, to the 2008 file server, currently on a work group, to a new domain. I want to lose permissions also.  

In addition, how can I exclude a particular file from being copied over, in this case *.pst files.  I'm thinking the below command should work, thoughts?

robocopy "\\SOURCESERVER\f$\Shares\Shared" "\\DESTINATIONSERVER\f$\Shares\Shared" /MIR /r:1 /w:1 /DAT /xf *.pst  /log:c:\shared_script.txt
0
Comment
Question by:fireguy1125
2 Comments
 
LVL 1

Author Comment

by:fireguy1125
ID: 39248571
robocopy "\\SOURCESERVER\f$\Shares\Shared" "\\DESTINATIONSERVER\f$\Shares\Shared" /MIR /r:1 /w:1 /copy:DAT /xf *.pst  /log:c:\shared_script.txt

seems to have worked for me - my other question - I'm doing the initial copy, but what syntax do I enter to just copy changes only so when I re-run it again it doesn't copy all the files again?
0
 
LVL 83

Accepted Solution

by:
oBdA earned 500 total points
ID: 39248576
Change /DAT to /copy:DAT (or leave it out; /copy:DAT is the default if not specified), and add /np (to prevent control characters from cluttering the log file) and maybe /TEE (to show progress on the console while logging):
robocopy.exe "\\SOURCESERVER\f$\Shares\Shared" "\\DESTINATIONSERVER\f$\Shares\Shared" /MIR /r:1 /w:1 /copy:DAT /xf *.pst /np /tee /log:c:\shared_script.txt

Open in new window

Note that robocopy has an /L switch, which tells it to just pretend to copy.
Note, too, that robocopy will by default only copy files that aren't in the target folder yet, so you can just run the same command several times to update the target.
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, I am going to show you how to simulate a multi-site Lab environment on a single Hyper-V host. I use this method successfully in my own lab to simulate three fully routed global AD Sites on a Windows 10 Hyper-V host.
This script can help you clean up your user profile database by comparing profiles to Active Directory users in a particular OU, and removing the profiles that don't match.
This tutorial will walk an individual through locating and launching the BEUtility application and how to execute it on the appropriate database. Log onto the server running the Backup Exec database. In a larger environment, this would generally be …
This tutorial will walk an individual through the process of configuring their Windows Server 2012 domain controller to synchronize its time with a trusted, external resource. Use Google, Bing, or other preferred search engine to locate trusted NTP …

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question