Page 1 of 2

Folders syncronize - Backup Incremental

Posted: Mon Dec 24, 2012 5:15 pm
by brunellopulix
Hi

saving zip is definitely the best way, but if the data size and the better the significant incremental save.
I have my application which has reached 20 GB and I have developed a procedure for saving incremental certainly can be useful to others.

Happy Holidays!!

Brunello

Re: Folders syncronize - Backup Incremental

Posted: Mon Dec 24, 2012 8:32 pm
by esgici
Hi Brunello

Thank you very much this valuable sharing :)

Viva HMG, viva frienship :D

Re: Folders syncronize - Backup Incremental

Posted: Tue Dec 25, 2012 7:00 am
by Rathinagiri
Looks promising. Thanks a lot.

Re: Folders syncronize - Backup Incremental

Posted: Tue Dec 25, 2012 11:38 am
by esgici
Hi Brunello

I couldn't make a .zip :(

Require a "User Manual"

Regards

Re: Folders syncronize - Backup Incremental

Posted: Tue Dec 25, 2012 1:44 pm
by danielmaximiliano
Brunello Hello, thank you very much for sharing.
I can compile the project from HMG.3.1.1, hit New Record, indicated the path of dbf tables, indicated the destination folder but does not save the data, different methods probe INC, Full, with the same result ZIP
I use Windows 7 Home Premium 64.

Hola Brunello , muchas gracias por compartir.
puedo compilar el proyecto desde HMG.3.1.1, presiono New Record, indico la ruta de las tablas dbf, indico la carpeta destino pero no guarda estos datos, probe los distintos metodos INC, Full, ZIP con el mismo resultado
utilizo Windows 7 Home Premiun 64.
Folders Synchronization_2012-12-25_10-37-28.jpg
Folders Synchronization_2012-12-25_10-37-28.jpg (54 KiB) Viewed 6957 times
New Record - Properties_2012-12-25_10-41-02.jpg
New Record - Properties_2012-12-25_10-41-02.jpg (17.92 KiB) Viewed 6957 times

Re: Folders syncronize - Backup Incremental

Posted: Tue Dec 25, 2012 2:38 pm
by esgici
esgici wrote: Require a "User Manual" ...
... or a "Quick Start" guide,

or a "how to ..." guide into program itself ..

TIA

Re: Folders syncronize - Backup Incremental

Posted: Tue Dec 25, 2012 6:06 pm
by brunellopulix
Daniel:
have selected active?
Esgici:
how you've set?
Brunello

Re: Folders syncronize - Backup Incremental

Posted: Wed Dec 26, 2012 7:31 am
by brunellopulix
I'll explain:
1. New record
2. select origin and target (empty fields Target and Origin will be ignored)
3. select the type of backup
4. save

when you want to save changes flag active in the "ON" switch on back page and press Save.
Will be processed only records "INC" and "FULL" with the active flag to "ON".
At the end automatically "ON" will be "OFF"

for zip passing on the page and press compress.
Will be processed only records type "ZIP" with the active flag to "ON".
At the end automatically "ON" will be "OFF"

Setting max zip zip files must be> 1.
He should be between 5 and 10.

This is because for personal experience staff I learned that only one backup file is suicide.
Remember when doing backups to floppies?
enough that only one was unreadable and farewell backup.

My 20 GB then save them incrementally on four different partitions in less than a minute. Several times a day.

Brunello

Re: Folders syncronize - Backup Incremental

Posted: Wed Dec 26, 2012 6:26 pm
by esgici
Finally :!:

I got it :D

It seems that

- This software is more clever than I was expected; more details is more difficulties for user ;)
So needs a bit more user friendly UI...

- Recursive folder scans, multiple compressing methods...
may be soon a File Manager

- Harbour_Zip method require a bit more work: Windows doesn't recognize structure of .zip file, and show it as empty :(

Anyway this is a valuable work, useful utility, nice sharing;

thanks again :)

Viva HMG :D

Re: Folders syncronize - Backup Incremental

Posted: Wed Feb 13, 2013 8:30 pm
by Steed
Brunello

I'd make some changes in your code to avoid errors when some file is not copied to the target, due to some permissions.

Code: Select all

4 #xcommand TRY              => BEGIN SEQUENCE WITH { |oErr| Break( oErr ) }
5 #xcommand CATCH [<!oErr!>] => RECOVER [USING <oErr>] <-oErr->
6 #xcommand FINALLY          => ALWAYS
and to keep the date of the file in the target folder equal to the origen file

and another litte update "Do events" to avoid freezing while big files are being copied
FUNCTION CopyFileOK( src, dst )

local lOk2
private dDate,cTime

IF !('\' $ src)
src := SET(_SET_DEFAULT) + '\' + src
ENDIF
IF !('\' $ dst)
dst := SET(_SET_DEFAULT) + '\' + dst
ENDIF
TRY
lOk2:= HB_FCOPY( src, dst)
HB_FGETDATETIME( src , @dDate, @cTime )
hb_FSetDateTime( dst , @dDate, @cTime )
CATCH
lOk2:=.F.
END
Do Events
RETURN lOk2

Regards,

Ed