简体   繁体   中英

perl modules failing to install

I was writing a perl script and realised I needed to get some additional modules, so I used the command:

$ cpan List::MoreUtils                                                                                                             

and got back:

Loading internal logger. Log::Log4perl recommended for better logging
Reading '/c/users/ahawryluk/.cpan/Metadata'
  Database was generated on Mon, 04 Jul 2022 15:56:10 GMT
Running install for module 'List::MoreUtils'
Fetching with LWP:
http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
LWP failed with code[503] message[Service Unavailable]

Trying with
    /usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440"
to get
    http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
--2022-07-04 14:02:20--  http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
Resolving www.cpan.org (www.cpan.org)... 146.75.33.55, 2a04:4e42:79::311
Connecting to www.cpan.org (www.cpan.org)|146.75.33.55|:80... connected.
HTTP request sent, awaiting response... 503 Service Unavailable
2022-07-04 14:02:20 ERROR 503: Service Unavailable.


    Function system("/usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440" "http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz" ")
    returned status 8 (wstat 2048), left
/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440 with size 0
    Warning: no success downloading '/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440'. Giving up on it.

Trying with
    /usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440"
to get
    http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
--2022-07-04 14:02:21--  http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
Resolving www.cpan.org (www.cpan.org)... 146.75.33.55, 2a04:4e42:79::311
Connecting to www.cpan.org (www.cpan.org)|146.75.33.55|:80... connected.
HTTP request sent, awaiting response... 503 Service Unavailable
2022-07-04 14:02:21 ERROR 503: Service Unavailable.


    Function system("/usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440" "http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz" ")
    returned status 8 (wstat 2048), left
/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440 with size 0
    Warning: no success downloading '/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440'. Giving up on it.
No external ftp command available

Fetching with LWP:
http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
LWP failed with code[503] message[Service Unavailable]

Trying with
    /usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440"
to get
    http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
--2022-07-04 14:02:22--  http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
Resolving www.cpan.org (www.cpan.org)... 146.75.33.55, 2a04:4e42:79::311
Connecting to www.cpan.org (www.cpan.org)|146.75.33.55|:80... connected.
HTTP request sent, awaiting response... 503 Service Unavailable
2022-07-04 14:02:22 ERROR 503: Service Unavailable.


    Function system("/usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440" "http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz" ")
    returned status 8 (wstat 2048), left
/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440 with size 0
    Warning: no success downloading '/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440'. Giving up on it.

Trying with
    /usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440"
to get
    http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
--2022-07-04 14:02:23--  http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
Resolving www.cpan.org (www.cpan.org)... 146.75.33.55, 2a04:4e42:79::311
Connecting to www.cpan.org (www.cpan.org)|146.75.33.55|:80... connected.
HTTP request sent, awaiting response... 503 Service Unavailable
2022-07-04 14:02:23 ERROR 503: Service Unavailable.


    Function system("/usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440" "http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz" ")
    returned status 8 (wstat 2048), left
/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440 with size 0
    Warning: no success downloading '/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440'. Giving up on it.
No external ftp command available

Please check, if the URLs I found in your configuration file
(http://www.cpan.org/) are valid. The urllist can be edited. E.g. with 'o
conf urllist push ftp://myurl/'

Could not fetch authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz

It's not like I've not downloaded other modules before. I'm not sure what's going on. Says "Service Unavailable 503". Yet, I can go to the URLs stated in the log above directly with my browser and download the file.

Trying to use the wget command directly results in the same issue.

$ /usr/bin/wget -O "/c/users/ahawryluk/.cpan/sources/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz.tmp24440" "http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz"
--2022-07-04 14:22:41--  http://www.cpan.org/authors/id/R/RE/REHSACK/List-MoreUtils-0.430.tar.gz
Resolving www.cpan.org (www.cpan.org)... 146.75.33.55, 2a04:4e42:78::311
Connecting to www.cpan.org (www.cpan.org)|146.75.33.55|:80... connected.
HTTP request sent, awaiting response... 503 Service Unavailable
2022-07-04 14:22:41 ERROR 503: Service Unavailable.

I'm using MSYS2. What could be going on here? Is there something wrong with the cpan site?

Edit

Things I've tried are:

  1. Adding mirrors as shown here .
  2. Attempted to do a full system upgrade as shown here .
  3. Tried to use a Ubuntu WSL to do the same thing.
  4. Tried to use my phone's data network to confirm that it wasn't caused by a firewall issue.

No joy. 😔

Can someone at least comment to say if they are having the same issues by doing a test module install?

Grrr. When I had attached to my phone, it's WiFi was connected to my local network and so had the same issue. Once I put it to only the cell network, it worked fine. Seems that this is caused by some change to our corporate firewall. 😠

Still doesn't explain why I could get to the file directly through the browser but couldn't using wget though.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM