2

I am trying to set up a filesystem server, so that I can use my various laptops to transparently mount a directory containing many VirtualBox VMs, some of which run full graphics environments. I will have up to 10 headless VMs running concurrently (as well as one at a time with display)

I plan on using this server for also serving home directories and media folders (with HD video and music) to a few machines. All of it should be transparent (fast, and appear to my Linux systems as though it is local). I plan on using a combination of NFS4 and SSHFS, and connecting to the fs server with Wireless LAN.

Currently, I'm using a RaspberryPi I had lying around, and It sort-of works for serving the music/video (the VMs run, but they are very slow, I'm not even gonna try the home directories).

Is there a way to tune sshfs, or VirtualBox itself, to cache, page (or whatever) the VMs locally in a more efficient way for the task at hand? Perhaps somebody can give me some tips on picking out server hardware that's budget friendly?

P.S. The wireless router is pretty fast ASUS RT-AC66U, so I think I won't have a problem there.. and ALL of the files I wan't to serve are currently on a 2TB external hard-drive.

EDIT --

So basically, what I'm getting from everybody is that I need a significant portion of the combined size of the Virtual disk images in RAM (or is it disk cache?) on the file server, so at that point my bottleneck becomes the wireless network (and relevant components like cards/adapters)? Also, is there a way to tune the RAM on a Linux machine to favor the virtual disk images (or any specific files) over other freeable memory?

  • If you've got WIFI AC then - if your external drive is a USB 2.0 - your bottleneck will probably be the disk connection. Getting it in an eSATA/USB 3 enclosure could alleviate that a great deal - but all of those external hdds are usually WD Greens or equivalent - economy class disks. You'll want some redundancy at least. – mikeserv Jan 12 '15 at 4:57
  • Mounting over a volatile connection such as wifi sounds like a dangerous idea. NFS is robust in a way that it just blocks and freezes until the connection is up again, but sshfs will probably drop the connection. The bottleneck are probably the virtual machines. A virtual hard drive image is frequently accessed all across the file (the file contains an entire fs with all its complexity) and driving this over an encrypted layer (ssh + probably wifi) and with the standard wifi delay sounds terrible. VM should probably be loaded into a ramfs on the laptop. – orion Jan 12 '15 at 11:26
  • 1
    Really, I think the bottle neck for hosting virtual machines on a raspberry pi is the CPU--it's single threaded. This means that each of your VM's is contending with each other, the rest of the server processes, and the kernel for CPU time on the single core. Make sure that there's a real server core backing each of your virtual cores. Also, the memory size is low, so your disk cache is also going to be small, so you'll spend more time then normal doing disk I/O, which is super slow over USB. If you have a place for one, you can buy cheap server refurbs off ebay--like a DL360 G5. – Christopher Neylan Jan 12 '15 at 22:10
  • @ChristopherNeylan - wow. Totally missed the dev board angle - definitely wont work. serving 10 concurrent encrypted FUSE mounts will explode it. – mikeserv Jan 13 '15 at 5:21
  • 1
    I never recommended sshfs, I agree it's more of a hack. NFS would be the way to go, as it is more robust and made properly on the inside. I haven't had much experience with the newest wifi standard, but what concerns me the most is that the connection can degrade unexpectedly: even the fastest connection can experience unexpected lag, dropped packets, or down time for any reason. But I'll be glad if I'm proved wrong, I have trust issues with wifi. – orion Jan 13 '15 at 16:09
0

There is no single bottleneck. It's a stack of layers that each make it impossible.

If you really need what you ask for, start again and expect to spend quite some money. Also, you may read some more about the technologies you use, to get a feeling for what may work together or not.

But then, I think you may not actually need what you describe. For example, you may not need network access as fast as if it were local.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.