VMware Ubuntu与windows 宿主机与虚拟机文件传输 (命令行) 【一只公羊】

5,138 阅读1分钟

从Windows主机向Ubuntu发送/获取文件

1. 获取Ubuntu的IP地址

ifconfig

2. Windows获取文件

scp carlos@192.168.245.129:/home/carlos/ubuntu_file.txt ./

3. Windows发出文件

scp ./windows_file.txt carlos@192.168.245.129:/home/carlos/

从Ubuntu主机向Windows发送/获取文件

1. 获取Windows的IP地址

ipconfig

注意: 在Windows上是ipconfig,而在Ubuntu是ifconfig.

2. Ubuntu获取文件

scp 123456@192.168.0.102:D:/scp_test/Windows_file1.txt ./

3. Ubuntu发出文件

scp /home/carlos/ubuntu_file1.txt 123456@192.168.0.102:D:/scp_test/