Technoracle
    Facebook Twitter Instagram
    • Sitemap
    • Privacy Policy
    • Disclaimer
    • Term of Services
    Facebook Twitter Instagram Pinterest Vimeo
    TechnoracleTechnoracle
    • Tutorials
      • Amazon Cloud
      • Google Cloud
    • How To
    • Blog
    • About
    Subscribe
    Technoracle
    Home»How To»How to Upload File to AWS EC2 Instance
    How To

    How to Upload File to AWS EC2 Instance

    Rajesh ShivamBy Rajesh ShivamMarch 25, 2022Updated:March 25, 2022No Comments2 Mins Read
    Share Facebook Twitter Pinterest LinkedIn Tumblr Reddit Telegram Email
    Upload File to AWS EC2 Instance
    Share
    Facebook Twitter LinkedIn Pinterest Email
    Upload File to AWS EC2 Instance

    We can upload files or directories to AWS EC2 using different ways. In this article, I am going to explain step by step how to upload a file to AWS EC2 instance.

    Page Contents

    • Upload Files and Directories to AWS EC2 Instance
        • Method 1: Files upload using FTP Client
        • Method 2: Files upload to EC2 instance from windows.
        • Methode 3: Files upload using command prompt
          • For Ubuntu and Mac Users:
      • Conclusion

    Upload Files and Directories to AWS EC2 Instance

    Method 1: Files upload using FTP Client

    You can upload your files to the EC2 instance using FTP clients, such as FileZilla, WinSCP, etc. Your EC2 instance should have an FTP setup for this method. If you want to set up FTP on your EC2 instance check here.

    Method 2: Files upload to EC2 instance from windows.

    If you are using windows system, you can just download and install WinSCP to upload or download website files to AWS EC2 instance. To connect using WinSCP, you will need EC2 instance IP, server ssh key, user name.

    Methode 3: Files upload using command prompt

    If you are using Ubuntu, Mac or any linux based system, upload files using command prompt to AWS.

    For Ubuntu and Mac Users:
    • If you are using Ubuntu or Mac system, you can directly upload files from the local machine to the AWS EC2 instance using SCP command from the terminal.
    $ scp -i [login key file path] [Source Files] [username]@[Server IP]:[Destination]
    
    Example:
    
    $ scp -i serverlogin.pem file.zip ub[email protected]:~
    
    SCP: Secure Copy Protocol.
    -i: It is use to specify the new SSH Keypair.
    :~ ( colon tild): Tild(~) means the home directory in linux.
    • To download the file from the AWS EC2 instance to the local machine, use the following command.
    $ scp -i [login key file path] [username]@[Server IP]:/[Source Files Server] [Destination]
    
    $ scp -i serverlogin.pem [email protected]:/home/ubuntu/file.zip .
    
    . (dot): Here "."(dot) means the location from where you are running the command t download the (file.zip)
    
    

    Conclusion

    In this article, you have learned how to upload file to AWS EC2 instance. If you have any doubt, you can comment below. I will try to answer your questions.

    ubuntu tips
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email
    Previous ArticleHow to Install Let’s Encrypt SSL on Ubuntu 20.04
    Next Article How to Check CPU Usage in Linux Easily
    Rajesh Shivam

    Hello, everyone, I am Rajesh Shivam, I am a full-time freelancer with more than seven years plus experience in different freelancing platforms, in this blog, I am going to provide complete freelancing tips and tricks.

    Related Posts

    How To

    How to Install Microsoft Teams on Ubuntu 22.04 Easily

    February 22, 2023
    Read More
    How To

    What is Elastic IP and Its Pricing in AWS

    February 22, 2023
    Read More
    How To

    How to Convert PEM to PPK file [Step by Step Guide]

    February 22, 2023
    Read More
    Add A Comment

    Leave A Reply Cancel Reply

    Facebook Twitter Instagram Pinterest
    © 2023 Technoracle

    Type above and press Enter to search. Press Esc to cancel.

    Go to mobile version