http://qs321.pair.com?node_id=507948

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

I'm using LWP::UserAgent and HTTP::Request to check out rankings on the "popular" search engines ... as you know, the most "popular" uses many data centers around the world, and your queries get routed to the one closest to you geographically.

Now whilst I can retrive the pages fine and parse out the results, is there any way to retrieve the actual remote IP that these HTTP::Requests are being served from.

I mean if I do a GET call to www.booble.com, the page might be sent back from one of N IP numbers ... how do I hack into LWP and ascertain the IP number ? If there any low level way to examine the TCP/IP packets of an actual LWP call as it is being used ?

Obviously I had thought about a ping of something similar immediately before of afterwards, but that doesn't guarantee the exact same IP as the one the LWP was fed from ... they can change in milliseconds, purely depending on their loading conditions.