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

Hi, just having a problem when installing Net::Ping Perl module, I have been searching for this error but no luck in Google. Can some one read the next code and tell me if anything is missing? I'm working in a just installed Debian 7.0; Linux Headers, Build essentials and make package are already installed. Thanks a lot!!!

cpan[5]> install Net::Ping Running install for module 'Net::Ping' Running make for S/SM/SMPETERS/Net-Ping-2.41.tar.gz Has already been unwrapped into directory /root/.cpan/build/Net-Ping +-2.41-9HLS7h Has already been made Running make test PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_h +arness(0, 'blib/lib', 'blib/arch')" t/*.t t/100_load.t ......... ok t/110_icmp_inst.t .... ok t/120_udp_inst.t ..... ok t/130_tcp_inst.t ..... ok t/140_stream_inst.t .. ok t/150_syn_inst.t ..... ok t/190_alarm.t ........ ok t/200_ping_tcp.t ..... 1/13 # Failed test 'Can't reach 172.29.249.249' # at t/200_ping_tcp.t line 48. # got: '1' # expected: '0' t/200_ping_tcp.t ..... 7/13 # Looks like you failed 1 test of 13. t/200_ping_tcp.t ..... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/13 subtests t/250_ping_hires.t ... ok t/300_ping_stream.t .. skipped: loopback tcp echo service is off (Cone +xión rehusada) t/400_ping_syn.t ..... 1/17 # Failed test 'supposed to be up: http://172.29.249.249/' # at t/400_ping_syn.t line 85. # got: '0' # expected: '1' # Looks like you failed 1 test of 17. t/400_ping_syn.t ..... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/17 subtests t/410_syn_host.t ..... 1/19 # Failed test 'supposed to be up: http://172.29.249.249/ []' # at t/410_syn_host.t line 88. # got: '0' # expected: '1' # Looks like you failed 1 test of 19. t/410_syn_host.t ..... Dubious, test returned 1 (wstat 256, 0x100) Failed 1/19 subtests t/450_service.t ...... ok t/500_ping_icmp.t .... ok t/510_ping_udp.t ..... ok t/520_icmp_ttl.t ..... ok Test Summary Report ------------------- t/200_ping_tcp.t (Wstat: 256 Tests: 13 Failed: 1) Failed test: 6 Non-zero exit status: 1 t/400_ping_syn.t (Wstat: 256 Tests: 17 Failed: 1) Failed test: 17 Non-zero exit status: 1 t/410_syn_host.t (Wstat: 256 Tests: 19 Failed: 1) Failed test: 13 Non-zero exit status: 1 Files=16, Tests=112, 14 wallclock secs ( 0.16 usr 0.06 sys + 1.35 cu +sr 0.33 csys = 1.90 CPU) Result: FAIL Failed 3/16 test programs. 3/112 subtests failed. make: *** [test_dynamic] Error 255 SMPETERS/Net-Ping-2.41.tar.gz /usr/bin/make test -- NOT OK //hint// to see the cpan-testers results for installing this module, t +ry: reports SMPETERS/Net-Ping-2.41.tar.gz Running make install make test had returned bad status, won't install without force Failed during this command: SMPETERS/Net-Ping-2.41.tar.gz : make_test NO cpan[6]>

Replies are listed 'Best First'.
Re: Problem Installing Net::Ping
by Anonymous Monk on Aug 07, 2013 at 09:20 UTC
Re: Problem Installing Net::Ping
by karlgoethebier (Abbot) on Aug 07, 2013 at 13:25 UTC

    Just a hint...

    From 200_ping_tcp.t in the package:

    # Hopefully this is never a routeable host is($p->ping("172.29.249.249"), 0, "Can't reach 172.29.249.249"

    You get:

    t/200_ping_tcp.t ..... 1/13 # Failed test 'Can't reach 172.29.249.249' # at t/200_ping_tcp.t line 48. # got: '1' # expected: '0'

    From the Test::More manpage:

    # Is the ultimate answer 42? is( ultimate_answer(), 42, "Meaning of Life" );

    From the Net::Ping manpage:

    $p->ping($host [, $timeout]); Ping the remote host and wait for a response....the success flag will +be 1 if the host is reachable and 0 if it is not...

    Force install and regards, Karl

    «The Crux of the Biscuit is the Apostrophe»

Re: Problem Installing Net::Ping
by vinoth.ree (Monsignor) on Aug 07, 2013 at 09:22 UTC
Re: Problem Installing Net::Ping
by 5mi11er (Deacon) on Aug 07, 2013 at 19:16 UTC
    Yes, force the install.

    The test is "failing" because you happen to have something alive on your internal network at address 172.29.249.249, which the author of the module was hoping was an address unlikely to be used out in the wild. In your case that didn't work out so well; therefore, since that's the only thing failing, you're safe to force the install.

    -Scott