增加运行 rsync 进程的详细程度?

Ger*_*mar 28 rsync

我正在运行'rsync -a -i /foo /bar'。我时不时地想知道 rsync 目前正在做什么,而无需一直输出 -v 。是否可以通过发送终止信号来增加正在运行的进程的详细程度?

小智 39

我用 rsync -v --stats --progress


Mar*_*c M 13

我会将输出重定向到文件中,然后tail -f在需要时查看输出:

rsync -a /foo /bar >/tmp/rsync.log 2>&1
Run Code Online (Sandbox Code Playgroud)

需要的时候:

tail -f /tmp/rsync.log
Run Code Online (Sandbox Code Playgroud)


shg*_*Inc 11

除了 -i 之外,您还可以使用 --progress 来更详细地发送数据。例如:

rsync -ai --progress .....
Run Code Online (Sandbox Code Playgroud)

如果需要越来越多,更好的方法是像上面@Marc M 所说的那样记录它。