How to set up a new droplet for extended storage only? (Block space n/a yet.)

November 19, 2016 118 views
Storage Block Storage Networking CentOS

I'm running out of disk space shortly and need to extend. Block Storage isn't available in my region (SGP1) yet, I wish it were, and resizing the current droplet isn't quite economically sensible when I don't currently need the extra RAM, CPU etc.

I see I can set up private networking etc. between droplets in the same region. I'm hoping the community here would have tips for setting up a new droplet that's used for storage only -- basically emulating Block Storage until it becomes available -- where the storage droplet is an extension of the "live" droplet's filesystem as seamlessly as possible

In other details: The storage droplet would be hosting materials that are downloaded via websites on the main droplet. I could always point subdomains to the new droplet, but that'd mean a new basic stack of server software to maintain, which I'd rather avoid. Also I'd prefer to run scripts to check and analyze the files in one go, rather than in separate runs. Thanks very much! =^_^=

1 Answer

I guess a NFS is a thing you're looking for.
How To Set Up an NFS Mount on Ubuntu 16.04 will explain you how to set it up. :)

NFS, or Network File System, is a distributed file system protocol that allows you to mount remote directories on your server. This allows you to leverage storage space in a different location and to write to the same space from multiple servers. NFS works well for directories...
  • Brilliant. If all I need to set up on the host box is FTP and NFS, I'm a happy camper. What sort of lag do you reckon there will be, compared to accessing files directly on the server? (And compared to Block Storage?) I imagine it'll be quite minimal, hopefully imperceptible.

    • I think Droplets are connected to each other with 1 GBps ethernet, if that matters to you.
      Basically, this is what you have to test.
      I guess, there would be differen between Block Storage and NFS, but not something noticeable to you or end users.
      I never played with it, so I can't say is there big difference, but I think there isn't, as it is based on fast network.

      • OK all set up here, happy camper is happy. PN, NFS, FTP, Iptables, li'l extras. So I just tested a DVD's worth (4.1 GB) to a NFS-mounted directory and it took ~70 seconds: write-to-host throughput of 70 MB/s. I copied back a 1.7 GB tar and it took ~20 sec: copy-from-host throughput at 85 MB/s. Oh wait, write happening at both ends huh. So 15 seconds for cat test.tar > /dev/null ie. read speed at 113 MB/s. (Same speed if I do it on a local file.)

        N.b. the ethernet would be 1 Gbps not 1 GBps, I wish! Which is 125 MB/s. Fair enough, nearly maxing it out with the read, so no bottlenecks here that anyone would ever notice. Whoever is downloading stuff over an OC-24 and getting itchy can suck it up or buy me an alien spacecraft too. ^_^

        • Glad to see you got it working. :)
          It sounds good. Thanks for sharing results.

          And yea, it should be 1 Gbps, typo. :P

Have another answer? Share your knowledge.