Ugly Hedgehog - Photography Forum
Home Active Topics Newest Pictures Search Login Register
Main Photography Discussion
Easy Backup of Your Photos
Jul 1, 2018 12:38:51   #
BB2 Loc: Sacramento CA
 
I always run a backup of my photos to both a thumb drive and an external hard drive whenever I add new photos or edit existing photos .
While there are many backup programs which come with a external drive these usually require restoring the file and do not have a copy of the file which can be opened directly from the backup drive,
The following batch script I found years ago in the Win98 days which copies your files without compressing them and leaves an exact copy you can access from any computer.
Also this batch file will replace any file in the backup set which is newer than the existing file in the backup set.

Things you will need to use this batch file:
PATH TO YOUR PHOTO FOLDER - All of your photos should exist in one main folder. They can all be in various sub-folders but the sub-folders must be in a single base folder.
PATH TO YOUR BACKUP FOLDER - This should be the same as your source folder but with the backup drive letter in place of the C: of your source folder.

Windows likes to store all of your stuff to C:\user\username\etc.
I prefer the old school and create the folder C:\Photos.

Open Windows "Notepad" and type the following substituting your folder locations for the C:\Photos\ and the K:\Photos with your folder locations. Maintain the punctuation etc as shown.
There is a space before the K and space between \ and / also spaces between the letters and the following /.


@echo on
REM copy documents
xcopy "C:\Photos\*.*" k:\Photos\ /c /s /r /d /y /i

Name and save this as a text file - File name.txt

Save the file again as a batch file - File name.bat
Right click on the batch file and create a shortcut on your desktop.
Running this batch file will copy your photos to the external or thumb drive and update any revised files.

If using a thumb drive you will be limited on the quantity of files you can copy to it. My Canon utility saves my photos in folders based on the date they were taken so that made it easy.
What I have done is set a starting date based on when the previous backup came close to filling the drive.
The batch file will then look like this:

