Link to home
Start Free TrialLog in
Avatar of Rafael
RafaelFlag for United States of America

asked on

Copy files while keeping Date & Time Stamp intact

I have multiple external hard drives that I have used for one reason or another. I am consolidating the various drives into one big NAS drive.  That catch is I need to keep the attributes and most important the date and time stamps intact when I consolidate them onto the new drive.  I know I can use xcopy from a command line but it can be tedious give the number of drives and files that have to be copied over. That is unless you have the right command syntax that allows for spaces in path names which I haven't been able to get to work.

So, I'm looking for a GUI based application that runs on Windows 7 that will allow me to copy from source to destination while keeping the attributes but more importantly the time stamp dates in tact.
Avatar of bbao
bbao
Flag of Australia image

regarding the time stamp you mentioned above, which date/time attribute do you refer to? Create Time, Modify Time or Access Time? they are different time stamps for the same single file.
...the right command syntax that allows for spaces in path names...
I didn't know xcopy doesn't allow you to copy folders with spaces in the names. Mine works fine here. Still, it doesn't address your other issue...
...to keep the attributes and most important the date and time stamps intact...
For that, you can use Robocopy with the /DCOPY:DAT switches.

By default, directory timestamps are not copied over so you need the T switch in  /DCOPY:DAT

For file attribute info, you will want to look at these switches...
/COPY:copyflag[s] :: what to COPY for files (default is /COPY:DAT).
  (copyflags : D=Data, A=Attributes, T=Timestamps).
  (S=Security=NTFS ACLs, O=Owner info, U=aUditing info).

/SEC :: copy files with SECurity (equivalent to /COPY:DATS)

/COPYALL :: COPY ALL file info (equivalent to /COPY:DATSOU)

Open in new window


For a 3rd party, competing Robocopy, see http://www.xxcopy.com

Do you still prefer a GUI based application?
Which NAS device would that be? Most consumer devices have USB port for copying from external HD to a folder on the NAS. That would also be an easy  way of copying all your data. After the copy you just move the files to a desired location as that does not modify timestamps.
Avatar of Rafael

ASKER

@ bbao - I'm referring to create date. For example on some of the USB drives there are folders that contain pictures.  These folders and pictures are random but due to the date they were placed on the original drive I can tell the time era for example a trip to the beach.

@NewVillageIT - I think you may be right. Windows 7's explorer sees the file names in it's explorer with spaces, I just wasn't able to create the right syntax to copy say F:\users\family\My Pictures\Trip To Beach\files to  H:\My Pictures\Trip to Beach\Ocean City\2012  etc.  I will try Robocopy for the GUI and see if it helps.

@gerwinjansen - Although, I do have a NAS (FreeNas) used for backups for servers, on my home network, it was the wrong choice of words on my part.  I am actually using a Seagate 3TB Bakup Plus.

All,  the drives are connected to my laptop via the USB ports. I also have the other drives that were old internal drives from my old computers plugged into my other USB ports as needed.  The trick is copying them to the Seagate USB Drive.  So i.e. I have to copy a 250 GB drive (F:) and all it's contents keeping the create date/time the same to my new 3TB Seagate drive (H:)  Sure I can cut and paste or move but it loses the date/time stamp which is what I need.
That Seagate is not a NAS, so I'd go for robocopy with the date option.

There are a few robocopy front-end gui's out there but I only use the command line. Just try one I'd say.
Avatar of Rafael

ASKER

have a syntax ?
@Rafael. Do you need syntax for.....robocopy command-line?
- I thought you were going to try Robocopy GUI? https://technet.microsoft.com/en-us/magazine/2006.11.utilityspotlight.aspx
- That link also has RichCopy. Supposedly better than Robocopy. I haven't tried it tho.
Avatar of Rafael

ASKER

I used both Robocopy and robocop robocopy and tried the below commands and they fail.

Robocopy "F:\Rafael\Documents and Settings\Rafael.NOVASTAR\Desktop\Car Stuff\*.* " I:\ /E /J /COPY:DAT /COPYALL /R:10 /W:5 /V /ETA

I used the following command and it failed.
Yours looks fine. Can you post your specific error?

