user3530169
user3530169

Reputation: 381

Download Directory from Google Cloud Compute Engine

I am trying to download a full recursive directory from Google Cloud Platform using the trial edition of the platform. I assumed that the "Download File" option under the SSH dropdown settings would work, but it does not, providing only a "Failed" message on the window.

Upon trying to look up the answer, I found people mentioning downloading files from storage buckets and such - that is not what this is and to my knowledge I don't have access to those on a trial edition of GCP. I have a compute engine running and can SSH into it and I am looking to download a full recursive directory from it.

Thank you for any advice that you can offer me!

Upvotes: 2

Views: 6075

Answers (3)

Sagar Birla
Sagar Birla

Reputation: 1

I would suggest you to use the "download file" button on the top right. the catch is that you can't download folders from that. so, just zip your folder [sudo apt install zip] -> [zip -r <output_zip_file>.zip <folder_to_zip>]. and donload the zip folder using "donload file" buttotn

Upvotes: 0

Jo&#227;o Krapp
Jo&#227;o Krapp

Reputation: 1

You can also download the Google CLI app (https://cloud.google.com/sdk/docs/install) and after logging in use the command:

gcloud compute scp --recurse username@server:/path C:/your_local_path

Upvotes: 0

akenion
akenion

Reputation: 815

If you already have SSH access, you can use the scp command to copy files(assuming it is available on the system to which you want to copy the files).

scp -r username@server:/path/to/your/directory /local/destination

Another option is to use SFTP if scp is not available. Various clients are available for this for various operating systems.

Either of these options will transfer the files over SSH without any additional configuration required on the server(compute instance in your case).

Upvotes: 2

Related Questions