1

I am trying to send file from windows local system to QEMU raspberry pi emulator.But every time I am getting "access denied".I have downloded pscp.exe. I have tried the following commands:

pscp.exe -scp myfile.txt pi@192.168.1.3:/home/pi

pscp.exe -scp myfile.txt pi@192.168.1.3:~/home/pi

pscp.exe -scp myfile.txt pi@192.168.1.3:~/Desktop

pscp.exe -scp myfile.txt pi@192.168.1.3:~

Every time it's giving Access Denied.Please tell me where I am going wrong.

Sneha Bansal
  • 941
  • 1
  • 13
  • 38
  • Close to something you want to achieve. http://stackoverflow.com/questions/23106012/how-to-access-raspberry-pi-qemu-vm-via-network – dhruvvyas90 Feb 16 '17 at 16:36

1 Answers1

2

I am probably late, but anyway this may help someone.

The syntax of pscp is

pscp [options] source [user@]host:target

Target is the destination file and you are inputting a folder. Also, you are using a file syntax /home/pi and not a folder syntax /home/pi/ (note the / slash at the end). So you are asking pscp to overwrite your entire user folder and put the source file instead. Needless to say this could have result in a massive catastrophe, deleting your entire home folder.

Your command should be:

pspc myfile.txt pi@192.168.1.3:/home/pi/myfile.txt

You can even hard code your password so that the transfer occurs without prompting.

pspc -pw yourpassword myfile.txt pi@192.168.1.3:/home/pi/myfile.txt

Susensio
  • 820
  • 10
  • 19