It is interesting that even after falling prices of HDDs, S3 costs have remained the same for at least 8 years. There's just not enough competition to push them to reduce costs. But imagine money it brings in in AWS because of this.
How AWS S3 serves 1 petabyte per second on top of slow HDDs
151–160 of 172 posts
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#152Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#153Earlier quoted context omitted.
Ceph's design is to avoid a single bottleneck or single point of failure, with many nodes that can all ingest data in parallel (high bandwidth across the whole cluster) and be redundant/fault tolerant in the face of disk/host/rack/power/room/site failures. In exchange it trades away some of: low latency, efficient disk space use, simple design, some kinds of flexibility. If you have a "small" use case then you will h…
While most of what you speak of re Ceph is correct, I want to strongly disagree with your view of not filling up Ceph above 66%. It really depends on implementation details. If you have 10 nodes, yeah then maybe that's a good rule of thumb. But if you're running 100 or 1000 nodes, there's no reason to waste so much raw capacity. With upmap and balancer it is very easy to run a Ceph cluster where every single node/dis…
Other than Ceph I've only worked on systems where one disk failure needs one hotspare disk to rebuild, anything else is handled by a separate backup and DR plan. With Ceph, depending on the design it might need free space to handle a host or rack failure, and that's pretty new to me and also leads me to prefer more free space rather than less. With a hundred "units" of storage grouped into 5 failure domains then only 80% is usable, again probably better with scale and experienced design.
If I had 10,000 nodes I'd rather 10,100 nodes and better sleep than playing "how close to full can I get this thing" and constantly on edge waiting for a problem which takes down a 10,000 node cluster and all the things that needed such a big cluster. I'm probably taking some advice from Reddit threads talking about 3-node Ceph/Proxmox setups which say 66% and YouTube videos talking about Ceph at CERN - in those I think their use case is a bursty massive dump of particle accelerator data to ingest, followed by a quieter period of read-heavy analysis and reporting, so they need to keep enough free space for large swings. My company's use case was more backup data churn, lower peaks, less tidal, quite predictable, and we did run much fuller than 66%. We're now down below 50% used as we migrate away, and they're much more stable.
[1] it didn't help that we had nobody familiar with Ceph once the builder had left, and these had been running a long time and partially upgraded through different versions, and had one-of-everything; some S3 storage, some CephFS, some RBDs with XFS to use block cloning, some N+1 pools, some Erasure Coding pools, some physical hardware and some virtual machines, some Docker containerised services but not all, multiple frontends hooked together by password based SSH, and no management will to invest or pay for support/consultants, some parts running over IPv6 and some over IPv4, none with DNS names, some front-ends with redundant multiple back end links, others with only one. A well-designed, well-planned, management-supported cluster with skilled admins can likely run with finer tolerances.
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#154> full-platter seek time: ~8ms; half-platter seek time (avg): ~4ms Average distance between two points (first is current location, second is target location) when both are uniformly distributed in [ 0 .. +1 ] interval is not 0.5, it’s 1/3. If the full platter seek time is 8ms, average seek time should be 2.666ms.
Full seek on a modern drive is a lot closer to 25ms than 8ms. It's pretty easy to test yourself if you have a hard drive in your machine and root access - fire up fio with --readonly and feed it a handmade trace that alternates reading blocks at the beginning and end of disk. (--readonly does a hard disable of any code that could write to the drive) Here's a good paper that explains why the 1/3 number isn't quite rig…
Is "full seek" a synonymous for worst case time to reach a position occurring less than 1% of working time?
From the article: max seek time is 15.2 ms + additionally 0 to 8.3 ms of rotational latency.
Reordering of sector accesses by NCQ should reduce worst case scenario occurrences.
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#155Earlier quoted context omitted.
Full seek on a modern drive is a lot closer to 25ms than 8ms. It's pretty easy to test yourself if you have a hard drive in your machine and root access - fire up fio with --readonly and feed it a handmade trace that alternates reading blocks at the beginning and end of disk. (--readonly does a hard disable of any code that could write to the drive) Here's a good paper that explains why the 1/3 number isn't quite rig…
> Full seek on a modern drive is a lot closer to 25ms than 8ms Is "full seek" a synonymous for worst case time to reach a position occurring less than 1% of working time? From the article: max seek time is 15.2 ms + additionally 0 to 8.3 ms of rotational latency. Reordering of sector accesses by NCQ should reduce worst case scenario occurrences.
When I was reviewing it for publication I ran a couple of tests and found more like 18 on the devices I tested, but I’m sure there are some that do 15. 25 is probably on the slow end. (although I’ve never tested a HAMR drive - their head assemblies are probably heavier and more delicate)
Old SCSI 10K drives could hand a huge queue and reach 500 random read IOPS, sounding like a buzzsaw while they did it. Modern capacity drives treat their internals much more gently, and don’t get as much queuing gain. Note also that for larger objects the chunk size is probably 1+ rotations to amortize the seek overhead.
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#156> full-platter seek time: ~8ms; half-platter seek time (avg): ~4ms Average distance between two points (first is current location, second is target location) when both are uniformly distributed in [ 0 .. +1 ] interval is not 0.5, it’s 1/3. If the full platter seek time is 8ms, average seek time should be 2.666ms.
There's acceleration of the read head to move it between the tracks. So it may well be 4ms because shorter distances are penalized by a lower peak speed of the read head as well as constant factors (settling at the end of motion)
That’s a bogus number from an ancient slide deck for a class in 2001 or so, that’s misled generations of folks googling for the answer.
Note also that the outer tracks are longer (google ZCAV) and hold more data, so seeks across uniformly distributed block numbers do not generate uniformly distributed track numbers.
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#157Earlier quoted context omitted.
Full seek on a modern drive is a lot closer to 25ms than 8ms. It's pretty easy to test yourself if you have a hard drive in your machine and root access - fire up fio with --readonly and feed it a handmade trace that alternates reading blocks at the beginning and end of disk. (--readonly does a hard disable of any code that could write to the drive) Here's a good paper that explains why the 1/3 number isn't quite rig…
> Full seek on a modern drive is a lot closer to 25ms than 8ms Is "full seek" a synonymous for worst case time to reach a position occurring less than 1% of working time? From the article: max seek time is 15.2 ms + additionally 0 to 8.3 ms of rotational latency. Reordering of sector accesses by NCQ should reduce worst case scenario occurrences.
You can do this test yourself with fio —readonly and root access to a hard drive block device, even if it’s mounted. (good luck reading any files while the test is running, but no damage done) Pick a variety of very high and low blocks, and the min delay will be when rotational delay is close to zero.
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#158Earlier quoted context omitted.
That’s just fractional redundant copies.
And "fractional redundant copies" is way less obvious.
It just saves AWS money is all, by achieving greater redundancy with less disk usage.
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#159A few factual inaccuracies in here that don't affect the general thrust. For example, the claim that S3 uses a 5:9 sharding scheme. In fact they use many different sharding schemes, and iirc 5:9 isn't one of them. The main reason being that a ratio of 1.8 physical bytes to 1 logical byte is awful for HDD costs. You can get that down significantly, and you get wider parallelism and better availability guarantees to bo…
Naively it seems difficult to decrease the ratio of 1.8x while simultaneously increasing availability. The less duplication, the greater risk of data loss if an AZ goes down? (I thought AWS promises you have a complete independent copy in all 3 AZs though?) To me though the idea that to read like a single 16MB chunk you need to actually read like 4MB of data from 5 different hard drives and that this is faster is baf…
If we assume 3 AZs, then you lose 1/3 of shards when an AZ goes down. You could do at most 6:9, which is a 1.5 byte ratio. But that's unacceptable, because you know you will temporarily lose shards to HDD failure, and this scheme doesn't permit that in the AZ down scenario. So 1.5 is our limit.
To lower the ratio from 1.8, it's necessary to increase the denominator (the number of shards necessary to reconstruct the object). This is not possible while preserving availability guarantees with just 9 shards.
Note that Cloudflare's R2 makes no such guarantees, and so does achieve a more favorable cost with their erasure coding scheme.
Note also that if you increase the number of shards, it becomes possible to change the ratio without sacrificing availability. Example: if we have 18 shards, we can chose 11:18, which gives us 1.61 physical bytes per logical byte. And it still takes 1 AZ + 2 shards to make an object unavailable.
You can extrapolate from there to develop other sharding schemes that would improve the ratio and improve availability!
Another key hidden assumption is that you don't worry about correlated shard loss except in the AZ down case. HDDs fail, but these are independent events. So you can bound the probability of simultaneous shard loss using the mean time to failure and the mean time to repair that your repair system achieves.
Re: How AWS S3 serves 1 petabyte per second on top of slow HDDs
#160Earlier quoted context omitted.
I generally don't think about storage I/O speed at that scale (I mean really who does?). I once used a RAID0 to store data to HDDs faster, but that was a long time ago. I would have naively guessed an interesting caching system, and to some degree tiers of storage for hot vs cold objects. It was obvious after I read the article that parallelism was a great choice, but I definitely hadn't considered the detailed schem…
RAID doesn’t exactly make writes faster, it can actually be slower. Depends on if you are using RAID for mirroring or sharding. When you mirror, writes are slower since you have to write to all disks.