Where does a file downloaded with CURL go on the file system?

2

Ive downloaded a file from this site with the following curl command:

https://www.modern.ie/en-us/virtualization-tools#downloads

# Copy/paste the command below into your terminal to begin downloading all the required files
# Don't have cURL or want to learn more, visit http://curl.haxx.se/

curl -O -L "https://www.modern.ie/vmdownload?platform=mac&virtPlatform=virtualbox&browserOS=IE10-Win8.1&parts=5&filename=VMBuild_20131127/VirtualBox/IE10_Win8/Mac/IE10.Win8.For.MacVirtualBox.part{1.sfx,2.rar,3.rar,4.rar,5.rar}"

Where does the file actually go? I cant seem to see it anywhere on my machine.

Evanss

Posted 2014-10-28T18:28:14.700

Reputation: 1 008

1look for a file named vmdownload in the directory where you ran that statement. – Darth Android – 2014-10-28T18:30:10.253

@Darth Android, I believe that vmdownload is a cgi script with the ? providing options into it. – headkase – 2014-10-28T18:31:12.990

1@Bill Correct! Which is what curl will use as the name when saving the result of requesting that script. On the HTTP level, the file being requested is https://www.modern.id/vmdownload, so vmdownload is the name that curl wants to use. The rest is just parameters curl is sending to the server, so it doesn't factor into the naming of the file. – Darth Android – 2014-10-28T18:33:38.960

@Darth Android, at the end of the parameters there are 5 parts specified however. How would those be handled with their partial names? curl can't be so brain-dead as to call them the name of the script instead of their proper names? – headkase – 2014-10-28T18:35:58.850

1@Bill How is curl supposed to know that those parameters are the filename? You could use the parameter called filename for anything - maybe the name of the file to upload; What if the website uses name or fname instead? There's no standards for any of this, so there's no way for curl to know what the filename might be, other than the script name. curl doesn't even know that it's calling a script. – Darth Android – 2014-10-28T18:39:12.217

Answers

4

You will type or paste that command into a terminal. In the folder the terminal is in when the command is executed the files will be placed in.

headkase

Posted 2014-10-28T18:28:14.700

Reputation: 1 690

If I close the terminal without running the command, is the file still somewhere on my system? – Evanss – 2014-10-28T18:33:28.163

1@jdln If you do not run the command, then the file is no where on your system. – Darth Android – 2014-10-28T18:35:43.343

But the file is downloaded. Is it only in RAM? – Evanss – 2014-10-28T18:38:54.480

@jdln The file is not downloaded unless you run the command. The command downloads the file; if you do not run the command, then it cannot download the file. – Darth Android – 2014-10-28T18:41:09.857