亚马逊 Ec2 原型设计

发布于 2024-11-30 01:26:37 字数 167 浏览 1 评论 0原文

人们(和初创公司)实际上如何在亚马逊上进行原型设计/部署并保持成本合理?上个月,我们正在尝试一些特定的应用程序并运行自己的 hadoop 集群,并设法花费了近 1.5k 来进行测试?当然 - 他们有微型实例,但是如果您的应用程序非常密集,实际上需要更大的实例来进行测试怎么办?所以我想要一些关于人们如何去做这件事的意见?

How do people (and start up companies) actually go about prototyping/deploying things on amazon and keep costs reasonable? Last month we were experimenting with some specific applications and running own hadoop cluster and managed to spend almost 1.5k just for tests ? Sure - they have micro instances, but what if you application is so intensive it actually requires a larger instance to even test? So I'd like some input as to how people go about doing this?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

笛声青案梦长安 2024-12-07 01:26:37

几个关键问题:

  1. 考虑用于某些目的的本地测试平台和考虑给定的测试是否确实需要 EC2。如果真的很难找到 2-4 台机器作为 Hadoop 的测试平台,那么就会出现另一个问题。无论您要运行什么,请先思考 Hadoop 将如何发挥作用,然后开始尝试。随着时间的推移,您还会想要更改网格、升级软件、修补其他想法等。当您使用 EC2 时,您已经平滑了一些粗糙的边缘。
  2. 在掌握窍门时,不要使用比您需要的更大容量的机器。如果您在此阶段没有推送大量数据或计算周期,则不必担心集群计算节点、大量 RAM 实例等。只需专注于正确设置即可。
  3. 当您准备好重新定位到功能更强大的机器时,请尝试几种不同的机器设置。也许集群计算实例会带来回报,也许您不需要那种吞吐量:在您知道瓶颈之前,不要超支。
  4. 确保在测试阶段经常使用竞价实例。您通常需要支付按需价格的 50% 左右。
  5. 如果您想要为按需实例付费,请根据需要启动和停止 Hadoop 实例的单独实例 - 除非您需要一个全部基于集群计算实例的大型集群。
  6. 准备好您的 AMI 以尽快启动(1 分钟内),如果没有必要,切勿让任何内容运行过夜或超过周末。

在系统设置并运行之前,您基本上需要支付学费来学习如何根据您的需求定制一切。只需支付“学费”来学习每一课(配置、瓶颈、扩展等),而不是尝试一次接受所有内容。当你将其视为一系列需要学习的课程时,花钱就不那么痛苦了,但只要你知道要测试和学习什么,你也会更明智地花钱。

最后,将 1500 美元与这种学习经历的劳动力成本进行比较——从长远来看,这可能不是什么大问题。一旦你知道某件事将是一个合理的计算工作块,它经过精心设计,并且会很快完成(尽管在许多机器上),那么花钱买它就不那么痛苦了。现在,你很难理解你所学到的东西,因为它还没有利于你的组织的目标。

Several key issues:

  1. Consider a local testbed for some purposes & consider if a given test really needs EC2. If it's really so hard to wrangle 2-4 machines to use as a testbed for Hadoop, there's a different problem. Get your head around whatever you're going to run, how Hadoop will play a role, and kick the tires on that. In time, you will also want to change your grid, upgrade software, tinker with other ideas, etc. When you go to EC2, you'll have smoothed some rough edges already.
  2. Don't use a larger capacity machine than you need while getting the hang of things. If you're not pushing lots of data or compute cycles through at this stage, don't bother with cluster compute nodes, massive RAM instances, etc. Just focus on getting things set up correctly.
  3. When you are ready to retarget to more powerful machines, try a few different machine setups. Maybe the cluster compute instances will pay off, maybe you don't need that kind of throughput: until you know your bottlenecks, don't overspend.
  4. Be sure to use spot instances frequently during the testing phase. You will typically pay about 50% of the on-demand price.
  5. If you get to a point where you want to pay for on-demand instances, have a separate instance start and stop Hadoop instances as needed - unless you need a big cluster all on cluster compute instances.
  6. Prepare your AMIs to get launched as quickly as possible (under 1 minute) and never leave anything running overnight or over a weekend if it isn't necessary.

Until you get the system set up and running, you're basically paying tuition to learn how to get everything tailored to your needs. Just pay the "tuition" to learn each lesson (configurations, bottlenecks, scaling up, etc.), rather than try to take on everything at once. When you approach it as a series of lessons to be learned, it is less painful to spend the money, but as long as you know what you're about to test and learn, you will also spend money more judiciously.

Finally, compare the $1500 to the labor costs of this learning experience - it probably isn't a big deal in the long run. Once you know that something is going to be a reasonable block of computational effort, it's well engineered, and will finish quickly (albeit on many machines), it isn't so painful to spend money on it. Right now, it's hard to appreciate what you're learning because it doesn't yet benefit your org's goals.

So要识趣 2024-12-07 01:26:37

在使用 Amazon Cloud 进行概念验证时解决成本问题。

我使用 Amazon AWS API 创建了一个轻量级 Java 应用程序,当我想对其运行测试时,它会创建亚马逊云实例。一旦测试完成或启动失败,应用程序将通过发送诊断邮件立即终止实例。

因此,没有亚马逊实例能够保持理想的运行或状态。如果您手动或通过单独的程序创建/终止,则可能会发生这种情况。

To address cost issue while doing proof-of-concept of using Amazon Cloud.

I created a light-weight Java Application using Amazon AWS API, which creates the amazon cloud instances when I want to run a test on them. Once the test is finished or failed-to-start the application terminates the instances immediately by sending out diagnostic mail.

So, no amazon instance kept running or sitting ideal. Which can happen if you create/terminate manually or through a separate program.

原谅我要高飞 2024-12-07 01:26:37

考虑使用现货实例。如果你出价过高,你几乎可以肯定它不会被终止。从长远来看,它们的价格与预留实例的级别相同,但您无需预先支付。我相信您还可以将测试安排在非高峰时段,以达到更好的价格,或者如果现货实例价格超过按需实例,则切换到按需实例 - Hadoop 应该可以很好地处理它。查看这篇关于竞价实例的文章。它还引用了另外两篇分析现货实例潜力的文章。

Consider using spot instances. If you overbid, you can be almost sure it won't be terminated. In longer run they have price on a level of reserved instances, but you don't need to pay upfront. I believe you could also schedule the tests for non-peak hours, reaching even better prices, or switch to on-demand if spot instance price exceeds on-demand one - Hadoop should handle it nicely. Check this article about spot instances. It has also references to two other articles that analyze the potential of spot instances.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文