• Welcome to Tux Reports: Where Penguins Fly. We hope you find the topics varied, interesting, and worthy of your time. Please become a member and join in the discussions.

is there a dos command that works like xcopy but compares file sizesor last modified dates?

M

Mike S

Flightless Bird
I use xcopy to backup large amounts of data from three different parent
folders to a 2nd hdd. It works great, but I would like to use a more
efficient method of only backing up files that are a different size,
have a different last modified date, or don't already exist, so no files
that haven't been modified since the last backup will be copied again.
Is there a DOS command similar to XCopy that will allow me to do this? I
like using DOS commands because they are fast.
 
M

Mike S

Flightless Bird
Re: is there a dos command that works like xcopy but compares filesizes or last modified dates?

On 9/3/2010 3:36 PM, Mike S wrote:
> I use xcopy to backup large amounts of data from three different parent
> folders to a 2nd hdd. It works great, but I would like to use a more
> efficient method of only backing up files that are a different size,
> have a different last modified date, or don't already exist, so no files
> that haven't been modified since the last backup will be copied again.
> Is there a DOS command similar to XCopy that will allow me to do this? I
> like using DOS commands because they are fast.


Sorry, I posted too soon, turns out XCopy has a /D that I didn't read
closely enough, it does exactly what I wanted:

XCOPY source [destination] [/D[:date]]

/d[:mm-dd-yyyy] : Copies source files changed on or after the specified
date only. If you do not include a mm-dd-yyyy value, xcopy copies all
Source files that are newer than existing Destination files. This
command-line option allows you to update files that have changed.
 
Y

Yousuf Khan

Flightless Bird
Re: is there a dos command that works like xcopy but compares filesizesor last modified dates?

On 03/09/2010 6:36 PM, Mike S wrote:
> I use xcopy to backup large amounts of data from three different parent
> folders to a 2nd hdd. It works great, but I would like to use a more
> efficient method of only backing up files that are a different size,
> have a different last modified date, or don't already exist, so no files
> that haven't been modified since the last backup will be copied again.
> Is there a DOS command similar to XCopy that will allow me to do this? I
> like using DOS commands because they are fast.


Xcopy itself does that. Use the "/m" option.

Yousuf Khan
 
M

Mike S

Flightless Bird
Re: is there a dos command that works like xcopy but compares filesizesor last modified dates?

On 9/3/2010 4:09 PM, Yousuf Khan wrote:
> On 03/09/2010 6:36 PM, Mike S wrote:
>> I use xcopy to backup large amounts of data from three different parent
>> folders to a 2nd hdd. It works great, but I would like to use a more
>> efficient method of only backing up files that are a different size,
>> have a different last modified date, or don't already exist, so no files
>> that haven't been modified since the last backup will be copied again.
>> Is there a DOS command similar to XCopy that will allow me to do this? I
>> like using DOS commands because they are fast.

>
> Xcopy itself does that. Use the "/m" option.
>
> Yousuf Khan


Thanks, that wasn't clear from this site:

http://www.lagmonster.org/docs/DOS7/z-xcopy.html

/M Only copies files with the archive attribute set, turning off
the archive attribute of the source files.
----------------------------------------

This was more to your point:

ARCHIVING FILES

Use Xcopy's /m switch to back up only files that have been changed since
the last time they were Xcopied. This works only on files that have been
Xcopied at least once before and will not work on un-Xcopied files.

When Xcopy copies a file, it resets the original file's archive bit from
1 to 0. For more on archive bits, see DOS Attrib. Whenever you update a
file, the archive bit is set to 1. When you use the /m switch, Xcopy
copies only files with the archive bit set to 1.

The following example backs up all files onto the D disk:

xcopy *.* d: /m

ARCHIVE ONE HARD DISK TO ANOTHER

The following example copies everything from the C: drive to the D:
drive that has changed since the last time the files on C: were Xcopied.
This includes the root and all subdirectories. The /s switch is used
here in order to include all subdirectories.

