Piping output from ntbackup through a compressor

Malo

Yak Mechanicum
Moderator
Legend
Supporter
I have the unenviable task of findout out whether I can pipe the data stream of NTBACKUP for win2k through a compression program like pkzip etc. so that a backup running to a smb mount on the win2k server can compress on-the-fly. Considering the backups are usually 50-60gb a night (minimum, but will be much more soon), doing compression afterwards is not a viable solution to management.

Immediately I thought this was impossible given ntbackup is a windows GUI program and doesnt use good ole STDOUT functions of dos and linux etc.

But the chief engineer at work whom has assigned me the task says it should be possible as he thinks it does use similar data piping functions like linux. Of course i've tried standard command routines in a batch file to attempt to pipe the information to a compressor like the GNU Zip program which accepts STDIN etc but to no avail.

Was wondering if anyone knows if this can be done and how?
 
Now i'm thinking I'm going to have to code some activeperl to do some named pipe data streams betweent he two programs..... turning into a nightmare.
 
You can try cygwin. You'll get all the linux glory including pipes 8) It's basically like a linux shell in windows. Did i say it's free?

You should deselect all the unnecessary packages (like all the devel stuff, thousands of libs and whatnot) at the setup since you really only need bash and bzip2/gzip.

Ah i just saw ntbackup got no STDOUT, nevermind then :?
 
Check if it is piping stuff through stderr?
Not sure how ntbackup works, do you end up with one large file on your backup media, or is it lots of smaller files?
If it is lots of smaller files, you could knock up a script which pipes files to pkzip as they appear on the backup media.

Good luck,

CC
 
Hmmm if the SMB folder its outputting to is a compressed folder then the computer you are sending it to should compress it as it gets the data. Heh assuming thats not a linux computer that the SMB folder is on of course.
 
thop said:
You can try cygwin. You'll get all the linux glory including pipes 8) It's basically like a linux shell in windows. Did i say it's free?

I'll check it out thanks.

Captain Chickenpants said:
If it is lots of smaller files, you could knock up a script which pipes files to pkzip as they appear on the backup media.

ntbackup writes to one large .bkf file :(

Diplo said:
Presumably the backup isn't already compressed? Just to save you wasting time!

ntbackup does not compress to any other media other than dat drives which have hardware compression. To all other media it is raw files.

Diplo said:
Hmmm if the SMB folder its outputting to is a compressed folder then the computer you are sending it to should compress it as it gets the data. Heh assuming thats not a linux computer that the SMB folder is on of course.

hehe unfortunately the smb mount on the 2k server is a mount from a linux box :p
 
I don't have any suggestions, but if you find the answer be sure to post it here. I'm curious if there's a simple solution.
 
Back
Top