/COPY:DAT is redundant. /COPYALL does it instead.

Do you have a /V: switch? I don't see one on mine. (I have windows 8.1)

Don't forget to use: /DCOPY:DAT

Another useful one is to log the results with /LOG+:Results.txt

EDIT: my bad. There is a /V switch, but not /V:

I think your error may be:
"F:\Rafael\Documents and Settings\Rafael.NOVASTAR\Desktop\Car Stuff\*.*"

Open in new window


Try removing the \*.*
"F:\Rafael\Documents and Settings\Rafael.NOVASTAR\Desktop\Car Stuff"

Open in new window

Rafael. I edited my last post. Refresh your web page.
>> I'm referring to create date.

as mentioned above, robocopy is the right choice: official and free.

> I'm looking for a GUI based application

robocopy has a GUI based version, see here.

https://technet.microsoft.com/en-us/magazine/2006.11.utilityspotlight.aspx?pr=blog
@bbao - That's an add-on, you still need robocopy - so you're just repeating what I said ;)
SOLUTION
Avatar of Gerwin Jansen
Gerwin Jansen
Flag of Netherlands image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Rafael

ASKER

Perhaps something is not tick'ed correctly.  Either way I'm using the Robocopy from TechNet. I have attached screen shots and I can't attach a log as it does show up nor do the files copy over.

However, from the command line this seemed to work EXCEPT it dumped all the files rather than copying the Car Stuff folder and it's contents. Am I missing something ?

C:\Users\Rafael>robocopy "F:\Rafael\Documents and Settings\Rafael.NOVASTAR\Desktop\Car Stuff" I:\ /E  /R:10 /W:5 /V

So... ???
monitoring.png
logging.png
filters.png
copy-options.png
path.png
...it dumped all the files rather than copying the Car Stuff folder and it's contents
You mean none of the files are in I:\?
Instead, it should have copied the Car Stuff contents to I:\, but without the folder name Car Stuff. However, when your run...
Robocopy /DCOPY:DAT /E /R:10 /W:5 /V f:\ i:\ConsolidatedDrv01\

Open in new window

, it will copy all the files and folders on the drive, and keep the folder names intact. Notice that it creates the folder ConsolidatedDrv01 automatically. Also, notice the trailing \, i.e.  I:\ConsolidatedDrv01\.
When the first drive is done, you can run it again with the name ConsolidatedDrv02. And so on, for each drive.

In your copy-options image, I don't see the /DCOPY option. I'm not familiar with the GUI version.
@Gerwin: /J :: copy using unbuffered I/O (recommended for large files).
I have Windows 8.1 RT
Avatar of Rafael

ASKER

@NewVillageIT  Yes it dumped everything into the root of I: however, it did not copy the Car Stuff folder.   I hoped it would have copied the entire folder and it's contents.
@Rafael. Yes, that's expected. See my prior post for explanation.

Your command:
robocopy "F:\Rafael\Documents and Settings\Rafael.NOVASTAR\Desktop\Car Stuff" I:\ /E  /R:10 /W:5 /V

Open in new window

As I mentioned, will copy the contents of "Car Stuff", but not the folder itself. In other words, just the folder "Car Stuff" is missing on the target.

...it dumped all the files...
At first, I thought it dumped=erased the files. LOL.
Avatar of Rafael

ASKER

So how would I get that folder copied without having to create one first and then dump into it ?
robocopy "F:\Rafael\Documents and Settings\Rafael.NOVASTAR\Desktop\Car Stuff\" I:\ /E  /R:10 /W:5 /V
Avatar of Rafael

ASKER

that didn't create the folder of Car Stuff and drop the contents into it. Am I missing a switch ?
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
How about using a ZIP archive as intermediate?

Create a .zip file on your destination drive in a new subfolder, containing data from one of the USB drives.

Then move files from the .zip on the destination drive to it's proper place. Time stamps are as they were. You may have to move files into a new subfolder on the source drive first.
Avatar of Rafael

ASKER

Sorry for the delay guys. Been slammed at work. Was able to use what was given and just made it work. I still have to manually create the directories though.