Best Way to Download Large Files From Google Drive

Alright, I feel like I take been creating a lot of detailed in-depth guides lately.

I am non complaining of course but today I feel like making a quick and dirty one.

Well, not dingy, just you know what I mean.

Today let's learn how y'all can download a large file from your google drive faster using Windows PowerShell.

Unremarkably when y'all try to download a large file from google drive directly you will receive a message like this.

Sometime google drive likewise splits your large file into multiple parts, zips them and and then permit's you lot download them.

Information technology's not very user-friendly now is it.

This hasn't happened to me but sometimes yous cannot recover the big files properly when they are split into tiny chunks and may pose some errors.

So, today let me show you a neat play a joke on that you can use to download large files from google drive directly using the Windows PowerShell, when a file is shared privately and requires you lot to authenticate.

Footstep 1: Fetching Your File ID

So the starting time thing that you need to exercise here is fetch the ID of the file y'all demand to download.

It's pretty simple and straight forward.

Follow these steps,

  1. Open a notepad.

You will be needing it to copy and paste IDs, authorization code and a PowerShell Script.

  • Open your browser and go to your google drive, open up login with the account that has the file yous wish to download.
  • Locate the file that you lot wish to download and select it.
  • Right click the file and click on "become shareable link"(refer the paradigm beneath).
  • You don't need to re-create the entire link here; you only need the file ID that we will be using afterwards.

The link volition await similar this: https://bulldoze.google.com/file/d/XXXXX/view?usp=sharing

In this link, you merely need to pay attention to the alphanumeric file ID, displayed by XXXXX hither.

  • Re-create the file ID in the notepad.

Step ii: Getting an OAuth Code

In this nosotros will be needing an OAuth 2.0 authorization API cardinal to let PowerShell to gain access to the user protected data (the file that we want to download) on our google drive.

In order to achieve this.

  1. Visit OAuth 2.0 Playground past clicking here.
  2. On the developer's webpage, in the "Select & authorize APIs" click on the "Bulldoze API v3" option, and select the: https://www.googleapis.com/auth/drive.readonly pick from the bachelor options.

Refer this image.

  • One time selected click Authorize APIs button on the bottom right corner of the tab.
  • After y'all click on the Authorize APIs button you volition be transferred to the google account login screen.
  • Select the same google account in which you have your file stored.
  • Allow Google OAuth two.0 to access your drive if asked.
  • When you get redirected dorsum to the OAuth 2.0 playground screen click on the "Substitution Authorization Code for Tokens" push as shown.
  • Copy the newly generated Access Token and salvage it on your notepad. You lot will exist needing this in the next footstep.

Step three: Downloading The File Using A Command Line Script

Okay it's finally time to download your file.

This adjacent footstep is pretty simple to be honest.

  • If you lot are on Linux, open the terminal and use the following command:
curl -H "Authorization: Bearer YYYYY" https://www.googleapis.com/bulldoze/v3/files/XXXXX?alt=media -o ZZZZZ
  • And if you lot are on windows, follow these steps.
  • Click on the First button
  • Search "Powershell" on Windows search, right click and select "Run As Ambassador".
  • Click Yes on the next window and you will see the Windows PowerShell Console pop up.
  • On your notepad first copy this command,
Invoke-RestMethod -Uri https://www.googleapis.com/drive/v3/files/XXXXX?alt=media -Method Get -Headers @{"Authorisation"="Bearer YYYYY"} -OutFile ZZZZZ
  • Now replace the "XXXXX" in the commands with the file ID that we copied in the first pace and replace "YYYYY" with the admission token that we copied in the 2d step.
  • "ZZZZZ" is whatever name of your choice y'all would want to requite to the downloaded file. So, replace information technology with the proper name of your choice, for case, "downloadedfile.mp4", if yous are downloading an mp4 file.

Well, that's it.

Hit enter and see your file getting downloaded.

The completed downloads will get stored in "C:\Windows\System32" or the System32 folder.

Please think this or you will continue fiddling in your downloads folder and will not exist able to locate your file.

I am leaving a screenshot below equally proof.

Try out this method and share with me your results.

Hit me back if in the comments if you have anymore queries or if you face any problem.

I will see ya in the adjacent one.

Tada!

You lot take Successfully Subscribed!

DOWNLOAD HERE

Posted by: mccarthyrequed.blogspot.com

0 Komentar

Post a Comment




banner