【linux命令】bash: rsync: command not found 报错原因以及解决办法
内容摘要
[[email protected] ~]$/usr/bin/rsync -avz -P -e ssh test.txt 1.2.3.4:/home/wwwroot/test
bash: rsync: command not found
rsync: connection unexpectedly clos
bash: rsync: command not found
rsync: connection unexpectedly clos
文章正文
[[email protected] ~]$/usr/bin/rsync -avz -P -e ssh test.txt 1.2.3.4:/home/wwwroot/test bash: rsync: command not found rsync: connection unexpectedly closed (0 bytes received so far) [sender] rsync error: remote command not found (code 127) at io.c(600) [sender=3.0.6]
报错原因:
线上的新服务器没有安装rsync导致。
解决办法:
新服务器(目标服务器)执行命令 yum install rsync -y 问题解决。
代码注释
[!--zhushi--]