Windows – Scheduled backup of certain directories in Windows 7

7-zipbackupwindows 7windows task scheduler

I'm using Windows 7 and I need to schedule a daily backup that does the following:

  • The schedule needs to run daily at 7pm
  • The backup needs to generate a compressed archive of selected backup directories. These archives are ideally created with 7zip.
  • The archives generated by the backup need to be placed in a directory on my filesystem of my choosing.

I know Python and MSBatch, but I was hoping I wouldn't have to write a script for this. Are there any tools out there that will do what I need or at least something similar? I can use the Windows 7 task scheduler to execute this, but I don't know of what program it would execute.

Best Answer

You can accomplish this using the 7zip command line tool and the windows task scheduler.

Download the 7zip command line tool from http://www.7-zip.org/download.html and extract it to c:\7zip

Open notepad and create a list of the directories you want to backup, one path per line

c:\users\username\important directory1
c:\users\username\important directory2

Go to tools->save and make sure to change the drop down menu from ANSI to UTF-8 and save the file as c:\users\username\backuplist.txt

Now, open the windows task scheduler and create a new task. Give the task a name and select to run it daily at your specified time. Select that you want to run a program and fill in the fields as follows

Program: c:\7zip\7za.exe
Arguments: a c:\backups\backupname.7z -r @c:\users\username\backuplist.txt
run in: c:\7zip

Now save the task and you should have a working backup solution based on 7zip.

Related Question