xcopy c:/*.* d:/ /s /m

http://www.answers.com/topic/dos-xcopy

Thanks,
Mike
 
M

mm

Flightless Bird
Re: is there a dos command that works like xcopy but compares file sizes or last modified dates?

On Fri, 03 Sep 2010 15:36:00 -0700, Mike S <mscir@yahoo.com> wrote:

>I use xcopy to backup large amounts of data from three different parent
>folders to a 2nd hdd. It works great, but I would like to use a more
>efficient method of only backing up files that are a different size,
>have a different last modified date, or don't already exist, so no files
>that haven't been modified since the last backup will be copied again.
>Is there a DOS command similar to XCopy that will allow me to do this? I
>like using DOS commands because they are fast.


Don't know, but xxcopy at www.xxcopy.com has an enormous set of
options, backward compatible with xcopy. It will do things you've
never considered doing. It has its own yahool discussion list if
there are questions.

Free to non-commerical users and not that expensive elsewise (is that
a word?)
 
Y

Yousuf Khan

Flightless Bird
Re: is there a dos command that works like xcopy but compares filesizesorlast modified dates?

On 9/3/2010 7:48 PM, Mike S wrote:
> On 9/3/2010 4:09 PM, Yousuf Khan wrote:
>> Xcopy itself does that. Use the "/m" option.
>>
>> Yousuf Khan

>
> Thanks, that wasn't clear from this site:
>
> http://www.lagmonster.org/docs/DOS7/z-xcopy.html
>
> /M Only copies files with the archive attribute set, turning off
> the archive attribute of the source files.
> ----------------------------------------
>
> This was more to your point:
>
> ARCHIVING FILES
>
> Use Xcopy's /m switch to back up only files that have been changed since
> the last time they were Xcopied. This works only on files that have been
> Xcopied at least once before and will not work on un-Xcopied files.
>
> When Xcopy copies a file, it resets the original file's archive bit from
> 1 to 0. For more on archive bits, see DOS Attrib. Whenever you update a
> file, the archive bit is set to 1. When you use the /m switch, Xcopy
> copies only files with the archive bit set to 1.
>
> The following example backs up all files onto the D disk:
>
> xcopy *.* d: /m
>
> ARCHIVE ONE HARD DISK TO ANOTHER
>
> The following example copies everything from the C: drive to the D:
> drive that has changed since the last time the files on C: were Xcopied.
> This includes the root and all subdirectories. The /s switch is used
> here in order to include all subdirectories.
>
> xcopy c:/*.* d:/ /s /m
>
> http://www.answers.com/topic/dos-xcopy


Yeah, Xcopy has been around since the old DOS days, and it has always
been a bit of a complex command to master, most people never saw a need
to master it, relying instead on the simpler Copy command. The options
were always explained arcanely. They'd never explain anything simply and
properly, instead relying on comp sci lingo.

Yousuf Khan
 
N

Nil

Flightless Bird
Re: is there a dos command that works like xcopy but compares file sizes or last modified dates?

On 03 Sep 2010, mm <NOPSAMmm2005@bigfoot.com> wrote in
microsoft.public.windowsxp.general:

> Don't know, but xxcopy at www.xxcopy.com has an enormous set of
> options, backward compatible with xcopy. It will do things
> you've never considered doing. It has its own yahool discussion
> list if there are questions.


Robocopy could be another good alternative. Very flexible and
fine-grained options:

<http://www.microsoft.com/downloads/...69-57ff-4ae7-96ee-b18c4790cffd&displaylang=en
 
A

Anthony Buckland

Flightless Bird
Re: is there a dos command that works like xcopy but compares file sizes or last modified dates?

"Mike S" <mscir@yahoo.com> wrote in message
news:i5rttu$dvf$1@news.eternal-september.org...
> On 9/3/2010 3:36 PM, Mike S wrote:
>> I use xcopy to backup large amounts of data from three different parent
>> folders to a 2nd hdd. It works great, but I would like to use a more
>> efficient method of only backing up files that are a different size,
>> have a different last modified date, or don't already exist, so no files
>> that haven't been modified since the last backup will be copied again.
>> Is there a DOS command similar to XCopy that will allow me to do this? I
>> like using DOS commands because they are fast.

>
> Sorry, I posted too soon, turns out XCopy has a /D that I didn't read
> closely enough, it does exactly what I wanted:
>
> XCOPY source [destination] [/D[:date]]
>
> /d[:mm-dd-yyyy] : Copies source files changed on or after the specified
> date only. If you do not include a mm-dd-yyyy value, xcopy copies all
> Source files that are newer than existing Destination files. This
> command-line option allows you to update files that have changed.
>


In a backup job I use to save My Documents as a whole at
frequent intervals, I use the following, which you could read
up on by going to DOS command mode and entering
help xcopy

/D /E /C /Q /H /R /Y /K

See if this would meet your needs.
 
P

(PeteCresswell)

Flightless Bird
Re: is there a dos command that works like xcopy but compares file sizes or last modified dates?

Per Mike S:
>I use xcopy to backup large amounts of data from three different parent
>folders to a 2nd hdd. It works great, but I would like to use a more
>efficient method of only backing up files that are a different size,
>have a different last modified date, or don't already exist, so no files
>that haven't been modified since the last backup will be copied again.
>Is there a DOS command similar to XCopy that will allow me to do this? I
>like using DOS commands because they are fast.


I use something called SecondCopy.

Probably slower but, since it has a scheduling feature, speed is
moot - I just set it and forget it.

Also has an option to keep N superceded copies.
--
PeteCresswell
 
M

mm

Flightless Bird
Re: is there a dos command that works like xcopy but compares file sizes or last modified dates?

On Fri, 03 Sep 2010 20:31:35 -0400, mm <NOPSAMmm2005@bigfoot.com>
wrote:

>On Fri, 03 Sep 2010 15:36:00 -0700, Mike S <mscir@yahoo.com> wrote:
>
>>I use xcopy to backup large amounts of data from three different parent
>>folders to a 2nd hdd. It works great, but I would like to use a more
>>efficient method of only backing up files that are a different size,
>>have a different last modified date, or don't already exist, so no files
>>that haven't been modified since the last backup will be copied again.
>>Is there a DOS command similar to XCopy that will allow me to do this? I
>>like using DOS commands because they are fast.

>
>Don't know, but xxcopy at www.xxcopy.com has an enormous set of
>options, backward compatible with xcopy. It will do things you've


In case I wasn't clear XXCopy is free and runs in DOS or a DOSbox, and
I think in almost all cases it runs as fast as dos commands, except I
guess for every selection criterion, it has to do one more compare and
branch, but you can't get somethin' for nothin', right. If you use
the progress bar, that can slow things down a lot because it does two
passes, one to find out how much there is to copy and one to copy it.
He's working on starting the copy while the count is still going on,
or maybe he's finished that already. "He" is the author, who
frequently answers questions on the mailing list.

There is a clone option to xxcpy, which has all the options to make
sure the files on the copy are exactly the same as the files on the
original.

And there is also XXClone, which makes a file by file bootable copy of
the original partition. Not an image copy so that incremental
updates are easily done. Only the full copy version is free and the
other one with incremental and differential copies is 40 dollars iirc,
but other clone products don't have the ability, iiuc, to do that.

He can only restore to the original computer, it seems, while Acronis
True Value Home and some others can transfer a system to another
computer.

>never considered doing. It has its own yahool discussion list if
>there are questions.
>
>Free to non-commerical users and not that expensive elsewise (is that
>a word?)
 
Top