dim*_*ech 0 linux ssh terminal tar
我正在尝试通过 tar 从目录中传输所有文件,如下所示:
tar cz * | ssh -p 57310 root@example.com tar xzv -C /home/site/www
Run Code Online (Sandbox Code Playgroud)
返回的错误是
stdin: is not a tty
tar: includes: file changed as we read it
tar: /home/site/www: Cannot chdir: No such file or directory
tar: Error is not recoverable: exiting now
Run Code Online (Sandbox Code Playgroud)
我正在使用 ssh 密钥连接到 example.com。
这对我有用:
tar cz * | ssh -p XXX account@host "cat | tar xvz -C /home/site/www"
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
737 次 |
最近记录: |