원격 rsync가 경로에 있더라도 rsync에 –rsync-path 플래그가 필요한 이유에 대해서는 상당히 혼란 스럽습니다.
치다:
$ rsync -avze 'ssh -p 22' --delete public/ pmatos@domain.com:~/public_html
bash: /usr/local/bin/rsync: No such file or directory
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: remote command not found (code 127) at io.c(601) [sender=3.0.7]
그런 다음 –rsync-path를 추가하려고했습니다.
$ rsync -avze 'ssh -p 22' --rsync-path=/usr/bin/rsync --delete public/ pmatos@domain.com:~/public_html
sending incremental file list
...
따라서 첫 번째 rsync는 / usr / local / bin에서 rsync를 검색했기 때문에 성공하지 못했지만 –rsync-path를 사용하여 rsync의 명확한 경로를 전달하자마자 작동합니다.
왜 이런거야? (이 명령 행은 octopress에서 rake deploy가 발행 한 명령 행입니다)
답변
내 기억은 이제 이것에 대해 매우 희미하지만이 일이 일어난 이유는 어느 시점에서 GNU stow를 rsync에 사용하고 rsync
위치 를 혼란스럽게하는 심볼릭 링크를 생성했기 때문 입니다. 이것은 많은 머리카락을 깎은 후에 분류되었습니다. 나는 이제 머리카락이 훨씬 가벼워 지지만 다른 한편으로는 효과가있다 rsync
. 당신이 나에게 요청하면 그것은 승리해야합니다.