From 0bc5849f30e47b51e64cafda772c17777cb53c8a Mon Sep 17 00:00:00 2001 From: Jeff Welling Date: Mon, 20 Mar 2017 19:53:51 -0700 Subject: [PATCH 1/2] Add disks to the ceph servers, plus notes --- Vagrantfile | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Vagrantfile b/Vagrantfile index 18e3f5c..a3e71f5 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -29,6 +29,19 @@ Vagrant.configure("2") do |config| config.vm.define "ceph-server-#{i}" do |config| config.vm.hostname = "ceph-server-#{i}" config.vm.network :private_network, ip: "172.21.12.#{i+11}" + config.vm.provider "virtualbox" do |v| + filename="./.vagrant/ceph#{i}.disk" + #This next step can fail if the disk is already created, eg if you + #CTRL+C'd a previous vagrant up, so wrap it in conditional. + unless File.exist?(filename) + #Create a sparse volume with a max size of 10GB called + v.customize ['createhd', '--filename', filename, '--size', 10 * 1024] + end + #You may have to tweak the value for --storagectl. + #Other folks have noted what worked for them here: + # https://gist.github.com/leifg/4713995 + v.customize ['storageattach', :id, '--storagectl', 'SATA', '--port', 1, '--device', 0, '--type', 'hdd', '--medium', filename] + end end end end From 15ff13349f3496edca0806076ecfb7bce841386c Mon Sep 17 00:00:00 2001 From: Jeff Welling Date: Mon, 20 Mar 2017 19:56:17 -0700 Subject: [PATCH 2/2] typo --- Vagrantfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Vagrantfile b/Vagrantfile index a3e71f5..ba9bd15 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -34,7 +34,7 @@ Vagrant.configure("2") do |config| #This next step can fail if the disk is already created, eg if you #CTRL+C'd a previous vagrant up, so wrap it in conditional. unless File.exist?(filename) - #Create a sparse volume with a max size of 10GB called + #Create a sparse volume with a max size of 10GB called "#{filename}" v.customize ['createhd', '--filename', filename, '--size', 10 * 1024] end #You may have to tweak the value for --storagectl.