Vagrant config

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Vagrant config

Makrand
Hello,

Getting started with vagrant.

Right now I am playing with hashicorp/precise64 box

The only thing I defined in vagrant file is name of box and kept rest file (created with vagrant init) as is. The VM is getting launched by default into /home/user/Virtualbox VMs folder. (Since this folder in on SSD, do not want to use if for testing purposes)

1) Is there any way can force VM to be launched into particular folder?? say /media/mount/VMs.

2) Where can I define the cpu core/ghz and root disk size parameters for VM? 

Already looked at below:- https://www.vagrantup.com/docs/vagrantfile/machine_settings.html

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/fa8f1e76-762e-4e1d-aa23-8eb57c194853%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Vagrant config

Alvaro Miranda Aguilera
hello

yes

1. you can open virtualbox GUI, go to settings and replace the default location for vms.

2. you can update the vagrantfile to modify the VM to adjust memory and CPU count.

ghz not sure, say your machine is 2ghz you can set some sort of cpu caps on utilization


cpu cap:


memory and cpu:

config.vm.provider "virtualbox" do |v|
  v.memory = 1024
  v.cpus = 2
end

Thanks
Alvaro

On Wed, Nov 22, 2017 at 1:38 PM, Makrand <[hidden email]> wrote:
Hello,

Getting started with vagrant.

Right now I am playing with hashicorp/precise64 box

The only thing I defined in vagrant file is name of box and kept rest file (created with vagrant init) as is. The VM is getting launched by default into /home/user/Virtualbox VMs folder. (Since this folder in on SSD, do not want to use if for testing purposes)

1) Is there any way can force VM to be launched into particular folder?? say /media/mount/VMs.

2) Where can I define the cpu core/ghz and root disk size parameters for VM? 


--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/fa8f1e76-762e-4e1d-aa23-8eb57c194853%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0exBpTs%3D-59-DPSwVae4h3avAm65%2Bf0FwNFeNnrrrug%2BNw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Vagrant config

Makrand
Hi,

Thanks a lot. 

for CPU ghz did below

   config.vm.provider "virtualbox" do |vb|
  #   # Display the VirtualBox GUI when booting the machine
  #   vb.gui = true
  #
  #    Customize the CPU/RAM on the VM:
     vb.memory = "512"
     vb.cpus = 1
     vb.name = "pilot-vm"
  #  Cap cpu limit at 50%. So it can be 1ghz cpu
     vb.customize ["modifyvm", :id, "--cpuexecutioncap", "50"]

     end

It just shows original ghz of native cpu at OS (and not 1ghz), but at Vbox GUI you can see cpu capped at 50%. So its 1ghz roughly.


BTW, 

1) how can I customize the size of disk? by default its creating 80GB of disk (I know its dynamically allocated, but it would still be nice to have this parameter defined)
2) Any glossary/index page which lists config parameters that we defined for each bit.





--
Makrand


On Wed, Nov 22, 2017 at 6:58 PM, Alvaro Miranda Aguilera <[hidden email]> wrote:
hello

yes

1. you can open virtualbox GUI, go to settings and replace the default location for vms.

2. you can update the vagrantfile to modify the VM to adjust memory and CPU count.

ghz not sure, say your machine is 2ghz you can set some sort of cpu caps on utilization


cpu cap:


memory and cpu:

config.vm.provider "virtualbox" do |v|
  v.memory = 1024
  v.cpus = 2
end

Thanks
Alvaro

On Wed, Nov 22, 2017 at 1:38 PM, Makrand <[hidden email]> wrote:
Hello,

Getting started with vagrant.

Right now I am playing with hashicorp/precise64 box

The only thing I defined in vagrant file is name of box and kept rest file (created with vagrant init) as is. The VM is getting launched by default into /home/user/Virtualbox VMs folder. (Since this folder in on SSD, do not want to use if for testing purposes)

1) Is there any way can force VM to be launched into particular folder?? say /media/mount/VMs.

2) Where can I define the cpu core/ghz and root disk size parameters for VM? 


--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/fa8f1e76-762e-4e1d-aa23-8eb57c194853%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
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 a topic in the Google Groups "Vagrant" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vagrant-up/xjsNZh0S7HI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0exBpTs%3D-59-DPSwVae4h3avAm65%2Bf0FwNFeNnrrrug%2BNw%40mail.gmail.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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CABdC_7%3DpfAQNqqxT2bQEgmZFKWK-Xd0V1sQNCh7XLu0EYRiYNA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Vagrant config

Alvaro Miranda Aguilera
hello

for 1, nope, chicken egg situation.

better build a new base box that is suit for the task. check packer.io for a tool to build base boxes.

for 2.

Check virtualbox documentation, cpu/memory are just in alias, but all the config are like this:

vb.customize ["modifyvm",..

that is like running VBoxManage modifyvm

so at command line you can do VBoxManage modifyvm --help or something, or just check VirtualBox documentation online

Thanks!
Alvaro

On Thu, Nov 23, 2017 at 12:00 PM, Makrand <[hidden email]> wrote:
Hi,

Thanks a lot. 

for CPU ghz did below

   config.vm.provider "virtualbox" do |vb|
  #   # Display the VirtualBox GUI when booting the machine
  #   vb.gui = true
  #
  #    Customize the CPU/RAM on the VM:
     vb.memory = "512"
     vb.cpus = 1
     vb.name = "pilot-vm"
  #  Cap cpu limit at 50%. So it can be 1ghz cpu
     vb.customize ["modifyvm", :id, "--cpuexecutioncap", "50"]

     end

It just shows original ghz of native cpu at OS (and not 1ghz), but at Vbox GUI you can see cpu capped at 50%. So its 1ghz roughly.


BTW, 

1) how can I customize the size of disk? by default its creating 80GB of disk (I know its dynamically allocated, but it would still be nice to have this parameter defined)
2) Any glossary/index page which lists config parameters that we defined for each bit.





--
Makrand


On Wed, Nov 22, 2017 at 6:58 PM, Alvaro Miranda Aguilera <[hidden email]> wrote:
hello

yes

1. you can open virtualbox GUI, go to settings and replace the default location for vms.

2. you can update the vagrantfile to modify the VM to adjust memory and CPU count.

ghz not sure, say your machine is 2ghz you can set some sort of cpu caps on utilization


cpu cap:


memory and cpu:

config.vm.provider "virtualbox" do |v|
  v.memory = 1024
  v.cpus = 2
end

Thanks
Alvaro

On Wed, Nov 22, 2017 at 1:38 PM, Makrand <[hidden email]> wrote:
Hello,

Getting started with vagrant.

Right now I am playing with hashicorp/precise64 box

The only thing I defined in vagrant file is name of box and kept rest file (created with vagrant init) as is. The VM is getting launched by default into /home/user/Virtualbox VMs folder. (Since this folder in on SSD, do not want to use if for testing purposes)

1) Is there any way can force VM to be launched into particular folder?? say /media/mount/VMs.

2) Where can I define the cpu core/ghz and root disk size parameters for VM? 


--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/fa8f1e76-762e-4e1d-aa23-8eb57c194853%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
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 a topic in the Google Groups "Vagrant" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vagrant-up/xjsNZh0S7HI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0exBpTs%3D-59-DPSwVae4h3avAm65%2Bf0FwNFeNnrrrug%2BNw%40mail.gmail.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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CABdC_7%3DpfAQNqqxT2bQEgmZFKWK-Xd0V1sQNCh7XLu0EYRiYNA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
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 [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0exgsZ4U_Txm3GfGdE5unXeu2Sa0%3DtQfZMFT2L3L%3DUS1%3DA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.