Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Help with CPAN failing

by astaines (Curate)
on Apr 20, 2003 at 21:37 UTC ( [id://251885]=perlquestion: print w/replies, xml ) Need Help??

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

Hi,

I've been banging my head against this problem for two days, with no joy, perhaps someone else can help?
I have just installed RedHat 8 on my laptop, which was running Redhat 7.2 very nicely, and CPAN is broken. I did a complete re-install, not an upgrade.

All the components work individually, for example I can get files with ftp and libwww (lwpget) from the CPAN mirrors, but when running the CPAN shell, I can't retrieve any files. Pulling the MIRRORED.BY file over manually allowed me to complete the initial CPAN setup successfully, but I still can't retrieve any files. The LWP access mode just fails with no error message, and the ftp access mode fails at the RETR command, with error 400 and response code 425 from the server

FTP Error- 425
425 Can't build data connection: Connection refused.

This error message is coming from all of the mirror sites in MyConfig.pm. The CPAN shell works fine on the same machine running Windows 2000. All the other internet services seem to be running normally. I use this machine from home over a modem line, so there shouldn't be any odd firewall stuff going on.

Any thoughts?? (Help!!)

--
Anthony Staines

Replies are listed 'Best First'.
Re: Help with CPAN failing
by TVSET (Chaplain) on Apr 20, 2003 at 23:08 UTC
    Looks like a firewall problem. Check your firewall settings on the newly installed RedHat box with:

    [root@host root]# iptatbles -n -L

    If you don't see something like:

    Chain INPUT (policy ACCEPT) target prot opt source destination Chain FORWARD (policy ACCEPT) target prot opt source destination Chain OUTPUT (policy ACCEPT) target prot opt source destination

    then you machine is running a firewall, which might block passive FTP connections. These will require some tuning. For a quick check, you can disable firewall and try to use CPAN shell for some installation. To temporarily switch off the firewall run:

    [root@host root]# service iptables stop

    If you machine is on the protected network and you don't need firewall at all, then you can switch also disable iptables service at boottime by running:

    [root@host root]# chkconfig --level 0123456 iptables off

    HTH.
    perl -e 'print "-- \n Leonid Mamtchenkov\n"'

      Thanks very much - it worked like a charm. I still don't understand why I could use ftp etc, and CPAN couldn't, bt I don't really care either. Thank you very much!

      --
      Anthony Staines

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://251885]
Approved by lacertus
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others exploiting the Monastery: (3)
As of 2024-03-19 05:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found