如何更新多个EC2实例是负载平衡? [英] How do I update multiple EC2 instances that are load-balanced?

查看:111
本文介绍了如何更新多个EC2实例是负载平衡?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以,我一直在玩弄亚马逊云(AWS),我试图找出如何让文件在所有服务器上的,如果他们进行负载平衡。

So, I have been playing around with Amazon Cloud (AWS) and I am trying to figure out how to get files on to all server's if they are load balanced.

起初,我以为我可以配合3种不同情况下的负载平衡器,然后让每个实例使用相同的音量。这样,所有我所要做的就是更新一个卷与最近建立网站的每个实例然后将访问。不过,我已阅读,你不能跨实例共享卷。

At first I thought I could tie 3 different instances to a load-balancer and then have each instance utilize the same volume. That way all I would have to do is update the one volume with the recent build of the site and each instance would then access that. However, I have read that you can't share volumes across instances.

那么该如何解决?我本来有三个实例都具有相同的数据,而我可以更新来呢?然后将阐述将复制横跨其他三个数据

So what is the solution? Would I have to have the three instances all with the same data, and a forth that I could update? Then the forth would replicate the data across the other three.

只是想弄清楚如何更新更新生产文件,并有被处理的负载拉在最近code基地的所有服务器。

Just trying to figure out how to update update the production files, and have all servers that are handling the load to pull in the most recent code base.

推荐答案

是所有的服务器都需要有相同的内容。你可以通过创建NFS共享或相似,并在每个服务器上的相同点安装它做到这一点。但显然是一个不错的解决方法是创建一个EBS卷的快照,然后将它们安装在每个实例。请参阅<一href="http://linuxforlovers.word$p$pss.com/2009/04/11/sharing-amazon-elastic-block-store-among-multiple-instances/" rel="nofollow">http://linuxforlovers.word$p$pss.com/2009/04/11/sharing-amazon-elastic-block-store-among-multiple-instances/了解更多详情。要提交更改时,都承诺仅EBS卷。

Yes all servers need to have identical content. You could do this by creating an NFS share or similar, and mounting it at the same point on each server. But apparently a decent workaround is to create snapshots of an EBS volume and then mount them on each instance. See http://linuxforlovers.wordpress.com/2009/04/11/sharing-amazon-elastic-block-store-among-multiple-instances/ for more details. Every time you want to commit your changes, you commit to the EBS volume only.

这篇关于如何更新多个EC2实例是负载平衡?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