Re: [vagrant-up] Clarification of Locations on disk (windows)

147 views
Skip to first unread message

JP Toto

unread,
Oct 11, 2018, 9:32:33 AM10/11/18
to vagra...@googlegroups.com
You're right about the Vagrant box storage. Those are cached versions of the downloaded boxes.

The created virtual machines get stored wherever the hypervisor is setup to store them. Vagrant talks to the hypvervisor and orchestrates it but the hypvervisor itself takes over from there and "custodies" the virtual machine. For example, if you're using VirtualBox, you can check the settings to see where the default storage location is for new virtual machines. There is a similar setting for Hyper V. 

Once you check that setting to see where the default is, you'll see where your Vagrant boxes are created.

On Thu, Oct 11, 2018 at 7:38 AM <design...@gmail.com> wrote:
I'm using Vagrant on Windows and I'd like to understand where it stores the files that can be found in the virtual machine.

I know that the boxes are stored in C:\Users\Cristian\.vagrant.d\boxes

From what I understand, boxes are not being changed when I install software or make changes to my virtual machines.

Example start:

If I do vagrant box list, I get

hashicorp/precise64 (virtualbox, 1.1.0)
laravel/homestead   (virtualbox, 6.0.0)
laravel/homestead   (virtualbox, 6.3.0)


Now I create as many new virtual machines from hashicorp/precise64: Vagrant init, then edit Vagrantfile and enter config.vm.box = "hashicorp/precise64" then do vagrant up.
I can do this 20 times and I will get 20 virtual machines, all of them independent from each other, all of them created from hashicorp/precise64. I can install apache for example on 1 of them and it will not be installed on any others.

Example end:


Now my question is: If I go via SSH inside any of those machines and install 1 gigabyte worth of linux software (apache, mail server, and so on)...where does it get stored?

I know it's not supposed to be stored in C:\Users\Cristian\.vagrant.d\boxes\hashicorp-VAGRANTSLASH-precise64, because that always stays "clean".
I know it's also not stored in the folder where my Vagrantfile lives, because that's always a few kilobytes in size.
I know it's not stored in C:\Users\Cristian\.vagrant.d\tmp because that only has 3 folders...whereas I have many more virtual machines powered by vagrant.

So where does it get stored? Can't seem to figure that out.

--
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 vagrant-up+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/68974ba1-3d9b-4a9a-9cc4-28d34f0ff38b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
JP Toto   |   james....@gmail.com   |   http://jptoto.jp   |   @jptoto

Cristian Enache

unread,
Oct 11, 2018, 6:17:42 PM10/11/18
to vagra...@googlegroups.com
Thank you, that answers my question!

Reply all
Reply to author
Forward
0 new messages