Perlbal on EC2
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > Perlbal > Perlbal on EC2




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Perlbal on EC2  
David Cancel


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
08-07-07 06:11 PM

I'm trying to use Perlbal to load balance a cluster of web servers hosted on
Amazon's EC2. EC2 does not provide access to IP Addreses, only hostnames.

Is there a way to pool servers using hostnames instead of IP addresses?

e.g.

This:
POOL my_web ADD
ec2-xx-xx-xx-xxx.z-1.compute-1.amazonaws.com:80<http://ec2-xx-xx-xx-xxx.z-1.comput<....amazonaws.com/>
vs:
POOL my_web ADD 10.1.1.111:80 <http://10.1.1.111/>

Thanks,
David






[ Post a follow-up to this message ]



    Re: Perlbal on EC2  
David Snopek


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
08-07-07 06:11 PM

EC2 *does* provide access to IP addresses.  Here's how I do it:

(1) On startup, the machine figures out its IP by grabbing the document at:

http://169.254.169.254/1.0/meta-data/local-ipv4

(2) Then it calls a service on the proxy host, passing the IP address
found in the step above, and it appends it to the nodefile used by
Perlbal.

If you don't want to do this from the machine itself (although I
highly suggest it because then you can make sure that your webserver
is up and running before it makes the call to add itself to the pool)
then just resolve the hostname via DNS.

On 8/7/07, David Cancel <dcancel@gmail.com> wrote:
> I'm trying to use Perlbal to load balance a cluster of web servers hosted 
on
> Amazon's EC2. EC2 does not provide access to IP Addreses, only hostnames.
>
> Is there a way to pool servers using hostnames instead of IP addresses?
>
> e.g.
>
> This:
> POOL my_web ADD
> ec2-xx-xx-xx-xxx.z-1.compute-1.amazonaws.com:80
> vs:
>  POOL my_web ADD 10.1.1.111:80
>
> Thanks,
> David






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 10:37 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register