Solved

using Robocopy

Posted on 2011-02-16
6
409 Views
Last Modified: 2012-05-11
Hi,
I am using Robocoy to copy files inbetween our differenent locations.  Working well.  I need to know the switches to put on so that robocopy copies only files that have changed or any new ones added once the full copy is already run on a particular folder to save time and bandwidth.
At the moment I am using
robocopy souce destination /MIR /SEC
Help plz
0
Comment
Question by:amanzoor
  • 2
  • 2
  • 2
6 Comments
 
LVL 34

Assisted Solution

by:Paul MacDonald
Paul MacDonald earned 250 total points
ID: 34907648
As I understand it, the way you're using it should work the way you want it to.
0
 
LVL 23

Accepted Solution

by:
jakethecatuk earned 250 total points
ID: 34907766
if you use /MIR, then files that no longer exist on the source will get purged from the destination - is that what you want?

also, you will not copy over any subfolders with your current syntax - consider adding /E if you want subfolders as well (I always put it in just in case folders get created)

adding /ZB should help avoid any access problems that you may come up against - can hepl with locked files.

adding /R:1 /W:1 will retry once and wait 1 second before trying again - useful with locked files.

/tee /log:{filename} will output what's going on to a file as well as a screen.

aside from that, your original command will work fine.
0
 
LVL 4

Author Comment

by:amanzoor
ID: 34907777
one more thing:  I am calling my script which is bak.bat from windows task schedular on server 2008.  Is there a way once the script is called by task schedular, it should actually show me the Dos window on screen where its running the files which are copied?
0
Superior storage. Superior surveillance.

WD Purple drives are built for 24/7, always-on, high-definition security systems. With support for up to 8 hard drives and 32 cameras, WD Purple drives are optimized for surveillance.

 
LVL 34

Expert Comment

by:Paul MacDonald
ID: 34907836
I think that will only happen if you're logged in as the user whose credentials are being used to launch the script.  That is, if you're logged in as administrator, and you're using the administrator account to run the batch file, you may see the command prompt.  Don't hold me to that.
0
 
LVL 23

Expert Comment

by:jakethecatuk
ID: 34907847
As I mentioned before, the '/tee /log:{filename}' command may help you as it will output what's going on to a file as well as a screen.  If you don't want it to screen, drop the '/tee' bit.
0
 
LVL 4

Author Closing Comment

by:amanzoor
ID: 34909149
Thanks Gentlemen, I really appreciate your time.
0

Featured Post

Don't lose your head updating email signatures!

Do your end users still have the wrong email signature? Do email signature updates bore you or fill you with a sense of dread? You can make this a whole lot easier on yourself by trusting an Exclaimer email signature management solution. Over 50 million users do...so should you!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Suggestions for hosted VOIP 5 46
Add Mac address reservation to Sonicwall TZ 210 router 1 44
Shoretel Edge Gateway 5 43
Classlful vs Classless subneting 18 61
PRTG Network Monitor lets you monitor your bandwidth usage, so you know who is using up your bandwidth, and what they're using it for.
For many of us, the  holiday season kindles the natural urge to give back to our friends, family members and communities. While it's easy for friends to notice the impact of such deeds, understanding the contributions of businesses and enterprises i…
This tutorial will walk an individual through the steps necessary to install and configure the Windows Server Backup Utility. Directly connect an external storage device such as a USB drive, or CD\DVD burner: If the device is a USB drive, ensure i…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now