rsync : salin file jika file lokal tidak ada. Jangan periksa ukuran file, waktu, checksum, dll

Saya menggunakan rsync untuk membuat cadangan satu juta gambar dari server linux ke komputer saya (windows 7 menggunakan Cygwin).

Perintah yang saya gunakan sekarang adalah:

rsync -rt --quiet --rsh='ssh -p2200' [email protected]:/home/XXX/public_html/XXX /cygdrive/images

Setiap kali proses terhenti, dan saya memulainya lagi, dibutuhkan waktu lama untuk memulai proses penyalinan. Saya pikir itu memeriksa setiap file jika ada pembaruan.

Gambar di server saya tidak akan berubah setelah dibuat.

Jadi, apakah ada cara yang lebih cepat untuk menjalankan perintah sehingga dapat menyalin file jika file lokal tidak ada tanpa memeriksa ukuran file, waktu, checksum dll...

Mohon sarannya.

Terima kasih


person Arnold    schedule 09.09.2013    source sumber


Jawaban (1)


apakah Anda mencoba tanda ini -- ini mungkin membantu, tetapi mungkin masih memerlukan waktu untuk melanjutkan transfer:

       --ignore-existing
          This tells rsync to skip updating files that already exist on the destination  (this  does  not  ignore
          existing directories, or nothing would get done).  See also --existing.

          This  option  is  a  transfer  rule,  not  an exclude, so it doesn't affect the data that goes into the
          file-lists, and thus it doesn't affect deletions.  It just limits the files that the receiver  requests
          to be transferred.

          This  option  can be useful for those doing backups using the --link-dest option when they need to con-
          tinue a backup run that got interrupted.  Since a --link-dest run is copied into a new directory  hier-
          archy  (when  it  is used properly), using --ignore existing will ensure that the already-handled files
          don't get tweaked (which avoids a change in permissions on the hard-linked files).  This does mean that
          this option is only looking at the existing files in the destination hierarchy itself.
person mnagel    schedule 09.09.2013