browser icon
You are using an insecure version of your web browser. Please update your browser!
Using an outdated browser makes your computer unsafe. For a safer, faster, more enjoyable user experience, please update your browser today or try a newer browser.

Rsync using ssh non-standart port ssh

Posted by on December 25, 2011

Before we start to explain deep, let me introduce rsync (evil_grin)

What is Rsync ? (lonely)

rsync is a file transfer program for Unix systems. rsync uses the “rsync algorithm” which provides a very fast method for bringing remote files into sync. It does this by sending just the differences in the files across the link, without requiring that both sets of files are present at one of the ends of the link beforehand (scenic) .

Rsync features 

  • Can update whole directory trees and filesystems
  • Optionally preserves symbolic links, hard links, file ownership, permissions, devices and times
  • Requires no special privileges to install
  • Internal pipelining reduces latency for multiple files
  • Can use rsh, ssh or direct sockets as the transport
  • Supports anonymous rsync which is ideal for mirroring

The Basic command rsync. (thinking)

rsync -av <source> <target>

 

eg.

rsync -av 192.168.1.100:/home/henry/ /backup/home/

 
or you can specify user

rsync -av henry@192.168.1.100:/home/henry/ /backup/home/

 
Rsync via ssh

rsync -ave ssh henry@192.168.1.100:/home/henry/ /backup/home/

 
Rsync with a non-standart ssh port

eg. ssh server listen on port 22222

rsync -av ‘ssh -p 22222′  henry@192.168.1.100:/home/henry/ /backup/home/

 

Leave a Reply

Your email address will not be published. Required fields are marked *

*


4 + = eleven

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

:)) :) :D (LOL) :-P (woot) ;-) :-o X-( ;-( :-& (angry) (annoyed) (bye) B-) (cozy) (sick) (: (goodluck) (griltongue) (mmm) (hungry) (music) (tears) (tongue) (unsure) (highfive) (dance) (doh) (brokenheart) (drinking) (girlkiss) (rofl) (money) (rock) (nottalking) (party) (sleeping) (thinking) (bringit) (worship) (applause) 8-) (gym) (heart) (devil) (lmao) (banana_cool) (banana_rock) (evil_grin) (headspin) (heart_beat) (ninja) (haha) (evilsmirk) (bigeyes) (funkydance) (idiot) (lonely) (scenic) (hassle) (panic) (okok) (yahoo) (blush) (fish_hit) (muhaha) (muscle) (taser) (beer) (coffee) (banana_ninja) (goal) (fireworks) (smileydance) (dance_bzz) (rusian)