Hello What you can try is create a 100% isolated environment for each run
since when you import a box using virtualbox, it first will import the same default folder ~/Virtualbox VMs/<same_name_if_same_base_box> this is base on my own personal tests. then will rename it to the default name per vagrant setup or vagrant default So at each environment, you can add JOBID="<some_unique_id>" VBOX_USER_HOME="~/ci/$JOBID/vbox" mkdir -p $VBOX_USER_HOME VBoxManage setproperty machinefolder VBOX_USER_HOME="~/ci/$JOBID/vbox" That will create the structure that will avoid such collisions JOBID can be an id from jenkins or some time stamp generated with date Hope this helps Alvaro On Fri, Jul 10, 2015 at 12:40 AM, Chris Burroughs <[email protected]> wrote: > On 07/07/2015 08:50 PM, Chris Burroughs wrote: >> >> I'm using vagrant with the virtualbox driver in a CI environment >> (jenkins + test-kitchen). I'm running into problems with spooky errors >> when multiple jobs are running at the same time (and there are thus >> concurrent vagrant commands running). For example with running 4 jobs >> at a time, about 6% of jobs will fail with a transient error (it is >> unlikely to occur for the same job if only that job is run again in >> isolation). > > > > Gating so that only one 'vagrant' command runs at a time was unsuccessful in > reducing the error rates. I suppose the 'critical section' could include > async operations after `vagrant up` returns. This is a surprising result to > me since we have a box with > 50 VMs spun up by humans and no one has > reported a similar error (so >> VMS, but << start/stop operations) > > I ran the same job in serial > 100 times with no failures which I believe > confirms is a problem with concurrent operations and not just a rare error. > > -- > This mailing list is governed under the HashiCorp Community Guidelines - > https://www.hashicorp.com/community-guidelines.html. Behavior in violation > of those guidelines may result in your removal from this mailing list. > > GitHub Issues: https://github.com/mitchellh/vagrant/issues > IRC: #vagrant on Freenode > --- You received this message because you are subscribed to the Google > Groups "Vagrant" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/vagrant-up/559E6BAD.2030008%40gmail.com. > For more options, visit https://groups.google.com/d/optout. -- This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list. GitHub Issues: https://github.com/mitchellh/vagrant/issues IRC: #vagrant on Freenode --- You received this message because you are subscribed to the Google Groups "Vagrant" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ewPHsLcHWkpBGa6h51LYg26ZfU4w77%3Det6ucDYgAVsLew%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
