nc命令传输文件

除了scp命令外,nc命令也可以远程传输文件,用法如下:

  1. 在接收端执行 nc -l port > file 准备接收; 在发送端执行 nc ip port < file

  2. 在发送端执行 nc -l port < file 准备发送; 在接收端执行 nc ip port > file

从TCE下载文件,接收端不变,发送端变成 nc -v -q 0 接收端ip 接收端port < file

Written on May 20, 2019