通过以下 Referral 链接购买 DigitalOcean 主机,你将可以帮助 V2EX 持续发展
DigitalOcean - SSD Cloud Servers
nonsense
V2EX  ›  VPS

廉价 VPS 计划存储 1 亿个 10KB 小文件提供对外访问,这 1 亿个数据怎么存储比较好?

  •  
  •   nonsense · Nov 9, 2017 · 817 views
    This topic created in 3112 days ago, the information mentioned may be changed or developed.
    100M*10KB = 10G 大小 廉价 VPS 的机械硬盘读取吞吐量在 50M ~ 130M 左右
    首先是不是否定了直接存硬盘? 100M 的 inode 元数据一是得重新格式化分区,二是 inode 元数据也要访问机械硬盘就太慢了。
    存储在 mysql/mongo/postgre 之类的数据库中,避免了元数据频繁访问,对每个文件做 hash,根据访问 hash 返回数据。cpu 能撑住的话应该能跑满峰值 1Gbps/125M 的带宽。
    除直接存储和存数据库之外还有其它的存储方案吗?
    3 replies    2017-11-12 09:58:45 +08:00
    msg7086
        1
    msg7086  
       Nov 11, 2017
    文件系统也是一个树形数据库。
    元数据不管怎样都会存在硬盘上,你以为数据库就没元数据了吗。
    存文件系统的话可以看看 Reiser4。
    derek80
        2
    derek80  
       Nov 11, 2017
    光存储的化存储类似 s3 对象存储比较划算吧。
    wavingclear
        3
    wavingclear  
       Nov 12, 2017 via iPad
    我为什么算出来是 1000G。。。
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5688 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 66ms · UTC 02:30 · PVG 10:30 · LAX 19:30 · JFK 22:30
    ♥ Do have faith in what you're doing.