How do you do....it? Thread, Move or copy a large directory tree in Technical; I am currently sorting out the directory and file structure on the new W2008 64bit domain server. I want to ...
13th April 2009, 12:06 PM #1
Move or copy a large directory tree
I am currently sorting out the directory and file structure on the new W2008 64bit domain server. I want to move a rather large (and deep) directory up a level. What are the recommended ways of doing this?
I have heard of Robocopy, but have not used it before and not sure if it works for 2008. Would I be able to copy the whole tree from one place to another on the same server? Does it retain things like time stamps and access and security information? I have read the Robocopy syntax but as I said being a newby on this I'd like some guidance please.
13th April 2009, 12:40 PM #2
How large are you talking about?
Are there likely to be locked files in the tree or is it largely data that no one will be accessing?
If you're only talking about a few GB of data, and it was still Easter there (with no one else accessing files etc), then I would be inclined to just copy via explorer.
If it's a bit messy and you would like an alternative app, I haven't used Robocopy (although i've seen it mentioned before with good feedback) but have used Beyond Compare.
Permissions / security will depend on whether permissions are inheritted from the folder above and if you're moving it to the same volume etc.
13th April 2009, 12:48 PM #3
Robocopy is built in to Server 2008 and is in fact recommended over the now-legacy xcopy command. It would do exactly what you need, but it might not be necessary since it sounds like you are moving the folder to another location on the same drive (which is actually just a rename; no new copy of the data is needed), in which case you may be able to use the much simpler move command.
As mb2k01 suggests, you will need full permissions for your account on all the the files, and for none of them to be locked in use, for that to work. If these conditions are not all true, then robocopy is definitely your friend. This is the syntax I would suggest:
robocopy "source" "destination" /e /copyall /b /move
Thanks to AngryTechnician from:
13th April 2009, 12:50 PM #4
The tree is in the tens of gb region rather than hundreds, not sure if there are any locks - there shouldn't be but there again this is a central store. It's a place where users (staff only) put resources so that others can access them, which is I guess why it has grown so large.
It would be going to the same volume and would need the same share permissions it has now. And yes they are inherited from the current share. I was holding off from a straight copy as I want to be able to do other things on the server (it being the hols) and I think it would take quite a long time.
Beyond Compare? Will look that one up, thanks.
13th April 2009, 12:54 PM #5
As I don't think anyone will be there today, this is I think what I need, thanks. Is there a way of checking that everything has moved, apart from the obvious that any file/directory would still be visible in the old location? Do I need another switch to be able to monitor what's going on?
Originally Posted by AngryTechnician
13th April 2009, 01:35 PM #6
Robocopy has a huge number of switches you can use. I tend to use:
Then delete manually after when I've checked the logfile.
robocopy.exe "source" "destination" /E /COPY:DAT /R:5 /W:5 /NDL /NP >"logfile.txt"
If you want something more graphical there's Robocopy GUI however that needs to be installed.
13th April 2009, 02:14 PM #7
If it's only xxGB and moving to somewhere else on the same physical disk, then it shouldn't take that long at all. As a rough guess i'd say about 5mins per 10GB?
Originally Posted by leco
Sadly I'm still a server 2003 man, but if 2008 has robocopy built in and has the potential to provide a safer move anyway i'd plump for that. You could always test it out on a test directory first to make sure it does what you want (maybe test permissions that way too?)
If it's a shared area maybe spend a bit of time checking out what the permissions are before you move (just in case!)
13th April 2009, 02:40 PM #8
By phreak in forum Jokes/Interweb Things
Last Post: 17th March 2008, 12:59 PM
Last Post: 1st February 2008, 12:32 PM
By Uraken in forum MIS Systems
Last Post: 30th October 2007, 03:28 PM
By Frazer in forum Scripts
Last Post: 20th June 2006, 04:53 PM
By tarquel in forum Windows
Last Post: 15th February 2006, 10:22 AM
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)