Date: | Wed, 29 May 2002 16:20:24 -0600 (MDT) |
From: | Rob Brown <rob [...] roobik.com> |
To: | via RT <bug-Net-Ping [...] rt.cpan.org> |
Subject: | Re: Can you do a ping 194.2.0.20 -I ppp0 with Net::Ping ? (fwd) |
Resending Bounced Message
Show quoted text
---------- Forwarded message ----------
Date: Sun, 17 Feb 2002 18:55:09 -0700 (MST)
From: Rob Brown <rob@roobik.com>
To: Olivier MARY <o.mary@auranext.com>
Cc: colinm@cpan.org, bbb@cpan.org, perl5-porters@perl.org
Subject: Re: Can you do a ping 194.2.0.20 -I ppp0 with Net::Ping ?
On Fri, 15 Feb 2002, Olivier MARY wrote:
> I have 2 network interfaces on my linux gateway:
> ppp0 (internet)
> eth1 (lan)
>
> When I have a pb on my internet access:
> route del 0.0.0.0/0
> route add -net 0.0.0.0/0 gw 192.168.1.253
>
> So all my traffic is redirected to another
> gateway in my LAN (I have 2 internet access)
>
> But I still want to check is the line comes back with:
> ping 194.2.0.20 -I ppp0
> (force a ping on ppp0 even if default route is through eth1)
>
> I want to implement that with Net::Ping
> but the bind method only change the source ip
> but still send through eth1
>
> Any ideas ???
>
> Olivier
Olivier:
I am not familiar enough with how ping (ping.c?)
implements the "-I ppp0" feature, much less how
to code it in perl. I thought the bind() feature
would automagically help the kernel decide which
interface to stick it on, but I guess that does
not work either. Sorry, but I have no ideas.
Maybe the perl porters know someone smart enough
to understand this network issue enough to port
that C code feature from ping.c to perl?
-- Rob