transferring_files_to_ec2_instance
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| transferring_files_to_ec2_instance [2017/07/26 06:51] – [How to transfer files] walkeradmin | transferring_files_to_ec2_instance [2024/10/02 17:09] (current) – removed walkeradmin | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ====== Transferring files to EC2 Instance ====== | ||
| - | <color darkorange> | ||
| - | \\ | ||
| - | \\ | ||
| - | |||
| - | ---- | ||
| - | ===== Introduction ===== | ||
| - | \\ | ||
| - | There are a few ways to transfer files to and from an Amazon EC2 instance. If you are using a desktop environment, | ||
| - | \\ | ||
| - | \\ | ||
| - | However, from the command line it can be a little trickier. In this example we will look at transferring files to and from an Amazon EC2 instance from the Linux command line using SCP. | ||
| - | \\ | ||
| - | \\ | ||
| - | |||
| - | ---- | ||
| - | ==== How to transfer files ==== | ||
| - | \\ | ||
| - | To be able to connect to your Amazon EC2 instance you will require your EC2 Instance key pair. Copy your key file to a directory on your source Linux server. | ||
| - | \\ | ||
| - | \\ | ||
| - | {{ : | ||
| - | \\ | ||
| - | \\ | ||
| - | Before we can use the key we have to change its permissions, | ||
| - | \\ | ||
| - | \\ | ||
| - | Use chmod to change your key.pem file permissions. | ||
| - | \\ | ||
| - | \\ | ||
| - | {{ : | ||
| - | \\ | ||
| - | chmod 0400 keyfile.pem | ||
| - | \\ | ||
| - | The keyfile.pem should now have the following permissions: | ||
| - | \\ | ||
| - | \\ | ||
| - | We are now ready to transfer files to and from our EC2 Instance. To connect to the EC2 instance you can use either the currently assigned IP Address, your Elastic IP Address if you have one, or the Public DNS (IPv4). | ||
| - | \\ | ||
| - | \\ | ||
| - | My test AWS EC2 Intance has the following details. | ||
| - | \\ | ||
| - | \\ | ||
| - | **Elastic IP Address: | ||
| - | **Public DNS (IPv4): | ||
transferring_files_to_ec2_instance.1501051916.txt.gz · Last modified: (external edit)
