1
  • I have created a AWS server instance.
  • I have a pem file which i use to get access to the remote AWS through my local system terminal
  • I have saved the file pem file in /home/downloads/xxx.pem

  • I want to copy an image from location /home/images/image.jpg to the server at /images
  • I did some research on the google and found out it is done through SCP
  • I could not achieve the goal

How to use scp to copy an image from source( MY-Computer-Local ) to AWS(server)?

Thanks

ישו אוהב אותך
  • 28,609
  • 11
  • 78
  • 96
  • 1
    possible duplicate of [Uploading file to AWS from local machine](http://stackoverflow.com/questions/18169455/uploading-file-to-aws-from-local-machine) – Mike Aug 12 '13 at 13:11
  • What user do you ssh to on the EC2 instance (e.g., "ec2-user")? What user owns the /images directory on the EC2 instance? Is /images the directory on the EC2 instance or is it the path of the URL on a web server? Is your local computer Windows? Linux? Mac? – Eric Hammond Aug 13 '13 at 06:37
  • Are you familiar with man pages? They provide extensive documentation on commands. You can read all about how to use scp by executing `man scp`. – William Pursell Dec 17 '16 at 16:14
  • Does this answer your question? [Using scp to copy a file to Amazon EC2 instance?](https://stackoverflow.com/questions/11388014/using-scp-to-copy-a-file-to-amazon-ec2-instance) – Samson Mar 13 '22 at 07:01

2 Answers2

1
scp -i secrate_key.pem file_name.ext ec2-user@publicDNS:~/.
Shravan40
  • 8,922
  • 6
  • 28
  • 48
-2

'You should keep that folder in your local D drive, and open that folder from AWS instance and drag & drop that folder'

Suresh U
  • 463
  • 3
  • 14
  • @ Suresh U ....... I kept the folder in drive-D ...... But how to open that folder from AWS instance ...... Which order or which options do i need to click ... can u share this information with me –  Aug 12 '13 at 12:41
  • 'From AWS Instance Click on Start button,->select computer there it is showing local and aws instances from there you have to select your local D drive.' – Suresh U Aug 13 '13 at 06:28
  • Suresh ..... in mu amazon ec2 dashboard ...... i right click on my instace .... and in Instance Lifecycle inselected `start` as u guided me .... but i cannot find any computer there ..... please can u point out for a documentaion or link that explains your steps .... it will be helpful to me ! –  Aug 13 '13 at 11:59