Disk performance issue with shared folders

Discussions related to using VirtualBox on Windows hosts.

Re: Disk performance issue with shared folders

Postby mpack » 29. Jan 2014, 01:38

A performance issue with GA shared folders? No argument there, because performance has never been the point of that feature. If you want performance then configure a true network share, ideally using VirtIO-net. But I guess all that was in the benchmark results.
mpack
Site Moderator
 
Posts: 33699
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Disk performance issue with shared folders

Postby socratis » 29. Jan 2014, 12:00

pat1498, that was a really good article that you linked (http://mitchellh.com/comparing-filesyst ... l-machines). Developers and others have often asked for "real data" when someone complains about performance. Mitchell Hashimoto's analysis is very good and if the developers want to address the issue, it's an excellent starting point.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
socratis
Site Moderator
 
Posts: 27690
Joined: 22. Oct 2010, 11:03
Location: Greece
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5

Re: Disk performance issue with shared folders

Postby NamedNick » 29. Jan 2014, 12:26

mpack wrote:A performance issue with GA shared folders? No argument there, because performance has never been the point of that feature. If you want performance then configure a true network share, ideally using VirtIO-net. But I guess all that was in the benchmark results.

You are obviously very knowledgeable and I heard the term VirtIO-net the first time now. I did some research and found this mentioned in https://www.virtualbox.org/manual/ch06.html but I'm unable to connect the dots: using a Windows host and a Linux guest, could this be used to have a shared-folder equivalent with better performance?

The documentation mentions that "virtio" is available for the Linux guest but then I wouldn't understand the connection to be able so use shared folders that way.

Sorry if this sounds unclear,

thx
NamedNick
 
Posts: 14
Joined: 10. Apr 2013, 19:06

Re: Disk performance issue with shared folders

Postby Martin » 29. Jan 2014, 12:57

Virtualbox shared folders are not designed to be used programatically and also not for perfomance.
It is a very simplified file system implementation just to copy files from/to the guest.
Many applications produce errors using shared folders, because they expect advanced features like file locking or access controls which don't exist for shared folders.
Martin
Volunteer
 
Posts: 2463
Joined: 30. May 2007, 18:05
Primary OS: Fedora other
VBox Version: PUEL
Guest OSses: XP, Win7, Linux, OS/2

Re: Disk performance issue with shared folders

Postby NamedNick » 29. Jan 2014, 13:35

I understand but currently it seems I've not much choice on Windows host/Linux guest to share information and I'm trying to understand whether the comment from mpack would imply there's another way to share folders in this scenario without the performance impact of the vboxfs .
NamedNick
 
Posts: 14
Joined: 10. Apr 2013, 19:06

Re: Disk performance issue with shared folders

Postby mpack » 29. Jan 2014, 13:54

If you want performance you would:

  1. Configure a true shared folder just like you would between two physical PCs. Google for generic networking walkthroughs. The VBox GA shared folders API (vboxsf, and the "Shared folders" part of the VM settings) would not be used.
  2. Use a Virtio-net adapter in the VM network settings. This is a paravirtual device, meaning that it provides a driver level API inside the guest, but it "knows" that it's a virtual device and hence talks directly to the VirtualBox host - it doesn't need to go through the overhead of virtual register I/Os and IRQs.
Of course you'll need a VirtIO-net driver for your guest. The KVM project has drivers for Linux and Windows guests (XP and later), no doubt they are available for Mac as well.
mpack
Site Moderator
 
Posts: 33699
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Disk performance issue with shared folders

Postby pat1498 » 12. Feb 2014, 19:29

There is a great plugin for Vagrant/VBox NFS on Windows that solved my problems: http://www.jankowfsky.com/blog/2013/11/ ... r-windows/

I don't know if this will work for people needing advanced file system methods, but it works for me serving apache2.2.4
pat1498
 
Posts: 4
Joined: 28. Jan 2014, 21:23

Re: Disk performance issue with shared folders

Postby chrispitude » 24. Dec 2014, 18:57

mpack wrote:If you want performance you would:

  1. Configure a true shared folder just like you would between two physical PCs. Google for generic networking walkthroughs. The VBox GA shared folders API (vboxsf, and the "Shared folders" part of the VM settings) would not be used.
  2. Use a Virtio-net adapter in the VM network settings. This is a paravirtual device, meaning that it provides a driver level API inside the guest, but it "knows" that it's a virtual device and hence talks directly to the VirtualBox host - it doesn't need to go through the overhead of virtual register I/Os and IRQs.
Of course you'll need a VirtIO-net driver for your guest. The KVM project has drivers for Linux and Windows guests (XP and later), no doubt they are available for Mac as well.


Some time passes...

I've also been desperate for a way to improve the performance of shared folders, and from this thread it appears the solution is not to use them.

For a linux host with Win7 guest, would the right solution be to serve a samba share on the host, then reference it from the guest by IP address using Virtio-net? Will referencing it by IP address keep share traffic entirely on the host machine, without going out on the LAN?
chrispitude
 
Posts: 42
Joined: 2. Jan 2009, 14:22

Previous

Return to VirtualBox on Windows Hosts

Who is online

Users browsing this forum: BillG and 24 guests