Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a fairly ancient Fedora server which I have inherited from another company. I only have access to the server VIA SSH. Here are some details of the server:

Linux REMOVED 2.6.15-1.1831_FC4 #1 Tue Feb 7 13:37:42 EST 2006 i686 i686 i386 GNU/Linux Fedora Core release 4 (Stentz) LSB_VERSION="1.3"(Stentz) LSB_VERSION="1.3"

I need to get a couple of GB of files off of this server with permissions preserved. The problem is that the server is almost at capacity. When I try to make a .tgz file, the space used fills the server to 100% capacity. There are live websites running off this server, so simply deleting the files to make room is not an option.

Is there a simple way to transfer these files from the server to another location as a .tgz file, but in such a way that I don't need to consume my local hard-drive resources?

I have considered rsync, but I want to make a copy with permissions preserved for backup purposes on my development box (Windows 7), so from my perspective creating a .tgz file is preferable. Does anyone have any experience in a similar situation?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

If you had a *nix box running ssh server on the receiving end you could do something like this on the source machine....

tar cvf - . | gzip -c -1 | ssh receiving-user@receiving-host cat ">" archive.tar.gz

This should tar up the files on the remote machine in the current directory and send the output to stdout, feeds to gzip, which feeds to cat over ssh on the receiving machine and then redirected to your archive file. You may have to modify the above command line depending on versions of utilities included with the OS's and your shells.

With ONLY the Windows box on the receiving end you could install an NFS server for Windows or share SMB over the internet and mount it as a filesystem on the remote machine. You would then be able to save directly to that filesystem, but using it over a non local link will probably be painful.

share|improve this answer
    
Awesome - seems to work nicely. I'm using another server as a proxy, but the transfer command works as expected. –  Aaron Newton Sep 16 '10 at 5:28

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.