Author pitrou
Recipients, giampaolo.rodola, greg.hellings, gregory.p.smith, pitrou, r.david.murray
Date 2009-12-28.22:11:03
SpamBayes Score 1.61384e-06
Marked as misclassified No
Message-id <1262038312.3366.11.camel@localhost>
In-reply-to <>
> For my own case, I have a machine with 50 IP addresses set and I need to 
> run a script to grab data that will randomly select one of those IP 
> addresses to use for its outgoing connection.  That's something which 
> needs to be selected at the socket level, as best I understand the issue, 
> not on the routing end.

Why do you need to select manually between those 50 IP addresses?
Load-balancing? Fooling the remote server so that you don't get
blacklisted for opening too many connections?

The problem I see with adding this to httplib is that it's not
HTTP-specific. Other modules (smtplib etc.) might want to benefit,
depending on the use case.

By the way, what I mean by routing is your OS' internal routing table
for outbound packets. For example under Linux:

# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
X.Y.223.0   U     0      0        0 eth1
X.Y.222.0   U     0      0        0 eth0         X.Y.222.254         UG    100    0        0 eth0

The interface for each outbound route is part of the routing table.
Date User Action Args
2009-12-28 22:11:05pitrousetrecipients: + pitrou, gregory.p.smith, giampaolo.rodola,, r.david.murray, greg.hellings
2009-12-28 22:11:04pitroulinkissue3972 messages
2009-12-28 22:11:03pitroucreate