Linux scp命令用于Linux之间复制文件和目录
scp [可选参数] file_source file_target
1)本地到远程
A)文件
scp local_file remote_username@remote_host:remote_file
scp local_fle remote_host:remote_file
[root@localhost ~]# scp ./sh/corn.sh weizong@192.168.0.251:/home/weizong/
weizong@192.168.0.251's password:
corn.sh 100% 480 0.5KB/s 00:00
B)目录
scp -rv local_dir remote_username@remote_host:remote_dir
scp -rv local_dir remote_host:remote_dir
scp -rv /var/develop/ weizong@192.168.0.251:/home/weizong/
Executing: program /usr/bin/ss