Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Incremental bat backup script.

Posted on 2009-07-07
13
Medium Priority
?
926 Views
Last Modified: 2012-06-21
Hi EE.

i need a little help for a simple script.

Wants to some folders to be incremental backup

From C:\App -> E:\App
From C:\List -> E:\App.

I have worked a bit with my own script, but cant get it to work 100 %.

If i delete a file in C:\App the file also should be deleted in E:\App

Thank you
0
Comment
Question by:JarlK
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 5
  • 3
13 Comments
 
LVL 9

Accepted Solution

by:
DCMBS earned 1000 total points
ID: 24792788
I would use the following delta copy utilty for this.  when set up correctly it will synchronise the destination and source folders automatically and is very efficient at copying the files.

http://www.aboutmyip.com/AboutMyXApp/DeltaCopy.jsp
0
 
LVL 19

Assisted Solution

by:deroode
deroode earned 200 total points
ID: 24792868
Normally, you would use a tool like robocopy  to perform such a synchronization.

Robocopy.exe c:\app e:\app /mir

The culprit however is that you are trying to synchronize from two directories to one. Robocopy will mirror the entire directory, thus with the above command deleting everything that originally came from C:\list

A solution could be devised if the filenames in C:\app and c:\list are sufficiently different that the filenames that are found in c:\list can be excluded in the robocopy command from c:\app, and vice versa.

for instance:

robocopy c:\app e:\app /mir /XF *.lst
robocopy c:\list e:\app /mir /XF *.exe


robocopy can be found here:
http://www.microsoft.com/downloads/details.aspx?FamilyID=9D467A69-57FF-4AE7-96EE-B18C4790CFFD&displaylang=en
0
 
LVL 9

Expert Comment

by:DCMBS
ID: 24792910
Robocopy is a good tool and works similarly to deltacopy. The main difference is that robocopy copies the entire file every time it detects a change whereas deltacopy will only copy changes to the file.  If you have large files in which only a small parts are changed then deltacopy can be very efficient.
0
Veeam Task Manager for Hyper-V

Task Manager for Hyper-V provides critical information that allows you to monitor Hyper-V performance by displaying real-time views of CPU and memory at the individual VM-level, so you can quickly identify which VMs are using host resources.

 

Author Comment

by:JarlK
ID: 24793014
I like deltatool.

I can get it to work on my machine, but not on my costumers ?




Connection is sucessful when i try to test the connection!
Executing: rsync.exe  -v -rlt -z --delete "/cygdrive/C/util/" "HP11103174822::Villadsenssmedie	/util/"
@ERROR: Unknown module 'Villadsenssmedie	'
 
rsync error: error starting client-server protocol (code 5) at /home/lapo/packaging/rsync-3.0.4-1/src/rsync-3.0.4/main.c(1504) [sender=3.0.4]
 
Error starting client-server protocol
Rsync.exe returned an error. Will try again. This is retry number 1 of 5
 
Executing: rsync.exe  -v -rlt -z --delete "/cygdrive/C/util/" "HP11103174822::Villadsenssmedie	/util/"
@ERROR: Unknown module 'Villadsenssmedie	'
rsync error: error starting client-server protocol (code 5) at /home/lapo/packaging/rsync-3.0.4-1/src/rsync-3.0.4/main.c(1504) [sender=3.0.4]
 
Error starting client-server protocol
Rsync.exe returned an error. Will try again. This is retry number 2 of 5
 
Executing: rsync.exe  -v -rlt -z --delete "/cygdrive/C/util/" "HP11103174822::Villadsenssmedie	/util/"
@ERROR: Unknown module 'Villadsenssmedie	'
rsync error: error starting client-server protocol (code 5) at /home/lapo/packaging/rsync-3.0.4-1/src/rsync-3.0.4/main.c(1504) [sender=3.0.4]
 
Error starting client-server protocol
Rsync.exe returned an error. Will try again. This is retry number 3 of 5
 
Executing: rsync.exe  -v -rlt -z --delete "/cygdrive/C/util/" "HP11103174822::Villadsenssmedie	/util/"
@ERROR: Unknown module 'Villadsenssmedie	'
rsync error: error starting client-server protocol (code 5) at /home/lapo/packaging/rsync-3.0.4-1/src/rsync-3.0.4/main.c(1504) [sender=3.0.4]
 
Error starting client-server protocol
Rsync.exe returned an error. Will try again. This is retry number 4 of 5
 
Executing: rsync.exe  -v -rlt -z --delete "/cygdrive/C/util/" "HP11103174822::Villadsenssmedie	/util/"
@ERROR: Unknown module 'Villadsenssmedie	'
rsync error: error starting client-server protocol (code 5) at /home/lapo/packaging/rsync-3.0.4-1/src/rsync-3.0.4/main.c(1504) [sender=3.0.4]
 
Error starting client-server protocol
Profile 'test' executed in 344 milliseconds. One or more errors were encountered.

Open in new window

0
 
LVL 9

Expert Comment

by:DCMBS
ID: 24793072
HP11103174822::Villadsenssmedie      /util/

This doesn't right if you are copying to a remote machine.

See the following link for how to specify the connection.

http://everythinglinux.org/rsync/
0
 
LVL 19

Expert Comment

by:deroode
ID: 24793076
HP11103174822 can be found without full domain name?

Villadsenssmedie is configured as a virtual directory on the receiving server?
0
 

Author Comment

by:JarlK
ID: 24793123
Its just a single computer.

The network name of the computer is : HP11103174822

So i have installed the server and client on same machine!
0
 
LVL 9

Expert Comment

by:DCMBS
ID: 24793137
I can get it to work on my machine, but not on my costumers ?

Apologies, I don't quite understand.

what is the difference between a set up that works on your machine, and the setup that doesn't work
0
 

Author Comment

by:JarlK
ID: 24793143
DCMBS : I just tried to make a test on my own pc, where i had no problems at all.
0
 
LVL 9

Expert Comment

by:DCMBS
ID: 24793159
So we need to pin down the difference between machines ?
0
 

Author Comment

by:JarlK
ID: 24793182
I have found the error!

:) I have made a space in the name of the "server" That is not allowed! Thank you!


Very nice app.
0
 
LVL 19

Expert Comment

by:deroode
ID: 24793203
Very nice app indeed.

And does it handle the two sources - one destination conflict without removing files?
0
 

Author Comment

by:JarlK
ID: 24793277
Yes !

Very nice!
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

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

Being a system administrator some time we require to do things remotely, one of them is installing software. Here I am going to tell you how to install software through wmic (Windows management instrument console). I am not at all saying that this i…
With User Account Control (UAC) enabled in Windows 7, one needs to open an elevated Command Prompt in order to run scripts under administrative privileges. Although the elevated Command Prompt accomplishes the task, the question How to run as script…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …

618 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