big-ish personal storage
- 2 minutes read - 343 wordsI was curious what it would cost to have something like 5-30TB of storage space on hand. The obvious choices are between buying some hard drives and paying for an S3 bucket or something.
The amazon costs are pretty straightforward: you pick a region, they tell you the cost. Starting with their pricing table:
aws = [
{"level": "standard", "c_millidollars": 23},
{"level": "infrequent", "c_millidollars": 12.5},
{"level": "one_zone", "c_millidollars": 10},
{"level": "glacier", "c_millidollars": 4}
]
we can say
gbs = 10000
for level in aws:
dollars_per_gb = level["c_millidollars"] / 1000
dollars = gbs * dollars_per_gb
print("{} ==> ${} * {} = ${}/month".format(
level["level"], dollars_per_gb, gbs, dollars
))
and get back
standard ==> $0.023 * 12000 = $276.0/month
infrequent ==> $0.0125 * 12000 = $150.0/month
one_zone ==> $0.01 * 12000 = $120.0/month
glacier ==> $0.004 * 12000 = $48.0/month
Figuring out the hard drive cost, I started from some raw data:
raw = [
{"slug": "toshiba_x300_4tb", "c": 11299, "tb": 4, "link": "https://www.amazon.com/Toshiba-Performance-Desktop-Internal-HDWE150XZSTA/dp/B013JPKUU2"},
{"slug": "toshiba_x300_5tb", "c": 12999, "tb": 5, "link": "https://www.amazon.com/Toshiba-Performance-Desktop-Internal-HDWE150XZSTA/dp/B013JPLKQK"},
{"slug": "toshiba_x300_6tb", "c": 17505, "tb": 6, "link": "https://www.amazon.com/Toshiba-Performance-Desktop-Internal-HDWE150XZSTA/dp/B013JPLKJC"},
{"slug": "toshiba_x300_8tb", "c": 23973, "tb": 8, "link": "https://www.amazon.com/Toshiba-Performance-Desktop-Internal-HDWE150XZSTA/dp/B074BTZ2YJ"},
{"slug": "seagate_barracuda_4tb", "c": 9399, "tb": 4, "link": "https://www.amazon.com/Seagate-BarraCuda-3-5-Inch-Internal-ST4000DM004/dp/B071WLPRHN"},
{"slug": "seagate_barracuda_5tb", "c": 18857, "tb": 5, "link": "https://www.amazon.com/Seagate-Barracuda-2-5-Inch-Internal-ST5000LM000/dp/B01M0AADIX"},
]
This gives us a figure of $29.38/TB for hard drives.
Just to blow up our hard drive costs a bit, we can assume some drive-level redundancy. Maybe we want to use ZFS 2 (but maybe we don’t). One alternative is using hardware or maybe even software RAID. Let’s assume we want to do 5 disks with 2 parity (something like RAID6). Just sticking with 4TB drives for a sec, we’d be buying 20TB for 12TB of capacity.
Using our “average-priced” drives, that’d be $587.70 upfront cost for hard drives.
Interestingly, there’s some ongoing costs for this option, too: the electricity for the computer the drives plug into. Assuming a 200-watt machine and San Francisco electricity prices ($0.201 / kWh), we’d be looking at
1 month @ 200 watts = 200 watts * 730 hours = 146,000 watt-hours = 146 kWh
==> $29.35