ROBOCOPY - Create Backup Script - Page 21 - Windows 7 Help Forums
Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.

Windows 7: ROBOCOPY - Create Backup Script

19 Jan 2013   #200

Windows 7 Home Premium x64

I'll have a look around and see what I can find. Thanks.

My System SpecsSystem Spec
19 Jan 2013   #201

Microsoft Community Contributor Award Recipient

Windows 7 Ult. x64

Imaging using something like Macrium would probably be a better option.
My System SpecsSystem Spec
19 Jan 2013   #202

Windows 7 Home Premium x64

Yeah, but I'm not willing to pay for macrium and the free version doesn't let you exclude folders or backup certain folders.
My System SpecsSystem Spec
15 Apr 2013   #203

win server 2008 r2 (64bit)
Robocopy Log file Maximum Size

Dear Experts,

I have robocopy running continuously to mirror a folder every X hours. The windows 2008R2 server running the code is set to start the script at startup. Everything appears to be working fine, except the log files are becoming to be gigs big (too big to open with notepad, etc). I can manually stop the process, rename the log file, then the restart the process, but I am looking for a way to programmatically limit the size of the log file. Is this possible? Thanks!

My System SpecsSystem Spec
16 Apr 2013   #204

Microsoft Community Contributor Award Recipient

Windows 7 Ult. x64


Unfortunately, its not possible to limit the size of the logfile - that would defeat the purpose of the the logfile : to log everything it does.

A workaround might be to write to a new logfile every X hours, so you write to several different named logfiles during the course of a day. Perhaps using the date to name the logfile, like this?

SET log_fname=%prefix%%date:~-4,4%%date:~-10,2%%date:~-7,2%.log
My System SpecsSystem Spec
25 May 2013   #205
Nuno Lopes

Windows 7 Ultimate 32bit

Hi all,

Ive create a .bat file with the help of this tutorial, to make a backup of a directorie to my Skydrive account, this is the script.

robocopy.exe "C:\Radio\DXLab" "C:\Users\userid\SkyDrive\Radio\DXLab Backups\teste" /e /mir /np /z /tee /log:backup_log.txt

Now what I was trying to do is:

Inside DXLab directorie is an Folder - Luncher, with an Luncher.exe, that lunches 7 applications, and when I terminate the Luncher.exe it terminates all 7 applications.

Now what I wanna do is when Luncher.exe close, the Backup.bat will make the backup of that session.

I've already converted .bat to .exe and the script works good.

Any ideia on how to do this.

My System SpecsSystem Spec
01 Jul 2013   #206
Ezra NLV

Windows 7 Professional x64
How to MOVE deleted file/folder to another location instead of deletin


I am hoping if someone can help me with a backup solution I have in mind.

I have a production site and an offsite.
Daily, I want to do a backup from production to offsite.

Challenge is, if files or folders are deleted from source, then the files/folders from destination must be MOVED to a folder in \\OffSiteServer\ShareName1\DELETED\<DateOfBackup>\path structure to file/folder.
Using the purge or mir does not work for me (for the moment) as it just purges off the data from destination. I need to keep the data for several years.

- The idea is to have a snapshot every beginning of the month. (Easy to manage this using \\OffsiteServer\ShareName1\<DateOfBackup>.)
- Next, incremental daily backup using /MAXAGE:1 (Easy to manage this as well using \\OffsiteServer\ShareName1\<DateOfBackup> and /MAXAGE:1)
- But the MOVING of files/folder from destination is something I cannot figure out how to achieve.
- The monthly snapshot is not to be touched as it is a snapshot as at that point in time. A comparison has to be done somehow if a file/folder has been deleted, then copy it from last available backup date to \\OffSiteServer\ShareName1\DELETED\<DateOfBackup>\path structure to file/folder. Additionally, it has to check in the \\OffSiteServer\ShareName1\DELETED subfolders that if it has been deleted already, it should not copy the file/folder into DELETED again (i.e. no multiple copies daily).

No, I do not have a script at the moment as I am lost at this point.

I would appreciate any help anyone can render at this moment.

Thank you all for your kind help.

Best Regards,
My System SpecsSystem Spec
16 Dec 2013   #207

64 bit win 7 home premium
robocopy help

Hi all:

Just need a little help with closing the window automatically. I run a .bat file that contains:

robocopy C:\Users\VA\Documents T:\ /mir /maxage:3 /r:0 /w:0 /np /mt /xf Backup-TC /log+:robobackuplog.txt

I would like the window to close automatically when done. Tried adding exit, didn't work. Any help is appreciated!
My System SpecsSystem Spec
16 Dec 2013   #208

Microsoft Community Contributor Award Recipient

Windows 7 Ult. x64

Try using :

start "" robocopy C:\Users\VA\Documents T:\ /mir /maxage:3 /r:0 /w:0 /np /mt /xf Backup-TC /log+:robobackuplog.txt
My System SpecsSystem Spec
16 Dec 2013   #209

64 bit win 7 home premium

It didn't work...any other ideas?

I attached a screen shot.

Thanks again.

Attached Images
My System SpecsSystem Spec

 ROBOCOPY - Create Backup Script

Tutorial Tools

Similar help and support threads for2: ROBOCOPY - Create Backup Script
Windows 7 Tutorial Category
Robocopy Backup - ERROR 5 (0x00000005) Backup and Restore
Robocopy backup for personal folders Backup and Restore
I Need Help To Create REG. Script With Admin. Priv. For Reg. Editor? Customization
Anyone use robocopy to backup? Backup and Restore

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 13:37.
Twitter Facebook Google+

Windows 7 Forums

Seven Forums Android App Seven Forums IOS App