Monday, May 27, 2019

Copy from windows to linux

With SCP:

Can be installed from Git (set of linux tools comes with it) or download directly.

scp /cygdrive/d/test.txt <linux ip>:/etc/var/test/test.txt

But, it will prompt for password after running the command.

For automation, we can skip the password prompt using ssh keys.

Other option is with PSCP:

We can pass the password as parameter with the command itself.
So used for automation without any SSH keys.

pscp -pw password D:\test.txt user@192.168.33.10:/etc/var/test/test.txt
PSCP comes with putty installation.

Reference:
Link1 
Link 2
Link 3

No comments:

Post a Comment