I appreciate the information. I'll try it.
But, I still cannot figure out the semantic of bind() system call.
As all of you know, the prototype of bind() goes like this,
int bind(int sockfd, const struct sockaddr *myaddr, socklen_t addrlen);
I think the second parameter will bind a specific local IP address to the socket
unless it has INADDR_ANY.
Why doesn't it work and why does it depend on the entry order in the routing table?
I think I can make a more dynamic load balancing policy if bind() works as it
literally means.
-----Original Message-----
From: Guus Sliepen [SMTP:[EMAIL PROTECTED]]
Sent: Thursday, August 12, 1999 11:31 PM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: RE: Load Balancing over 2 ethernet cards
SungHawk Kim wrote:
> Thank you for the answer. but, I guess it's not my case. What I want
> to do is balance the load of outgoing packets over more than one
> ethernet cards evenly. to do this, I get a UDP socket and bind it with
> eth0, and I get another UDP socket and bind it with eth1. I think
> bind() system call decides which interface outgoing packets are sent
> through. but, to my suprise, outgoing packets are sent through just
> one interface card which is the former entry in rouging table. I think
> it's a kind of mistake of Linux network implementation.
I have made a patch that does what you think I guess. You can make a
multipath route, which normally just distributes the tcp/udp CONNECTIONS
equally, to distribute every PACKET equally. Please try it out:
ftp://sliepen.warande/net/pub/eql/
Alternatively, you can combine two interfaces into one using the eql
scheduler, for which you don't need a patch, but isn't as flexible.
-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to [EMAIL PROTECTED]