Security.. not really. It's a VPN connection. Performance? Yes. Sanity? I have to do this under this circumstances.
I don't control the firewall so I have to use a windows share. I'll try to port the tools to use ftp in the near by future but till then I still think perl does something wrong and leaks memory.
Please give me hints how to stop the memory leak and don't tell me that rsync is better because I know that. :) I found it a little bit strange that just by using win32 module ("use win32") perls leaks less memory by fork,copy,exit. Can you give me a direction on how to investigate this? I am new to perl and I have created just small scripts, nothing complicated or advanced
Well, I'm really not a Windows programmer. When I have to do something on Windows I try to keep it as simple as possible.
One thing you could try is actually spawning a new process rather than using Perl's thread-based fork(). I believe you do that with Win32::Process. You could spawn a separate process to copy each file, which might help keep memory use under control.