How To Do safer downloads (Updated 2023-11-24)

Hello,

  • OpenMandriva Lx version:
    ALL

  • Desktop environment (KDE, LXQT…):
    ALL

  • Description of the issue (screenshots if relevant):
    Downloads get interrupted sometimes. Especially frustrating for larger downloads like ISO files.

  • Relevant informations (hardware involved, software version, logs or output…):

In Konsole first cd to the directory where you want to download an ISO file then choose one of the following commands:

$ aria2c -c -m 0 https://example.com/file.iso

$ wget -d -c --tries=0 --read-timeout=30 https://example.com/file.iso

$ curl -L -C - https://example.com/file.iso

With these commands if your .iso or other download is interrupted by something in the internet it will automatically resume. Also if the download is interrupted by a power outage one can resume the download exactly where it left off. The aria2c command is preferred for .iso downloads.

This post expands on the curl command and exlains the options in the command string.

Normally you would download as user not as root.

$ curl -L -C - https://example.com/file.iso

Here is what the options mean :

Option What It Does
-L Some URLs redirect to some other sites. This option tells cURL to obtain the file from that redirected location.
-C – This option is for telling cURL to resume download and the dash ("-") that follows it is to automatically detect the size of the file to continue downloading.
1 Like

This post expands on the aria2c command and exlains the options in the command string.

Normally you would download as user not as root.

$ aria2c -c -m 0 https://example.com/file.iso

Here is the explanation of each options used in the above command :

Option What It Does
-c Tells aria2c to resume downloads
-m 0 This option will make aria2c retry downloads for unlimited times. Some servers tend to break connection after some time. But, this option makes aria2c to auto retry when such things happen.
1 Like

This post expands on the wget command and exlains the options in the command string.

Normally you would download as user not as root.

$ wget -d -c --tries=0 --read-timeout=30 https://example.com/file.iso

And here is the explanation of the options used :

Option What It Does
-d Tells wGet to Download the File
-c Tells wGet to resume download
–tries=0 Tells wGet to retry connections unlimitedly when it is interrupted.
–read-timeout=30 If no response is received in 30 seconds, exit and establish a new connection

Have fun downloading

2 Likes

Thread updated and simplified 2023-11-24.