Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- From: "Pegasus \(MVP\)" <I.can@xxxxxxxxxx>
- Date: Tue, 23 Dec 2008 00:09:09 +0100
"scottedwards2000" <scottedwards2000@xxxxxxxxx> wrote in message
news:183099c4-fafd-4194-b7dc-3e65c30b76dd@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On Dec 22, 1:52 am, "Pegasus \(MVP\)" <I....@xxxxxxxxxx> wrote:
"scottedwards2000" <scottedwards2...@xxxxxxxxx> wrote in message
news:9e802dbb-08f8-4e49-87d7-b4f33afd98ae@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On Dec 1, 3:02 am, "Pegasus \(MVP\)" <I....@xxxxxxxxxx> wrote:
"scottedwards2000" <scottedwards2...@xxxxxxxxx> wrote in message
news:292a7016-3095-4c2e-87c2-fcd9499bd617@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Robocopy is great at showing in the output files that were skipped
because they were "Extra" (present in the destination only) -- this
appears to be the default behavior -- but the only way I seem to be
able to show files that were skipped because they are NEWER in the
destination (they are skipped because I'm using the /xo flag) is the
use the /v (verbose) flag, which shows me ALL skipped files. I don't
need to see all that because I'm using robocopy to move any new files
from a production directory to a backup directory, so of course there
will be many skipped files each time. But, I really want to guard
against the posibility that someone will put a NEW file in the backup
directory by accident instead of the Production directory, so I need
some way to quickly see the files that were skipped due to my use of
the /xo flag. Is there any way? Do I have to combine robocopy with
some text processing commands?
Standard redirection stuff:
robocopy d:\temp d:\Mon *.txt /xo /v | find /i "older"
Thanks, Pegasus.
Great suggestion -- I wasn't even aware of that find command. The
only issue is that I wanted a concise log that only listed the
exceptions, and that /v (verbose) flag causes the log to be too long.
So, using your idea, I came up with a 2-3 step solution that allows me
to have the concise log and still check for "older" files. Let me
know if you can think of a better way (although I still think Robocopy
should have as an option to show these "older" files alongside the
"extra" ones without having to use the verbose option).
1. first I run this to actually do the backup and list any Extra
files:
robocopy E:\Workspace\CW2008\Production E:\Workspace\CW2008\Backup /r:
10 /xo /log+:RoboLog.txt /s /np
and look through the log for any "EXTRA" files or directories
2. then run this to check for files not backed-up due to the
destination copy being NEWER:
robocopy E:\Workspace\CW2008\Production E:\Workspace\CW2008\Backup /r:
10 /xo /s /np /v | find /i "older"
3. if you see any output from #2, use the log from this command to
find the specific location of the file(s):
robocopy E:\Workspace\CW2008\Production E:\Workspace\CW2008\Backup /r:
10 /xo /log:RoboLogVerbose.txt /s /np /v
==============
I'm not quite with you. You write " I wanted a concise log that
only listed the exceptions", and this is precisely what the command
robocopy d:\temp d:\Mon *.txt /xo /v | find /i "older"
does: It lists the exceptions, nothing more, nothing less.- Hide quoted
text -
- Show quoted text -
Sorry, you are right -- it is just that I also wanted to keep the
format of the log where it lists the files that were copied and the
"Extra" files. What I meant by concise was not listing all of the
files like the verbose option does. But your command was very helpful
- I just have to live with the multiple steps.
Thanks again for your help.
=======================
This is called "scope creep" - having one set of specs at first, then
modifying them as time goes by . . .
If your multiple steps do the trick, fine. If they don't then the usual
method would be to massage the log file with a script. If you were to post a
short sample of the verbose report, then a manually edited version of what
you would really like to see then I could tell you if this would be a
trivial exercise or a big effort.
.
- Follow-Ups:
- References:
- Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- From: Pegasus \(MVP\)
- Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- From: scottedwards2000
- Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- From: Pegasus \(MVP\)
- Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- From: scottedwards2000
- Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- Prev by Date: Re: Ultra secure and user friendly file sharing on Server 2003?
- Next by Date: Re: Services stop randomly
- Previous by thread: Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- Next by thread: Re: With Robocopy can I just show files that were skipped due to being newer in the destination?
- Index(es):
Relevant Pages
|