@echo on
REM copy documents
xcopy "C:\Photos\*.*" k:\Photos\ /c /s /r /d /y /i/D:11-15-2014
(No space before the D or anything following the D.

I have created separate batch files both for the external hard drive and for the thumb drive.

Since I started using this method a long time ago it was easy to find the start date for thumb drives, however if you already have more photos than even a 128GB thumb drive can hold you may have to fill the first drive by arranging your files by date and manually copying them to the thumb drive.
I have not tried running the batch file to see if it will just stop when it reaches thumb drive capacity.

While the batch file is running you will see a command line window showing the progress.

Reply
Jul 1, 2018 13:14:19   #
Longshadow Loc: Audubon, PA, United States
 
I loved using batch files.
Saves a lot of typing!
I use drag-n-drop now between two windows of Windows Explorer.

Reply
Jul 1, 2018 16:29:03   #
PeterBergh
 
BB2 wrote:
... xcopy "C:\Photos\*.*" k:\Photos\ /c /s /r /d /y /i ...


I strongly suggest adding the /V option to the XCOPY command. (The /V option verifies that the source files match the target files, ensuring the copy didn't screw things up.)

PS. For my similar implementation of your idea, I use XCOPY /D /E /F /H /I /K /R /V /X /Y. (For an explanation of what the various options mean, type XCOPY /? in a command window.)

Reply
 
 
Jul 1, 2018 16:31:22   #
PeterBergh
 
BB2 wrote:
... I have not tried running the batch file to see if it will just stop when it reaches thumb drive capacity. ...


Windows asks you to mount another drive when the first one gets full. (It does the same thing with any removable drive.)

Reply
Jul 1, 2018 17:23:52   #
BB2 Loc: Sacramento CA
 
Thanks Peter adding the verification is a good idea.

Also for the clarification of Windows action with a full drive.

Reply
Jul 2, 2018 00:44:48   #
TBerwick Loc: Houston, Texas
 
Just realize that if one or more of your files gets corrupted on the source, XCOPY will overwrite your destination with the corrupt file. For my work, I prefer a backup with versioning meaning as you make edits you'll end up with more than one copy, i.e. a fall back version. There are some inexpensive software packages that will perform that option for you. Google "backup software with version control."

Reply
Jul 2, 2018 08:03:39   #
johntaylor333
 
Much easier is to use Microsoft SyncToy (free). Works very well - it copies individual files rather than a complete backup (just what I want) and I run it every night copying new and changed photos to my RAID array.

Reply
 
 
Jul 2, 2018 08:58:39   #
DirtFarmer Loc: Escaped from the NYC area, back to MA
 
BB2 wrote:
I always run a backup of my photos...


While backing up your photos is important, backing up everything else is just as important. Your email, your word processing files, your program configuration files... everything.

Also understand the difference between archive and backup. Most people are thinking about archives here.
Backup: stuff you will be using in the near future;
Archive: stuff you want to keep forever.

Backup can be stored on things like CD/DVDs, thumb drives, things like that which are good for short term storage but not really suitable for the long term.
Archives take maintenance. The files have to be stored on media that will last a while, but when technology changes, the files have to be transferred to newer media to ensure that they will be readable in the future. As noted above, verification should definitely be a part of the transfer.

Reply
Jul 2, 2018 08:59:09   #
Gort55 Loc: Northern Colorado
 
BB2 wrote:
I always run a backup of my photos to both a thumb drive and an external hard drive whenever I add new photos or edit existing photos .
While there are many backup programs which come with a external drive these usually require restoring the file and do not have a copy of the file which can be opened directly from the backup drive,
The following batch script I found years ago in the Win98 days which copies your files without compressing them and leaves an exact copy you can access from any computer.
Also this batch file will replace any file in the backup set which is newer than the existing file in the backup set.

Things you will need to use this batch file:
PATH TO YOUR PHOTO FOLDER - All of your photos should exist in one main folder. They can all be in various sub-folders but the sub-folders must be in a single base folder.
PATH TO YOUR BACKUP FOLDER - This should be the same as your source folder but with the backup drive letter in place of the C: of your source folder.

Windows likes to store all of your stuff to C:\user\username\etc.
I prefer the old school and create the folder C:\Photos.

Open Windows "Notepad" and type the following substituting your folder locations for the C:\Photos\ and the K:\Photos with your folder locations. Maintain the punctuation etc as shown.
There is a space before the K and space between \ and / also spaces between the letters and the following /.


@echo on
REM copy documents
xcopy "C:\Photos\*.*" k:\Photos\ /c /s /r /d /y /i

Name and save this as a text file - File name.txt

Save the file again as a batch file - File name.bat
Right click on the batch file and create a shortcut on your desktop.
Running this batch file will copy your photos to the external or thumb drive and update any revised files.

If using a thumb drive you will be limited on the quantity of files you can copy to it. My Canon utility saves my photos in folders based on the date they were taken so that made it easy.
What I have done is set a starting date based on when the previous backup came close to filling the drive.
The batch file will then look like this:

@echo on
REM copy documents
xcopy "C:\Photos\*.*" k:\Photos\ /c /s /r /d /y /i/D:11-15-2014
(No space before the D or anything following the D.

I have created separate batch files both for the external hard drive and for the thumb drive.

Since I started using this method a long time ago it was easy to find the start date for thumb drives, however if you already have more photos than even a 128GB thumb drive can hold you may have to fill the first drive by arranging your files by date and manually copying them to the thumb drive.
I have not tried running the batch file to see if it will just stop when it reaches thumb drive capacity.

While the batch file is running you will see a command line window showing the progress.
I always run a backup of my photos to both a thumb... (show quote)


Thanks! Much easier than the Perl script I’ve been using. Guess I forgot about xcopy and it’s many options. One caveat though: when using the /d argument — if you periodically weed out photos from your main drive and have to restore from a backup, all those photos you erased come back. Not fun.

Reply
Jul 2, 2018 09:05:43   #
gvarner Loc: Central Oregon Coast
 
I copy my originals from the SD card to a folder on an external drive, then to a same named folder on my HD for editing.

Reply
Jul 2, 2018 11:37:42   #
sandiegosteve Loc: San Diego, CA
 
I've been doing that with robocopy for years. I think xcopy is about the same. I copy to another local drive, a couple of USB drives and a NAS. For the NAS, there is switch to handle the potential time stamp difference (fft on robocopy) so that it only need to copy new or updated files.

Reply
 
 
Jul 2, 2018 12:15:59   #
Latsok Loc: Recently moved to Washington State.
 
There has been a lot of discussions about backups of photographs.
I don't remember anyone ever mentioning the pros/cons of saving the photos on the original SD card. A non-photographer suggested that, and I could not think of a good reason as to :why not. The SD card could be labeled with the inclusive dates and stored away. Nowadays they are fairly affordable and can be stored away in a safe place very easily. Any thoughts on that?

Reply
Jul 2, 2018 12:26:58   #
DirtFarmer Loc: Escaped from the NYC area, back to MA
 
Latsok wrote:
...I don't remember anyone ever mentioning the pros/cons of saving the photos on the original SD card. A non-photographer suggested that, and I could not think of a good reason as to :why not...


My primary cameras use XQD cards which run around $100 for the small ones. Not an economically viable solution since I can get several terabytes of hard drive for that.

Reply
Jul 2, 2018 14:33:04   #
Ednsb Loc: Santa Barbara
 
There is a rule of 3 for backups - automatic backups to external drive , scheduled cloan backups to another external drive then cloud backup. I'm a mac user so the first two are really simple with Apple's time machine and then cloaning software from Carbon Copy Cloaner (both free) but the cloud backup is the most important because I live in an area where we have fires and could have earthquakes so anything stored at my house could be destroyed. I've been using backblaze for years. Unlimited backup for $5/month. Used to be mac only but I'm pretty sure it is now on PC's as well (maybe even Linux). Take a look at them at backblaze.com.

Reply
Jul 2, 2018 15:10:14   #
PeterBergh
 
Gort55 wrote:
... if you periodically weed out photos from your main drive and have to restore from a backup, all those photos you erased come back. Not fun.


I handle that problem by occasionally reformatting my backup drives (of course, I don't reformat all of them, but reformat a couple, rerun my "backup" batch file, reformat a couple more, etc.).

Reply
If you want to reply, then register here. Registration is free and your account is created instantly, so you can post right away.
Main Photography Discussion
UglyHedgehog.com - Forum
Copyright 2011-2024 Ugly Hedgehog, Inc.