Lion and/or Core 2 Duo and/or VB and/or vagrant causing pain? Try enabling host i/o caching for your virtual disk

639 views
Skip to first unread message

notproperlycut

unread,
Sep 29, 2011, 4:49:38 PM9/29/11
to Vagrant
Accept my apologies if this is widely know already - I did a little
searching beforehand.

I've been having a lot of trouble using vagrant since upgrading to
Lion. Symptoms have included: Stuttering and temporarily unresponsive
Lion, spinning pinwheel, complete lock-ups of Lion requiring reboot,
that grey Apple screen telling me I have to hit the power button,
Ubuntu guests failing due to "read-only filesystem" and absolutely no
hope of running two boxes at the same time for any useful duration.
Issues have been happening several times a day, every day.

Core 2 Due MBA + Core 2 Duo MBP
Lion 10.7.1
Ruby 1.9.2p290, vagrant 0.8.7
virtualbox 4.1.2
Veewee-built box(es) derived from the 'ubuntu-10.10-server-i386'
template

The fix for me? Enabling virtualbox's "Host i/o caching" option on
the .vmdk used by my boxes. Today I have had no problems at all and my
vagrant workflow is completely back to normal. Subjectively - it's
hard to be sure - it seems that I've traded a little performance for
this restored stability.


If you halt your box first, the Virtualbox GUI will let you enable the
setting:
VB GUI -> Your VM -> Settings -> Storage -> Your disk -> tick "Use
host I/O cache"

As a more permanent fix I have updated my veewee definition(s) to
enable the option:
:hostiocache => 'on' in the relevant definition.rb file


Perhaps this will help someone else who's having similar trouble.

Dafydd

unread,
Jan 30, 2012, 3:22:37 PM1/30/12
to vagra...@googlegroups.com
This seems to fix a similar issue I was having. Thanks for that! I don't actually have a veewee definition yet, so I did:
  1. Fire up the VM then run vagrant halt.
  2. Open up VirtualBox and use the GUI to change the settings to enable the host I/O cache for the SATA controller.
  3. Re-package the base box: vagrant package.
  4. Remove and re-add the base box: vagrant box remove <box>; vagrant box add <box> package.box
Reply all
Reply to author
Forward
0 new messages