Tool

skoltogyan's picture
tool
Reads:

5066

Score:
0
0
 
Comments:

0

Create Backup Copy of File Every N minutes

(View Disclaimer)

license: 
Free

This Perl script creates backup copy of file every N minutes.

The Perl script works on the Server console.

Files:
bcpspc.pl
bcpspc.cfg

Example:
\\server\docum\wrk\home\user1\file.sxc
will be created every 15 min from 8:00 to the 21:00 files here:
\\server\docum\wrk\home\user1\bcp\yyyymmddhhmm.sxc if file.sxc is opened by user.

How to configure:

  1. create folder:
    sys:\etc\1bcpspc
  2. create file
    sys:\etc\1bcpspc\bcpspc.cfg
    with info as in the attachment: bcpspc.cfg
  3. put file bcpspc.pl to the folder: sys:\perl\scripts
  4. create file: sys:\system\1bcpspc.ncf with this text:
    perl sys:\perl\scripts\bcpspc.pl
  5. Create folders for BACKUP and LOG files (as in the example this will be:)
    \\server\docum\wrk\home\user1\bcp
    \\server\docum\wrk\home\user1\bcp\log
  6. Create empt files:
    \\server\docum\wrk\home\user1\bcp\log\tfile.tsk
    \\server\docum\wrk\home\user1\bcp\log\lfile.tsk
  7. Load from the server console: TBX.NLM
  8. Run from the server console script:
    1bcpspc.ncf

This script, from the example, will create a Backup copy of file.sxc every 15 min.

This will be if file LOCK by user application.

How to stop the script:

Create the file: SYS:\bcpspc.txt

Before Run the script again, need RENAME SYS:\bcpspc.txt to the SYS:\bcpspc.tx

AttachmentSize
bcpspc.zip1.63 KB

Disclaimer: As with everything else at Cool Solutions, this content is definitely not supported by Novell (so don't even think of calling Support if you try something and it blows up).

It was contributed by a community member and is published "as is." It seems to have worked for at least one person, and might work for you. But please be sure to test, test, test before you do anything drastic with it.




User Comments

© 2013 Novell