CPAN Networking Issue

Hi all,
I have a wierd problem, I have a Solaris 11.3 server which is connected to the internet and if I run

perl -MCPAN -e 'install XML::Simple'

it goes off, downloads it's list of sites and installs the module and it's dependencies great.

Then I have a zone that uses the same internet connection, same dns etc. and if I run the above I get this:

Would you like me to automatically choose the best CPAN mirror
sites for you? (This means connecting to the Internet and could
take a couple minutes) [yes]

Trying to fetch a mirror list from the Internet
  LWP not available
  LWP not available
Fetching with Net::FTP:
ftp://ftp.perl.org/pub/CPAN/MIRRORED.BY
  Could not connect to host 'ftp.perl.org' with Net::FTP
Fetching with Net::FTP
ftp://ftp.perl.org/pub/CPAN/MIRRORED.BY.gz
  Could not connect to host 'ftp.perl.org' with Net::FTP
Warning: no success downloading '/root/.cpan/sources/MIRRORED.BY.tmp30246'. Giving up on it.
No external ftp command available

  LWP not available
Warning: no success downloading '/root/.cpan/sources/MIRRORED.BY.tmp30246'. Giving up on it.
  LWP not available
Fetching with Net::FTP:
ftp://ftp.perl.org/pub/CPAN/MIRRORED.BY
  Could not connect to host 'ftp.perl.org' with Net::FTP
Fetching with Net::FTP
ftp://ftp.perl.org/pub/CPAN/MIRRORED.BY.gz
  Could not connect to host 'ftp.perl.org' with Net::FTP
Warning: no success downloading '/root/.cpan/sources/MIRRORED.BY.tmp30246'. Giving up on it.
No external ftp command available

Your urllist is empty! The urllist can be edited. E.g. with 'o conf urllist
push ftp://myurl/'

Could not fetch MIRRORED.BY
We failed to get a copy of the mirror list from the Internet.
You will need to provide CPAN mirror URLs yourself.


Now you can enter your own CPAN URLs by hand. A local CPAN mirror can be
listed using a 'file:' URL like 'file:///path/to/cpan/'

CPAN.pm needs at least one URL where it can fetch CPAN files from.

Please enter your CPAN site: []

no idea why it is not working, any help would be appreciated

Thanks

Martin

@callmebob

Your error message indicated that you may have a networking issue.

Did you confirm your host (giving you the issue) can reach the CPAN URL requested?

Hi Neo,
Any ideas how I can just try and get to it, it does name resolution but did try a normal ftp but don't think this worked. It is a zone, so not done a huge amount of networking with zones.

Any help greatly appreciated

Thanks

Martin

This is your error, @callmebob

You need to resolve this; isn't that right?

Resolved it thanks NEO. I hadn't done a svcadm refresh name-service/switch so /etc/nsswitch.conf was not populated. I could resolve IP's but not names and it was doing DNS resolution.

Not liking this confiure DNS through the SMF on Solaris 11

2 Likes

Great to hear you are on to the next step.

Thank you for posting back and letting us know, @callmebob

No problem, thank you for your help