Periodic folder "backups"

Problems? Post here...
Post Reply
eppik
Fame ! Where are the chicks?!
Fame ! Where are the chicks?!
Posts: 212
Joined: 26 Mar 2006, 16:00
18
Location: Infinite Loop
Contact:

Periodic folder "backups"

Post by eppik »

I would like to know what the best way to periodically copy a folder to another folder would be (on windows)

Lets say I have folder A, and I want to copy that folder to folder B every 30 minutes.

Does windows have anything that will do this without craping out or are there any good 3rd party software you use?

User avatar
bad_brain
Site Owner
Site Owner
Posts: 11636
Joined: 06 Apr 2005, 16:00
19
Location: In your eye floaters.
Contact:

Re: Periodic folder "backups"

Post by bad_brain »

hm, Windows has a built-in backup tool, have a look here:
http://www.addictivetips.com/windows-ti ... windows-7/" onclick="window.open(this.href);return false;

but I doubt it's really practicable, because it seem you always just have the latest backup version and you are not able to jump back to the 3rd last backup you made for example.

have a look at this tool, looks promising:
http://www.hinxsoft.com/index.php?page=bueasy" onclick="window.open(this.href);return false;

damn Windows, in Linux you could do this with a single line as cronjob.. :roll:
Image

eppik
Fame ! Where are the chicks?!
Fame ! Where are the chicks?!
Posts: 212
Joined: 26 Mar 2006, 16:00
18
Location: Infinite Loop
Contact:

Re: Periodic folder "backups"

Post by eppik »

Its not really backing up I dont need to retrieve previous versions

All I need is:
-Wipe destination folder (B)
-Copy all contents of A folder to B
-Wait x minutes
-Repeat

Do batch files support loops?

User avatar
bad_brain
Site Owner
Site Owner
Posts: 11636
Joined: 06 Apr 2005, 16:00
19
Location: In your eye floaters.
Contact:

Re: Periodic folder "backups"

Post by bad_brain »

um, sure. but you could do that with the on-board Windows function shown in the first link...;)
Image

User avatar
Gogeta70
^_^
^_^
Posts: 3275
Joined: 25 Jun 2005, 16:00
18

Re: Periodic folder "backups"

Post by Gogeta70 »

Yes, batch files support loops, but running in constant loop like that is going to run your cpu at 100% the whole time. Shouldn't be all that laggy though.

You can write a batch file to do something like this though, without a loop:

This is just pseudo-code mostly

Code: Select all

@echo off
del C:\my\backup\directory\*.*
copy C:\old\stuff C:\my\backup\directory\

at [time] start this.bat

"AT" is an actual windows command, look it up.
I'm not sure if you can get the current time AND add minutes/hours to it using batch scripting though, so this may not be an option.

Just fyi, this is how you do a batch loop:

Code: Select all

:myloop
some stuff here...

goto myloop
Hope this helps, later.
¯\_(ツ)_/¯ It works on my machine...

User avatar
Lundis
Distorter of Reality
Distorter of Reality
Posts: 543
Joined: 22 Aug 2008, 16:00
15
Location: Deadlock of Awesome
Contact:

Re: Periodic folder "backups"

Post by Lundis »

You'd want to switch those lines before trying the script, copy before deleting the files... xD

User avatar
Gogeta70
^_^
^_^
Posts: 3275
Joined: 25 Jun 2005, 16:00
18

Re: Periodic folder "backups"

Post by Gogeta70 »

No, because then you'd be deleting the files that you copied. He said he wanted to wipe the backup directory before copying the new backup over.
¯\_(ツ)_/¯ It works on my machine...

User avatar
Lundis
Distorter of Reality
Distorter of Reality
Posts: 543
Joined: 22 Aug 2008, 16:00
15
Location: Deadlock of Awesome
Contact:

Re: Periodic folder "backups"

Post by Lundis »

oh right, my mistake #-o

Post Reply