Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

CPAN times out on "01mailrc.txt.gz", every time, Mac OS X Darwin

by brycen (Monk)
on Dec 12, 2005 at 23:15 UTC ( #516175=perlquestion: print w/replies, xml ) Need Help??

brycen has asked for the wisdom of the Perl Monks concerning the following question:

Here's an odd one: Every time I install something with CPAN, I have to wait about four minutes for it to time out getting "01mailrc.txt.gz". Everything else about CPAN is fine:
# cpan cpan shell -- CPAN exploration and modules installation (v1.76) ReadLine support enabled cpan> install Date::Format CPAN: Storable loaded ok Going to read /Users/brian/.cpan/Metadata Database was generated on Thu, 08 Dec 2005 23:00:12 GMT CPAN: LWP::UserAgent loaded ok Fetching with LWP: LWP failed with code[400] message[FTP return code 000] Fetching with Net::FTP: Couldn't fetch 01mailrc.txt.gz from Issuing "/usr/bin/ftp -n" ...
I've tried deleting ~/root/.cpan, but the problem comes back. Directly ftp'ing is fine, no hang, no timeout, no pause, no delay, no trouble getting "01mailrc.txt.gz":
# ftp Trying Connected to ...

Replies are listed 'Best First'.
Re: CPAN times out on "01mailrc.txt.gz", every time, Mac OS X Darwin
by thor (Priest) on Dec 12, 2005 at 23:52 UTC
    I used to hate waiting for the file to download, too. Then, I included minicpan in a weekly cron job and pointed cpan (actually cpanp) to use that as its repository. I couldn't recommend this more. It's a pretty elegant solution, IMO.


    The only easy day was yesterday

Re: CPAN times out on "01mailrc.txt.gz", every time, Mac OS X Darwin (passive)
by tye (Sage) on Dec 13, 2005 at 02:25 UTC

    Pick an HTTP mirror or turn on 'passive' FTP (by setting the FTP_PASSIVE environment variables to 1, for example).

    Yes, I agree that it is quite unfortunately that comes "out of the box" in a configuration that makes it time out mysterious for several minutes and then do nothing useful (if run on a machine that is behind a firewall, which should be all machines but is surely a very large fraction of machines).

    - tye        

      Thanks, that was the pointer I needed to find, and this worked:
      env FTP_PASSIVE=1 cpan -i Net::FTP
      I never would have guessed this myself, since the actual module installation was fine, only the mailrc failed to load (and cpan never really seemed to care). How do I set the mirror? I don't find a in my ~/.cpan.
        This worked for me as well. I was getting the same on the 01mailrc.txt.gz hanging everytime i tried to install modules. I couldn't figure out why. Again, thanks. BTW i my OS is FreeBSD 5.4

        "Es gibt mehr zu Leben als Bücher, kennen Sie. Aber nicht viel mehr " -(Der Smiths)
        The file you're looking for is called ~/.cpan/CPAN/
        @/=map{[/./g]}qw/.h_nJ Xapou cets krht ele_ r_ra/; map{y/X_/\n /;print}map{pop@$_}@/for@/
Re: CPAN times out on "01mailrc.txt.gz", every time, Mac OS X Darwin
by stvn (Monsignor) on Dec 13, 2005 at 01:28 UTC

    I had similar issues at one point, and I turned off the Mac OS X built-in firewall and they went away. However, I don't think that is a long term solution, but it might be a start in figuring out what is going wrong.


Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://516175]
Approved by astaines
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (2)
As of 2020-08-11 00:17 GMT
Find Nodes?
    Voting Booth?
    Which rocket would you take to Mars?

    Results (58 votes). Check out past polls.