既存のファイルと同期されたファイルのrsync出力を非表示にする方法は?

既存のファイルと同期されたファイルのrsync出力を非表示にする方法は?

私は出力を持っています:

sent 66 bytes  received 12 bytes  156.00 bytes/sec
total size is 204  speedup is 2.62
sending incremental file list

sent 67 bytes  received 12 bytes  158.00 bytes/sec
total size is 204  speedup is 2.58
sending incremental file list

sent 66 bytes  received 12 bytes  156.00 bytes/sec
total size is 204  speedup is 2.62
sending incremental file list

sent 67 bytes  received 12 bytes  158.00 bytes/sec
total size is 204  speedup is 2.58
sending incremental file list

sent 67 bytes  received 12 bytes  158.00 bytes/sec
total size is 204  speedup is 2.58
sending incremental file list

sent 67 bytes  received 12 bytes  158.00 bytes/sec
total size is 204  speedup is 2.58
sending incremental file list

sent 67 bytes  received 12 bytes  158.00 bytes/sec
total size is 204  speedup is 2.58
sending incremental file list

sent 67 bytes  received 12 bytes  158.00 bytes/sec
total size is 204  speedup is 2.58
sending incremental file list
mysql-bin.000118
            204 100%    0.00kB/s    0:00:00 (xfr#1, to-chk=0/1)

sent 229 bytes  received 35 bytes  528.00 bytes/sec
total size is 204  speedup is 0.77

次のように表示する方法はありますか?

sending incremental file list
mysql-bin.000118
            204 100%    0.00kB/s    0:00:00 (xfr#1, to-chk=0/1)

sent 229 bytes  received 35 bytes  528.00 bytes/sec
total size is 204  speedup is 0.77

これが唯一の欠落ファイルです。

編集:BowlOfRedに感謝します。以下を使用しています。

rsync -azvp --progress --ignore-existing

今回の答えでasを使うとうまくいきます。

rsync -azp --info=name,progress --ignore-existing

ベストアンサー1

rsyncを呼び出す方法や使用しているバージョンについては言及していません。これはあなたが使用しているものと似ており、最後に統計とともに増分リストの進行状況を提供するようなものを-P設定します。-v

適用された転送に「デルタ送信」と終了統計を提供する方法がわかりませんが、ファイルが転送されないときに出力が自動的に維持されるように、両方を削除して進行状況/デルタのみを提供できます。 rsync 3.xの場合は、-Pより細かいバージョンに置き換えるのが最善です--info

rsync 3.2.7の例:

$ rsync -a --info=name,progress dir/ dir2
$ touch dir/a
$ rsync -a --info=name,progress dir/ dir2
a
              0 100%    0.00kB/s    0:00:00 (xfr#1, to-chk=2/4)
$

おすすめ記事