Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
html
Please note that &&, ||, and -, are documented at the bottom of this page.
PUSH:
PULL:
ssh target_address cat remotefile > localfile
ssh target_address dd if=remotefile | dd of=localfile
ssh target_address cat "<" remotefile >localfile
ssh target_address cat "<" remotefile.gz | gunzip >localfile
COMPARE:
###This one uses CPU cycles on the remote server to compare the files:
ssh target_address cat remotefile | diff - localfile
1 of 4 30-03-2011 21:44
Network File Copy using SSH http://ultra.ap.krakow.pl/~bar/DOC/ssh_backup.html
Of course there is always ftp, scp2, nfs, smb and other methods as well.
RSH works just the same as SSH I'm sure, it's jut that ssh or ssh should give
you better security.
localfile and remotefile can be files, directories, images, hard drive partitions, or
hard drives.
FTP VIEW:
FTP PUSH:
2 of 4 30-03-2011 21:44
Network File Copy using SSH http://ultra.ap.krakow.pl/~bar/DOC/ssh_backup.html
FTP PULL:
zcat Fig.ps.Z | gv -
gunzip -c Fig.ps.gz | gv -
tar xvf mydir.tar
tar xvf - < mydir.tar
cat mydir.tar | tar xvf -
tar cvf mydir.tar .
tar cvf - . > mydir.tar
tar cf - . | (cd ~/newdir; tar xf -)
gunzip -c foo.gz > bar
cat foo.gz | gunzip > bar
zcat foo.gz > bar
gzip -c foo > bar.gz
cat foo | gzip > bar.gz
cat foo | gzip > bar.gz
SSH Keys
see http://www.cpqlinux.com/sshkeys.html
3 of 4 30-03-2011 21:44
Network File Copy using SSH http://ultra.ap.krakow.pl/~bar/DOC/ssh_backup.html
The dash "-" is used to reference either standard input or standard output. The
context in which the dash is used is what determines whether it references
standard input or standard output.
Homepage: http://www.cpqlinux.com
Site Map: http://www.cpqlinux.com/sitemap-date.html
4 of 4 30-03-2011 21:44