1

Topic: [perl] how to download very much a file> =15G

On the server 15  a frame, but lwp  c out of memory!
Rocking chair such

use LWP:: UserAgent;
use LWP:: Protocol:: https;
use File::Download;
$url=q {https://feeds.itunes.apple.com/feeds/epf/v3/full/current/};
$ua = LWP:: UserAgent-> new;
$ua-> show_progress (true);
$req = HTTP:: Request-> new (GET => $url);
$req-> authorization_basic (",");
@str = split/\n/, $ ua-> request ($req)-> as_string;
$i=0;
foreach $l (@str) {
$l = ~ m/href = "(. + tbz)"/g;
$fnm = $1;
$i ++;
unless ($fnm eq ") {
$dw=HTTP:: Request-> new (GET => "$url$fnm");
$dw-> authorization_basic (",");
open (out, "> $fnm");
binmode out;
print out $ua-> request ($dw)-> content;
close (out);
}
}

2

Re: [perl] how to download very much a file> =15G

On me so for downloading to make, for example, the system call wget and not to be soared.

3

Re: [perl] how to download very much a file> =15G

vkle wrote:

On me so for downloading to make, for example, the system call wget and not to be soared.

It is the correct approach, but not sports.

4

Re: [perl] how to download very much a file> =15G

Jebrail if only not to consider all-round in personal offset, very much even the sports approach. I do not see sense to force to run on skis of the weight-lifter if there is in a command well able it to do the skier.
In the pearl-barley code literally one line is a business simple. And downloading, including repetition of connection and  a file in case of a channel breakaway and as, if needed, and  on a case of analysis of flights easier to guarantee with specially trained utility.