News for hackers. Stuff that matters.
Re:A million-dollar engineering problem by Negitivefrags on Thursday March 16, 2017 @02:19PM (#13887468)
A friend of mine was annoyed that a small service he liked was shutting down.

He contacted the developer who said that they were shutting it down because the server costs were higher than the money they were making.

They were spending 5k a month on AWS crap and claimed it was impossible to get any lower.

He helped them consolidate everything onto a single rented dedicated server costing 400 a month. Now the service is profitable, and will stay up.

It runs way faster on the single server. It also has required less maintenance after the move too.

This kind of shit is everywhere. At this point simply not using AWS is a competitive advantage.

Re:A million-dollar engineering problem by QuinnyPig on Thursday March 16, 2017 @03:30PM (#13888335)
> At this point simply not using AWS is a competitive advantage.

Respectfully, I'm going to disagree. I consult full time on AWS cost optimization / reduction / understanding.

If you blindly run things on AWS without an understanding of the costing model, that'll work for a time. As you scale, you start to realize "oh my god it runs on money."

There are myriad ways around that, but a blanket "never use AWS" isn't going to address it constructively.

Re:A million-dollar engineering problem by rdtsc on Friday March 17, 2017 @12:29AM (#13891494)
> I consult full time on AWS cost optimization / reduction / understanding.

Curious, have you ever consulted a client not to use AWS? As in "your cost optimization is going to be not using AWS and using $x instead"?

Re:A million-dollar engineering problem by QuinnyPig on Saturday March 18, 2017 @02:07PM (#13902631)
Absolutely. Great example: container workloads without high data volumes. Slap those into GCP if you can-- or arbitrage between different cloud providers / regions / on-prem if you have them.

That said, clients who come to me already have a significant investment with AWS. Getting rid of that is a high bar in terms of engineering effort.

That said, I've no financial incentive to recommend one provider over another. My clients pay me, the vendors do not.

Re:A million-dollar engineering problem by rdtsc on Saturday March 18, 2017 @11:13PM (#13904945)
Makes total sense. Thank you for responding!

We've pushed clients to competitors' products a few times, I was young and thought that was silly. However those clients spread the word about us and we didn't even have much of a marketing department, it was all word of mouth. Gaining their trust was gold and a really good long term investment.

Re:A million-dollar engineering problem by mrlatinos on Friday March 17, 2017 @10:48AM (#13894340)
Curious about this as well. Otherwise, it's like a car salesman saying you shouldn't buy a bike, rather, understand mpg before buying a car.
Re:A million-dollar engineering problem by QuinnyPig on Saturday March 18, 2017 @02:09PM (#13902640)
Sure-- but I'm usually not retained until the environment is built out. The client's starting point is relevant to what comes next.
Re:A million-dollar engineering problem by tyingq on Thursday March 16, 2017 @05:37PM (#13889429)
I would guess the network egress costs, specifically, might justify a blanket statement like...

"If you have content where you can't put a cache in front of it, and it drives significant bandwidth use, then AWS is not a great option"

Re:A million-dollar engineering problem by stemuk on Thursday March 16, 2017 @05:54PM (#13889557)
This. I really feel like egress traffic costs is the most overlooked issue with popular cloud services like AWS or Google Cloud. Charging 9 or 12 cents for a mere GB of regular traffic is just insane, keeping in mind that even most CDNs are cheaper.

Data driven applications on AWS are already expensive because of the high traffic costs, but storing/serving media on S3 single handedly lets your bill explode. For everyone who feels like the statements above are exaggerations, just check out their actual prices (https://aws.amazon.com/ec2/pricing/on-demand/) in comparison with a regular CDN (https://www.stackpath.com/pricing/).

Re:A million-dollar engineering problem by tyingq on Thursday March 16, 2017 @09:07PM (#13890527)
A quick and dirty comparison would be 3TB out in a month. That's what's typically included at popular VPS services for a decent sized VPS that's $20/month. On an EC2 instance, just the bandwidth for that month would be $269.91.
Re:A million-dollar engineering problem by kafkaesq on Thursday March 16, 2017 @05:30PM (#13889388)
A blanket "never use AWS" isn't going to address it constructively.

But that's not what the commenter was saying, of course.

More like (paraphrasing) "before you go full-hog on AWS, do some simple math first." Which an amazingly high percentage of people neglect to do, these days.

Re:A million-dollar engineering problem by nulagrithom on Friday March 17, 2017 @11:00AM (#13894433)
> before you go full-hog on AWS, do some simple math first

I had a coworker who was turned off of AWS by clicking the "Dedicated IP" checkbox when deploying a CloudFlare distribution with SSL.

One month and $600[0] later he swears up and down that AWS is the devil.

You can spend an amazing amount of money on AWS by accident and/or without need. Hourly pricing is a huge footgun. Best to run everything through the "Simple" Monthly Calculator: https://calculator.s3.amazonaws.com/index.html

0: https://aws.amazon.com/cloudfront/pricing/

Re:A million-dollar engineering problem by hinkley on Friday March 17, 2017 @03:32AM (#13892234)
Weeks of work can save hours of meetings.
Re:A million-dollar engineering problem by thecrazyone on Friday March 17, 2017 @03:34PM (#13897236)
interesting thing to say, but did you plan for it to mean something in this context? :)
Re:A million-dollar engineering problem by kafkaesq on Friday March 17, 2017 @05:40PM (#13898219)
Nothing special - just the whole "Yeah, saw your email† ... look, I'm so busy, did you get the site up and running again? I'll get back to you on this after my vacation" management style which seems to drive a great many "decisions" that are made in this realm. And on which AWS, implicitly, banks a great deal of its business model on.

† About the monthly you-know-what bill now well into 5 figures, and climbing.

Re:A million-dollar engineering problem by EnFinlay on Thursday March 16, 2017 @06:24PM (#13889738)
> At this point simply not using AWS is a competitive advantage.
Re:A million-dollar engineering problem by logfromblammo on Thursday March 16, 2017 @10:12PM (#13890822)
I read this as suggesting that a simple arbitrary rule to not use AWS is likely to save both money and also the time that would otherwise be spent tuning your use of AWS to cost less money.

Your time is valuable too. It could be spent developing something novel instead of messing around with server configuration.

Re:A million-dollar engineering problem by qeternity on Thursday March 16, 2017 @03:48PM (#13888510)
I am curious your thoughts on the following. It seems like there is a trough of benefit to AWS. In the mid-size world, especially where computing needs are relatively stable/predictable, you are much better leasing dedicated servers from the usual suspects. Below that size, the linear scaling allows small scrappy startups to really scale/burst with their needs. And at large scale, but below Google/Facebook et al scale, it's cheaper than building your own datacenter yourself. At least this has been my casual observations. And fwiw, the startup I have just launched fits into this trough perfectly. So hopefully I am not just biased. I love the cloud for the spot market. But not for our base load. Spot is the nat gas of the server world, and OVH is the coal.
Re:A million-dollar engineering problem by QuinnyPig on Thursday March 16, 2017 @03:53PM (#13888567)
I agree with a lot of what you're saying-- but that trough is a lot wider than most people think.

At the single instance very small scale, it simply doesn't matter all that much. "Our business failed because our infrastructure bill was $400 instead of $150 every month" isn't that common of a story.

Base load can be effectively migrated to AWS, depending upon how it's built / structured. It's hard to lose money on infrastructure by converting worker servers to spot instances or lambda functions, as a for-instance-- but it's VERY easy to lose months of engineering effort in doing so.

Remember as well: done right you're not just buying services from the cloud, but flexibility as well. Resizing on the fly, bursting, duplicating your infrastructure for a test-- these things add value.

Re:A million-dollar engineering problem by metafunctor on Friday March 17, 2017 @05:56AM (#13892775)
Resizing, bursting, and duplicating on the fly aren't exclusive to AWS, though.

A lot of teams rent space from places like OVH or Hetzner because the raw power is so much cheaper, and they already have the talent and tools to scale and manage a computing fleet (people like to think it's harder than it actually is).

Re:A million-dollar engineering problem by rhizome on Thursday March 16, 2017 @04:17PM (#13888779)
Are bursting and resizing an issue in the trough, though? GP's premise is that these companies have platform and load stability. There can be marginal gains in having a dynamic architecture, sure, but when it also costs "months of engineering," I don't see where the savings would be compelling, or even guaranteed.
Re:A million-dollar engineering problem by QuinnyPig on Thursday March 16, 2017 @04:56PM (#13889095)
There are companies "in the trough" who are contently spending tens of millions a year on AWS. It's hard to give generic advice for all situations-- as with so much else, context matters heavily.

Those marginal gains could potentially pay for a dozen engineers...

Re:A million-dollar engineering problem by rhizome on Thursday March 16, 2017 @05:33PM (#13889399)
My point was based on how dynamic the architectures are (or aren't) of those in the trough, not their level of spending.
Re:A million-dollar engineering problem by QuinnyPig on Thursday March 16, 2017 @05:48PM (#13889517)
Ah, my apologies!

It depends. I have a toy service that exists entirely as an autoscaling group. That's pretty dynamic!

Counterpoint: Mainframes.

Re:A million-dollar engineering problem by rhizome on Thursday March 16, 2017 @06:30PM (#13889765)
A toy service is not what I'm thinking of as being in "the trough." The trough is where scaling and bursting aren't generally necessary.
Re:A million-dollar engineering problem by alexkon on Thursday March 16, 2017 @05:09PM (#13889207)
How do you approach a horrifying AWS bill? Can you recommend any reading? I’m going to need to optimize a tiny fleet on GCE pretty soon.
Re:A million-dollar engineering problem by QuinnyPig on Thursday March 16, 2017 @05:58PM (#13889585)
It gets into the specifics of "what makes it horrifying" pretty quickly. It usually boils down to "nobody's responsible for cleaning things up," a misunderstanding of the billing model, and by the time anyone cares to fix it the billing report is multiple gigabytes.

Step 1 is always "figure out what you've got, and why it is this way."

Re:A million-dollar engineering problem by brazzledazzle on Thursday March 16, 2017 @10:34PM (#13890910)
So if the best way to avoid the mess is accountability for keeping things clean, how do you do that from the start? Would something as simple as tagging resources to specific teams/departments be a good place to start? I'm helping with setting up a completely new account/environment and I know once the buzzword fever passes and the annual costs are reviewed there will be frantic requests to cut down the bill. Getting ahead of that inevitability with a plan and some preparation will save us a headache.
Re:A million-dollar engineering problem by QuinnyPig on Thursday March 16, 2017 @11:52PM (#13891318)
Propagate tags to secondary resources, like EBS volumes. Separate out production from your dev environment-- preferably with a second AWS account with consolidated billing. Buy in to something like Terraform or CloudFormation for building the non-instance parts of your stack.

As you grow, start adding project tags to things. Automatically tag resources with the IAM user who creates them. Have an "untagged resources report" that goes out on a schedule.

Build with an eye towards "when someone freaks out in a year about the bill, what questions will they have, and how can I best position Future Me to answer them?"

Re:A million-dollar engineering problem by fpp on Friday March 17, 2017 @11:44AM (#13894822)
Running / monthly cloud cost and comparison to other options (e.g. run on a rented dedicated machine / co-location) should already been looked at when you do even the most basic business plan.

Generally most of the time the best approach is to create solutions that can scale out independent from the HW / infrastructure they run on. With frameworks like K8s / Docker / e.a. this is now relatively easy.

With that for example you can start of with a few small cloud machines / docker containers. When you get continuous load - migrate some of them to 1-2 dedicated machines. Same with peak load - just spin up more images.

All that of course depends on what kind of application you are providing. If you are running a data intensive apps you might start directly with a dedicated machine.

Easy in, expensive out. One cost with cloud services many forget is the cost to get out again. Have a look at the AWS / Azure price-lists.

Re:A million-dollar engineering problem by voidlogic on Thursday March 16, 2017 @03:17PM (#13888179)
I used to do data-center and virtualization consulting- we always designed our enterprise client's systems to handle the baseload in-house and burst to public cloud. Not rock science. We even automatically live-migrated load from and shutdown onsite hypervisors at night when the system had surplus capacity...

I think the real issue is that people assume all workloads are public cloud workloads. The bigger and less dynamic your workload the less that is true.

Re:A million-dollar engineering problem by klodolph on Thursday March 16, 2017 @04:16PM (#13888767)
This is a great approach. A company I worked at was running mostly on dedicated hardware, and due to the pain of moving jobs around and getting new hardware, we focused hard on optimizing our code to run within our existing capacity whenever we ran into problems. After a couple years of customer growth, I'm sure we would have been running on at least 10x as many machines if we had never done that. We then set up cloud spot instances for when we just needed extra short-term capacity.
Re:A million-dollar engineering problem by user5994461 on Thursday March 16, 2017 @04:25PM (#13888845)
> I'm sure we would have been running on at least 10x as many machines

Seeing the opposite trend.

Because your own machines are so expensive and annoying to manage, you only get 500GB memory 40 cores servers. You don't optimize and you run stuff randomly on whatever seem available.

Whereas in the cloud, you put VMs per role, with appropriate sizing. And when someone asks for 5 machines with 16 cores, you can be like, WTF are you running with all that power???

Re:A million-dollar engineering problem by klodolph on Thursday March 16, 2017 @06:48PM (#13889865)
I would believe that, but we were hitting the limits of our huge servers. There's only so much QPS you can throw at a single box. These servers were also "pets" as opposed to "cattle", and a big part of the prep for cloud was treating them as cattle.
Re:A million-dollar engineering problem by that_colo_guy on Thursday March 16, 2017 @04:41PM (#13888975)
anon account for obvious reasons.

Came here to share my story, which is very close to what you describe.

tl;dr: Moved from AWS to colo in desperate attempt to make balance sheet more attractive. It worked.

Before I took over the engineering bits at this plateau/failing startup, they were all in on AWS. Monthly costs were running at around £3k. Which is not much, but since the revenue was tiny, the costs of hosting was "considerable". After a monumental effort on my part to try to make things more efficient and streamlined, I eventually run out of motivation (but that's another story) so I expressed my wish to leave to the founder and he finally agreed to my years old suggestion of going lean-and-mean and in one last attempt to make the company more attractive to one last investment round (E by then). Make it or break it, as the say goes.

On that same week I came across a HPE "Buy One Get One Free" offer (similar to this one https://www.serversdirect.co.uk/pdf/BOGOF-Gen9-Servers.pdf). Then found guy who was re-selling colo space at a under-used datacentre in London. Since I (sysadmin/DevOps/InfoSec/Backend engineer Jack-of-all-trades master of none) was the person who would end up managing the new metal, I picked a location within an hours drive from home.

And so it happened.

2x 1U HPE proliant servers with decent CPU and 32G of RAM. And 6x Samsung 850 SSDs off Amazon. Total bill for the hardware (BOGOF refund included): £2600 ish.

Post migration, monthly hosting costs: £50 for the colo; £50-ish AWS S3+CloudFront (10M assets would increase the SSD storage costs too much); £40 in taxi fares when I visit the DC once a month for kernel updates.

And just like that, we broke even the very next month after the last "big" AWS bill. Our product wasn't all that exciting, but 2 months later we found a buyer who was happy to snatch this "non loss making" operation.

3 months after the acquisition, they had already migrated the whole thing back to AWS and the HPE proliant servers were gathering dust in their office.

Re:A million-dollar engineering problem by empath75 on Thursday March 16, 2017 @07:41PM (#13890148)
Of course, because how do you scale up when you're building everything yourself? Suddenly you have to hire a whole bunch of hardware guys, storage guys, db guys etc, etc.
Re:A million-dollar engineering problem by brianwawok on Thursday March 16, 2017 @09:09PM (#13890535)
Why do you need a DB guy if you host it on your server or AWSs? You have a DB either way. You can have a guy if you want or not... Physical location means nothing.
Re:A million-dollar engineering problem by daurnimator on Friday March 17, 2017 @12:03AM (#13891372)
DB guy to tune the instance the database runs on + figure out your streaming backups etc. It's not a full time job, but it's a couple of days a week; and completely taken care of if you use RDS
Re:A million-dollar engineering problem by Lazare on Friday March 17, 2017 @08:06AM (#13893307)
I think your estimate is off by a factor of about 40. RDS is great at what it does, but it doesn't do that much. Getting the stuff RDS gives you for "free" might take a a few days to set up, but after that, your automated backups are going to take just as much of your time as the ones RDS gives you, ie, none.

If RDS saves you 30 minutes a week I'd be surprised.

Re:A million-dollar engineering problem by hueving on Friday March 17, 2017 @03:30AM (#13892228)
A couple of days a week? That's ridiculous, once you have established procedures the only thing left is regular OS maintenance tasks which are the same as the rest of your servers.
Re:A million-dollar engineering problem by brianwawok on Friday March 17, 2017 @09:45AM (#13893875)
Indeed. RDS saves like 1 day setup. No ongoing difference.
Re:A million-dollar engineering problem by throwawaysed on Thursday March 16, 2017 @02:38PM (#13887677)
A lot of people are in denial that there isn't using some magic efficiency to cloud services that other datacenters don't have. Primary cost savings on cloud VM's is from overprovisioning. The more abstracted away the service is from the hardware, the more they can overprovision without customers noticing.

The 50%+ profit margins have to be coming from somewhere. AWS is not made of magic, it's made from largely the same PC parts you buy on newegg

Re:A million-dollar engineering problem by illumin8 on Thursday March 16, 2017 @07:21PM (#13890037)
This is just factually incorrect. AWS hard partitions all instance types, except T2 (which are overcommitted, and clearly advertised as such: "burstable").

So, if you provision an x1.32xlarge with 128 vCPU and 1.92TB of RAM, you get a single, dedicated host with that much CPU and memory. Nobody else gets it - it's dedicated to you 100%.

The profit AWS is making is purely due to datacenter efficiency and being able to automate their operations at scale.

Re:A million-dollar engineering problem by hueving on Friday March 17, 2017 @03:29AM (#13892222)
>The profit AWS is making is purely due to datacenter efficiency and being able to automate their operations at scale.

That's what they want you to think, but a lot of it comes in the form of ripping you off for bandwidth to actually get data out of EC2.

Re:A million-dollar engineering problem by dexterdog on Friday March 17, 2017 @10:46AM (#13894330)
I've been with AWS for about 10 years now on a number of projects. Bandwidth pricing has always been my major gripe. Almost everything else I consider fairly priced for what I get and how hands-off I get to be.
Re:A million-dollar engineering problem by patrickg_zill on Thursday March 16, 2017 @08:55PM (#13890478)
The instant you wrote "128vCPU" you undermined your own argument.

What is a vCPU?

Re:A million-dollar engineering problem by brianwawok on Thursday March 16, 2017 @09:06PM (#13890519)
It's early defined in the docs. The machine also has a physical core count that is yours.
Re:A million-dollar engineering problem by patrickg_zill on Thursday March 16, 2017 @10:20PM (#13890852)
There is nothing stopping Amazon from having a machine that is double that config, and renting you half of it, however.

As soon as 32GB DIMMs drop enough in price, I would expect them to do exactly that. You can configure a Dell R930 with e7 Haswell CPUs online, if you want to double-check it. Not sure if the R930 can go to 8 CPUs (which the e7 Haswells CPUs support).

Re:A million-dollar engineering problem by dexterdog on Friday March 17, 2017 @10:45AM (#13894310)
But as soon as they double the size of the machine there is no reason for them to not have an instance type that is the size of the machine minus the host layer.
Re:A million-dollar engineering problem by user5994461 on Thursday March 16, 2017 @02:38PM (#13887683)
> The 50%+ profit margins

Charge more than what it costs you. That's how to make money.

Re:A million-dollar engineering problem by Shivetya on Thursday March 16, 2017 @03:12PM (#13888110)
well to be honest its because it sounds cool, its in the news, and so how can such proposals be wrong. Seriously the number of times I heard "the cloud" bandied about by people who have continuously failed or were "thwarted" by people who knew better is getting silly. I am sure it happens in other places but too many think it makes them look smart to suggest it.

if anything its a diversion from fixing what is broke or even admitting to it within some organizations

Re:A million-dollar engineering problem by whalesalad on Thursday March 16, 2017 @07:03PM (#13889946)
The problem is not AWS. The problem is poorly architected systems and software. We see a similar issue with the "we switched from PHP to Haskell on .NET in Azure and improved performance 3000x" -- the issue wasn't the fault of the language, it was the way it was used.

You put bald tires that are over-inflated on a Porsche and you're gonna have a shitty experience. Sure, bare-metal is gonna have performance benefits over AWS and at times might be cheaper -- but that isn't the only thing an eng organization is looking for.

tl;dr – you can build systems on AWS that perform well and are reasonably priced.

Re:A million-dollar engineering problem by ars on Friday March 17, 2017 @02:43AM (#13892045)
> You put bald tires that are over-inflated on a Porsche and you're gonna have a shitty experience.

This is off topic, but bald tires have better traction than grooved ones in dry conditions. (But the slightest bit of rain and they will not hold.)

Also tire inflation does not have a strong correlation with traction (there is some, but it's not large), so it's not so obvious that over-inflated means a bad experience.

Re:A million-dollar engineering problem by SudhindraBhat on Friday March 17, 2017 @07:25AM (#13893110)
Bald tires also mean that the tire compound has degraded. So it is going to have worse traction. Slick tires on the other hand are new without any grooves.
Re:A million-dollar engineering problem by YZF on Friday March 17, 2017 @12:45AM (#13891566)
If you have a more or less fixed workload then AWS ends up being a lot more expensive. If you have a highly variable workload and you have a bunch of servers sitting idle most of the time then it becomes more competitive. AWS lets a small startup go from one server to 10K servers without breaking sweat, at least in theory, but it's not for everyone. At the same time not everyone wants to build DCs with thousands of servers in different geographies all by their own.

But yeah, AWS generally is expensive, which is part of why it's making so much money.

It definitely makes business sense to try to avoid locking yourself in to AWS but at the same time it's a good place to ramp up or test your business ideas without needing to invest a lot of money in servers, real estate etc.

[You can probably substitute any other cloud provider for AWS here]

Re:A million-dollar engineering problem by phamilton on Friday March 17, 2017 @03:43AM (#13892272)
The variable workload has been a little less important with reserved instances. They used to have a "light/heavy utilization" pricing structure but now it's basically cheaper to reserve the instance than it is to scale it up and down, unless you need the extra capacity less than 60% of the time.
Re:A million-dollar engineering problem by dexterdog on Friday March 17, 2017 @10:35AM (#13894254)
That's going between 1 and 0 servers for an instance. Real scaling needs are met in a setup going from 3-50+ servers throughout the week.
Re:A million-dollar engineering problem by phamilton on Monday March 20, 2017 @10:18PM (#13919333)
I think you misunderstand me. Doing 100 servers for 16 hours and scaling down to 30 servers for 8 hours a day is more expensive than running 100 reserved instances for 24 hours a day. (100 reserved instances == average of 60 on demand instances).
Re:A million-dollar engineering problem by kbenson on Thursday March 16, 2017 @06:55PM (#13889903)
The company I work for is backed by a bunch of data in a MySQL database, scripts to aggregate and process more data into that database, and simple internal webapp to both manage inventory, track tasks and run lots of reporting on the aggregated data.

We made do for quite a while on a single colocated database with 32 GB of RAM and a few fast SSDs (for the time, which was about 6 years ago), and a few multi-TB archival drives, but disk space is a concern since our compressed innodb tables are well over 100GB now. I set up a Google Cloud SQL instance (the largest possible at the time I believe, 104GB RAM, and enough disks to hit peak IOPS) a few months back in preparation of migrating the data store to it, and found it wholly inadequate for our needs prior to even getting it going.

First, the second generation instances don't support being a replication slave to a non Cloud SQL instance, making migration a pain. Second, just running through the replication logs on a client and piping it to a connection to the cloud SQL instance showed that the cloud SQL instance was just barely able to keep up with the insert and update traffic from the replication log, even while handling no other queries. Catching up the the master would take over a week, even though the backup was from less than 48 hours prior.

We signed up for an actual hardware server from Rackspace at about 2/3 the cost, but with 128 GB of RAM (which I can request expanded), and nice hardware RAID 10 of fast SSD drives, and tons of logical CPUs. It's appropriately faster compared to the original database server, to the degree you would expect from from stats quoted. It fits our needs, because really I just don't want to manage the hardware anymore (this the decision not to deploy more hardware in the local datacenter we are colocated at), and that's covered.

On demand spin up/down of resources and per-minute billing is nice, and I've used it to good effect for non-database resources before, so I understand the versatility of it and how it can really enable some new types of usage and am a fan of that aspect, but I just wasn't prepared for how substandard the DB offerings are if you actually have any sort of load. At this point, the only good thing I have to say about the higher end database offerings is that they were quick to destroy so I didn't get billed anymore. :/

Re:A million-dollar engineering problem by illumin8 on Thursday March 16, 2017 @07:24PM (#13890061)
May I make a suggestion: Try Amazon Aurora. You'll get 500,000 read operations per second, and 100,000 writes per second. It supports up to 64TB of total capacity, and 244GB RAM on your primary master. You can also have up to 15 read replicas with a similar footprint. You should seriously try it. It's amazing.
Re:A million-dollar engineering problem by kbenson on Thursday March 16, 2017 @08:46PM (#13890440)
Maybe on the next upgrade iteration. As it is now, the server is performing well, and it can scale to 1.5 TB of RAM, so that aspect has quite a bit of room.
Re:A million-dollar engineering problem by deesix on Thursday March 23, 2017 @01:11PM (#13941737)
Quick question. Which version of MySQL were you running? 5.6 is single thread on the slave and falls behind more easily. 5.7 gives you multiple threads and does a better job of keeping up.

Disclosure: I work on Google Cloud and Cloud SQL

Re:A million-dollar engineering problem by kbenson on Thursday March 23, 2017 @04:16PM (#13943830)
Whichever the highest version offered in the second generation Google Cloud SQL offering as of November/December 2016. If 5.7 was available, I would have chosen that. I don't specifically recall though.
Re:A million-dollar engineering problem by user5994461 on Thursday March 16, 2017 @02:40PM (#13887703)
You shouldn't be on AWS in the first place if everything you do can fit on a single server.

Use the right tool for the job.

Re:A million-dollar engineering problem by GFischer on Thursday March 16, 2017 @03:13PM (#13888121)
I disagree. Depends on the service's business model obviously, but there are services where the convenience will more than offset the extra costs.

Once the company grows big enough, yes, then it might make sense to go off AWS (or not - see: Netflix).

Re:A million-dollar engineering problem by secabeen on Thursday March 16, 2017 @03:40PM (#13888430)
Remember that Netflix runs their core product (content distribution) internally on their own CDN. All of the supporting technologies (billing, content discovery, etc.) is on AWS, but the core product is not.
Re:A million-dollar engineering problem by rbranson on Thursday March 16, 2017 @03:59PM (#13888612)
This was a pretty recent change. Netflix has classically relied on third-party CDN providers. They launched the streaming service in 2007, and it took them 9 years to move 100% of their traffic to their own CDN infrastructure. That said, they still have one of the largest AWS footprints.
Re:A million-dollar engineering problem by user5994461 on Thursday March 16, 2017 @03:48PM (#13888513)
The core products are the shows, not the tech.
Re:A million-dollar engineering problem by omarchowdhury on Thursday March 16, 2017 @04:36PM (#13888935)
Without the tech, no one sees the core products.
Re:A million-dollar engineering problem by user5994461 on Thursday March 16, 2017 @05:04PM (#13889164)
Without the shows, the tech has nothing to show. Who's gonna pay for nothing?
Re:A million-dollar engineering problem by omarchowdhury on Thursday March 16, 2017 @08:00PM (#13890249)
Those with the shows didn't build the tech, but Netflix did.
Re:A million-dollar engineering problem by antons_ghost on Thursday March 16, 2017 @09:14PM (#13890563)
And now Netflix is even building shows.
Re:A million-dollar engineering problem by pm90 on Thursday March 16, 2017 @03:35PM (#13888385)
I've always found it interesting that Netflix has not at least tried to go off AWS; if only because Amazon has a competing service with Amazon video. I'm sure its not an easy problem to solve, but Dropbox has gone off AWS as well; it seems like they would be much better served with their own "Video Cloud" with specialized hardware for streaming/processing videos.
Re:A million-dollar engineering problem by illumin8 on Thursday March 16, 2017 @07:26PM (#13890070)
Netflix realizes that the value presented by AWS for outweighs the costs. If you feel differently, you should probably ask yourself what information you are missing, rather than just dismissing Netflix and their decision. It's clear that Netflix knows more about operating applications with tens of millions of simultaneous global users than most companies...
Re:A million-dollar engineering problem by bcook on Thursday March 16, 2017 @08:30PM (#13890377)
>If you feel differently, you should probably ask yourself what information you are missing

That's something that should be applied almost universally. :)

Re:A million-dollar engineering problem by curun1r on Thursday March 16, 2017 @10:03PM (#13890784)
I don't think Netflix and Amazon really compete yet. Very few people see the two services as either/or. They're more allies against the cable companies at the moment.
Re:A million-dollar engineering problem by pokler on Thursday March 16, 2017 @03:44PM (#13888473)
Netflix doesn't use AWS for streaming video.

https://openconnect.netflix.com/en/

Re:A million-dollar engineering problem by danblick on Thursday March 16, 2017 @04:13PM (#13888740)
You make a good point that Netflix has a pretty sophisticated system for delivering video (not just served from AWS Cloudfront). However IIUC they still use AWS for preparing video files for their CDN.
Re:A million-dollar engineering problem by GFischer on Thursday March 16, 2017 @04:00PM (#13888622)
Dropbox is an example where their core business is very data-intensive and AWS costs can be considerable.

I'm thinking of services, say the automated robo-built sadwiches, or the Easy 401 service, or the luxury shoes startup (all real YC-accepted companies), where the core business proposition isn't necessarily dependent on having a huge infrastructure.

Re:A million-dollar engineering problem by eip on Friday March 17, 2017 @01:15PM (#13895812)
Netflix doesn't pay retail prices for AWS.
Re:A million-dollar engineering problem by lossolo on Thursday March 16, 2017 @02:50PM (#13887848)
I have services that do not fit on one server and still I don't need AWS. Distributing load/dividing services on x-xx servers is not rocket science, especially with tools we have available at the moment.
Re:A million-dollar engineering problem by sdflkd on Thursday March 16, 2017 @03:12PM (#13888107)
How does one begin to learn about these things? Minimizing cost of running services sounds super interesting but as a student I've never had to deal with it and am basically starting with 0 knowledge.
Re:A million-dollar engineering problem by sillysaurus3 on Thursday March 16, 2017 @06:46PM (#13889852)
I worked through the labs at https://pdos.csail.mit.edu/6.824/ for fun. It's more along the lines of "How can we write a distributed fault-tolerant database?" but you might like it anyway.

Lab 4 is a beast with more lives than <insert metaphor>. The moment you think you've finally written your distributed system correctly, the unit tests will prove your service fails during XYZ network partition topologies. It's very worthwhile to be forced to think about issues like that and to design distributed systems for correctness.

But to address your question more directly, it's generally just a matter of scaling your service as much as possible on a single server. The server has finite resources (CPU, Memory, network, disk) so you either know how your system consumes those resources (because e.g. you wrote the service, and you know it uses O(n) memory w.r.t. the workload) or you graph your usage over time and try to predict when you'll exhaust your available resources. At that point you can usually think of some straightforward optimizations, which keeps everything on a single server. But eventually you might run out of resources with no obvious path to optimize it, so what then?

It depends entirely on your service, but typically you can just use off-the-shelf software to scale to multiple servers. For example you could set up three servers, each running Redis, and have Redis keep a list of "work to be done." Then your central process just farms out the workload to each of the three servers round-robin style, for example.

But at that point your service becomes a lot more brittle, e.g. you'll need to set up a failover solution so that your cluster can survive partitions and outages. (Redis uses Sentinel for that.) So it's worth keeping everything on a single server for as long as possible, if you can work out the optimizations to do so, since it's so much simpler with only one server. (HN is still running on a single core and serving 350k daily uniques, I believe, which shows just how effective it can be to keep your architecture as simple as possible.)

Re:A million-dollar engineering problem by sdflkd on Friday March 17, 2017 @02:38PM (#13896676)
Wrt the first link, I'm going to be taking a distributed systems course next semester that (hopefully) covers the same material. Nice to know what I learn at school is somewhat applicable.

My question is learning about design ideas like having Redis keeping a list of "work to be done" and such. Using modern tools to combat 'modern' problems. Is it just something you figure out after knowing the fundamentals (i.e. when you can identify a problem you know what the solution needs to be)?

Re:A million-dollar engineering problem by sillysaurus3 on Friday March 17, 2017 @08:27PM (#13899154)
Yeah, pretty much. I've never actually done it, but I know I could do it if I needed to.

If it sounds mysterious, think of it this way: Imagine you were thrown into a room with a computer, internet, and endless food, and the only way out of the room was to solve this problem. I bet you'd figure it out within a week or two, or a couple months max. (If only to go have a shower.)

One thing to watch out for: Solving modern problems can be pretty unsatisfying. Before you experience what life is like at a modern company, you tend to think of them as functional, orderly, and planned. Real companies are almost universally dysfunctional, disorderly, and haphazard. It's very rare that a plan is conceived, followed, and deployed without growing some warts and throwing in some hacks to get it done.

So I think you should enjoy this time, where you're free to think of thought-problems like "What's the most correct and extensible way to solve this problem?" instead of being forced to solve them on a time crunch.

Re:A million-dollar engineering problem by hluska on Thursday March 16, 2017 @09:32PM (#13890646)
Thanks for the link to 6.824! It looks amazing and I can't to start working through the labs.
Re:A million-dollar engineering problem by walrus01 on Thursday March 16, 2017 @04:33PM (#13888917)
A million dollars buys a shitload of fast 1U dual socket xeon servers each with 512GB of RAM.
Re:A million-dollar engineering problem by user5994461 on Thursday March 16, 2017 @05:22PM (#13889320)
-looks at this datacenter-

Well, actually it doesn't.

RAM and Xeons are expensive.

Re:A million-dollar engineering problem by gkop on Thursday March 16, 2017 @07:14PM (#13889998)
So how many does it buy?
Re:A million-dollar engineering problem by tiplus on Friday March 17, 2017 @06:30AM (#13892889)
I would estimate the cost for three years like this:

- 1U single socket Supermicro Xeon E5v4-2630 10core+1GTX1070 GPU = 1500EUR

- operation costs (power+cooling) over 3 years = 1500EUR

- cost of 2 hardware admins 160k/year

- renting local rack space 15EUR/U

This equals about 145 servers for 3 years for us for 1 Million. The setup is highly optimized for _one_ set of data crunching tasks, not DB. We do not need much ram, or network but require a specific CPU/GPU ratio.

Re:A million-dollar engineering problem by geezerjay on Saturday March 18, 2017 @11:57AM (#13901835)
>cost of 2 hardware admins 160k/year

This is by far the most expensive item in your estimate, and I'm sure that you don't suddenly need to hire another pair of admins when you buy a single Xeon blade.

Once you factor this fact in your estimates, you'll realise that the unit cost of each server is, unlike your estimate, negligible.

Re:A million-dollar engineering problem by user5994461 on Friday March 17, 2017 @09:24AM (#13893711)
Let's say 1 Rack of 42 * 1U servers.

That's about the upfront costs of servers ONLY.

Ignoring cooling, all personal costs, electricity, networking gear, network storage and future maintenance.

Re:A million-dollar engineering problem by Aeolun on Friday March 17, 2017 @03:53AM (#13892305)
Approximately 4?
Re:A million-dollar engineering problem by patrickg_zill on Friday March 17, 2017 @10:40AM (#13894284)
There are companies that will lease you a dedicated server with 40 cores and 256gb RAM for $499/month.

Figure a 10% quantity discount and you are looking at at least 200 of those for about $1 million per year.

Re:A million-dollar engineering problem by geezerjay on Saturday March 18, 2017 @12:01PM (#13901856)
Just because a company is ripping you off, it doesn't mean that's representative of the real market.

For 500€ a month, it's possible to buy your own 40 core blade with 256gb of RAM. In fact, it's possible to buy a pair of those servers.

Re:A million-dollar engineering problem by eip on Friday March 17, 2017 @01:23PM (#13895909)
Hetzner will rent you 24 cores (48 'cloud' cores), 1024GB RAM, and 4TB SSD for less than $499/month.
Re:A million-dollar engineering problem by ilaksh on Friday March 17, 2017 @02:38AM (#13892023)
> simply not using AWS is a competitive advantage.

The way you wrote your comment about using a dedicated server implies that there are no other viable cloud providers besides AWS. That is the problem, people do not know or do not acknowledge the existence of a number of other cloud/VPS providers that, in most cases, would work perfectly fine for their startup, and be a massively better value.

Such as Digital Ocean, Linode, or many small relatively less well-known providers that are perfectly fine like UltraVPS etc.

Sure, some few people do actually need DynamoDB or some other ultra-scaling AWS service, but people who just need VPSs can get a much better deal elsewhere.

Re:A million-dollar engineering problem by rbranson on Thursday March 16, 2017 @03:17PM (#13888172)
Totally. If the growth rate is reasonable (<50% y/y) and haven't really broken beyond what can be done on a single machine, using AWS or GCE or Azure is a ludicrous decision, short of a "serverless" style architecture. It's pretty easy to get sucked into the "best practices" and overengineer something that costs a lot of money.
Re:A million-dollar engineering problem by lossolo on Thursday March 16, 2017 @02:46PM (#13887795)
Exactly this. I am using dedicated servers everywhere, I would pay easily 10-20x more for the same if I would use AWS instead.
Re:A million-dollar engineering problem by jaredklewis on Friday March 17, 2017 @08:40AM (#13893472)
Well, it seems obvious that if you want scalable, redundant, no downtime infrastructure, it will cost more than non-redundant, non-scalable infrastructure.

While it was obviously a good trade off for this company, it seems silly to then extrapolate that all companies would benefit by getting rid of redundancy and scalability.

Re:A million-dollar engineering problem by reacweb on Friday March 17, 2017 @11:18AM (#13894590)
IMHO, AWS is fabulous when your needs are a fast moving target. When you have something stable and have time to optimize for performance and cost, dedicated servers are better (cheaper and/or faster). There is no silver bullet.
Re:A million-dollar engineering problem by amelius on Thursday March 16, 2017 @03:28PM (#13888295)
I guess you could go even lower by not renting, but buying a server instead.
Re:A million-dollar engineering problem by qeternity on Thursday March 16, 2017 @03:51PM (#13888544)
Not necessarily true. We run a decent amount of gear with OVH, and because if their scale and bulk discounts from OEM, our TCO is actually lower than it otherwise would be. I'm sure this isn't true at much larger scale, but I would bet it's true for most people.
Re:A million-dollar engineering problem by patrickg_zill on Thursday March 16, 2017 @08:51PM (#13890457)
You are absolutely correct, and I have seen this sort of thing time and again... "cloud" doesn't mean that the server is magically faster - it usually means "a great deal slower" because it is a shared resource.
Re:A million-dollar engineering problem by yegle on Thursday March 16, 2017 @03:17PM (#13888171)
So, how about backup, availability and a potential additional employee to make sure the server runs fine?

If they can indeed fit their footprint in one single server, then it should be fisible to just host the server at someone's home with enough upload speed, no?