• Post Reply Bookmark Topic Watch Topic
  • New Topic

split client on many server...

 
mark smith
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi

i have client who connect to a gateway... the gateway have some information about server and port

my gateway have a vector who store ipserver adress and another for the port

if i have 2 server, i would like the client 1 go to server 1, client 2 go to server 2, client 3 go to server 1......

i search a the most simple way to do it...
 
Stan James
(instanceof Sidekick)
Ranch Hand
Posts: 8791
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Clients could easily pick a server at random if they knew the address and port for all available servers. Give them a retry ability: if they try one and it's down, switch to the other. This would be dead simple and pretty effective.

There are hardware boxes available that do this kind of load balancing; you give clients the address of the load balancer and it forwards work to one of "n" servers. We use one called ArrowPoint currently in round-robin mode.

If you don't have the budget for a hardware solution, you might be able to build one on a low-powered PC that could keep up with traffic. You could possibly even put it as a separate process on one of your server boxes, but that would lead to some imbalance.

Any load balancer may become a Single Point Of Failure, which is probably just what you're trying to avoid.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!