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

Hello Monks,

I try to install Perl module using CPAN, I get the following error

cpan> install DBI LWP failed with code[500] message[LWP::Protocol::MyFTP: connect: timeo +ut

Can you tell me how this error is happening.

Thanks in Advance!!!

Replies are listed 'Best First'.
Re: Cpan Install error
by Corion (Patriarch) on Jul 10, 2006 at 08:44 UTC

    That error means that cpan could not connect to the outside world by using the FTP prototcol, and the error it got was a timeout.

    The first thing to check is if the machine you're trying this on can reach the internet at all, and by which method. A common way is the HTTP protocol.

    The next step is to reconfigure cpan to use a HTTP url instead of ftp, either by completely reconfiguring (Type o conf init in cpan) or by reconfiguring selected items (Remove all ftp items, and set up HTTP, if HTTP works for you)

    Traditionally, the CPAN shell will try several options though, so something seems weird with your setup, as it only seems to try ftp.

Re: Cpan Install error
by Herkum (Parson) on Jul 10, 2006 at 11:38 UTC

    Another issue could that the site(s) that you are trying to reach is not up. If you are using an internal repository, for example, make sure that the site is up and available.

    In cpan, if you issue the command o conf you should see an option that says urllist. These are the repositories that cpan will attempt to download from. If you can get to these sites manually, try using your browser, then it is a problem with the way cpan is configured.

    One more potential problem is that if there is a proxy between you and the repository, you will need to change your cpan configuration to tell there is a proxy.