Are you familiar with rsync? It is able to do all the things that you're talking about and a bit more (transfer over encrypted channel via ssh for example). To be honest, I've never used any of the rsync modules on CPAN (never needed anything the base binary can't do), but you should probably check them out before you start off.
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it. -- Brian W. Kernighan