diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml index 796b9821e8..491f00c35f 100755 --- a/docs/mkdocs.yml +++ b/docs/mkdocs.yml @@ -93,6 +93,7 @@ pages: - ['articles/ambassador_pattern_linking.md', 'Articles', 'Cross-Host linking using Ambassador Containers'] - ['articles/runmetrics.md', 'Articles', 'Runtime metrics'] - ['articles/baseimages.md', 'Articles', 'Creating a Base Image'] +- ['articles/b2d_volume_resize.md', 'Articles', 'Increasing a Boot2Docker Volume'] # Reference - ['reference/index.md', '**HIDDEN**'] diff --git a/docs/sources/articles.md b/docs/sources/articles.md index 51335c6afd..325037b4ce 100644 --- a/docs/sources/articles.md +++ b/docs/sources/articles.md @@ -11,3 +11,4 @@ - [Runtime Metrics](runmetrics/) - [Automatically Start Containers](host_integration/) - [Link via an Ambassador Container](ambassador_pattern_linking/) + - [Increase a Boot2Docker Volume](b2d_volume_resize/) diff --git a/docs/sources/articles/b2d_volume_images/add_cd.png b/docs/sources/articles/b2d_volume_images/add_cd.png new file mode 100644 index 0000000000..f4ac25d879 Binary files /dev/null and b/docs/sources/articles/b2d_volume_images/add_cd.png differ diff --git a/docs/sources/articles/b2d_volume_images/add_new_controller.png b/docs/sources/articles/b2d_volume_images/add_new_controller.png new file mode 100644 index 0000000000..17b29fa660 Binary files /dev/null and b/docs/sources/articles/b2d_volume_images/add_new_controller.png differ diff --git a/docs/sources/articles/b2d_volume_images/add_volume.png b/docs/sources/articles/b2d_volume_images/add_volume.png new file mode 100644 index 0000000000..58e53dce48 Binary files /dev/null and b/docs/sources/articles/b2d_volume_images/add_volume.png differ diff --git a/docs/sources/articles/b2d_volume_images/boot_order.png b/docs/sources/articles/b2d_volume_images/boot_order.png new file mode 100644 index 0000000000..19a22fce7e Binary files /dev/null and b/docs/sources/articles/b2d_volume_images/boot_order.png differ diff --git a/docs/sources/articles/b2d_volume_images/gparted.png b/docs/sources/articles/b2d_volume_images/gparted.png new file mode 100644 index 0000000000..421e7e585c Binary files /dev/null and b/docs/sources/articles/b2d_volume_images/gparted.png differ diff --git a/docs/sources/articles/b2d_volume_images/gparted2.png b/docs/sources/articles/b2d_volume_images/gparted2.png new file mode 100644 index 0000000000..0226a047ba Binary files /dev/null and b/docs/sources/articles/b2d_volume_images/gparted2.png differ diff --git a/docs/sources/articles/b2d_volume_images/verify.png b/docs/sources/articles/b2d_volume_images/verify.png new file mode 100644 index 0000000000..e1c3763176 Binary files /dev/null and b/docs/sources/articles/b2d_volume_images/verify.png differ diff --git a/docs/sources/articles/b2d_volume_resize.md b/docs/sources/articles/b2d_volume_resize.md new file mode 100644 index 0000000000..7d6790965e --- /dev/null +++ b/docs/sources/articles/b2d_volume_resize.md @@ -0,0 +1,101 @@ +page_title: Resizing a Boot2Docker Volume +page_description: Resizing a Boot2Docker Volume in VirtualBox with GParted +page_keywords: boot2docker, volume, virtualbox + +# Getting “no space left on device” errors with Boot2Docker? + +If you're using Boot2Docker with a large number of images, or the images you're +working with are very large, your pulls might start failing with "no space left +on device" errors when the Boot2Docker volume fills up. The solution is to +increase the volume size by first cloning it, then resizing it using a disk +partitioning tool. + +We recommend [GParted](http://gparted.sourceforge.net/download.php/index.php). +The tool comes as a bootable ISO, is a free download, and works well with +VirtualBox. + +## 1. Stop Boot2Docker + +Issue the command to stop the Boot2Docker VM on the command line: + + $ boot2docker stop + +## 2. Clone the VMDK image to a VDI image + +Boot2Docker ships with a VMDK image, which can’t be resized by VirtualBox’s +native tools. We will instead create a VDI volume and clone the VMDK volume to +it. + +Using the command line VirtualBox tools, clone the VMDK image to a VDI image: + + $ vboxmanage clonehd /full/path/to/boot2docker-hd.vmdk /full/path/to/.vdi -—format VDI -—variant Standard + +## 3. Resize the VDI volume + +Choose a size that will be appropriate for your needs. If you’re spinning up a +lot of containers, or your containers are particularly large, larger will be +better: + + $ vboxmanage modifyhd /full/path/to/.vdi —-resize + +## 4. Download a disk partitioning tool ISO + +To resize the volume, we'll use [GParted](http://gparted.sourceforge.net/download.php/). +Once you've downloaded the tool, add the ISO to the Boot2Docker VM IDE bus. +You might need to create the bus before you can add the ISO. + +> **Note:** +> It's important that you choose a partitioning tool that is available as an ISO so +> that the Boot2Docker VM can be booted with it. + + + + + + + + +


+ +## 5. Add the new VDI image + +In the settings for the Boot2Docker image in VirtualBox, remove the VMDK image +from the SATA contoller and add the VDI image. + + + +## 6. Verify the boot order + +In the **System** settings for the Boot2Docker VM, make sure that **CD/DVD** is +at the top of the **Boot Order** list. + + + +## 7. Boot to the disk partitioning ISO + +Manually start the Boot2Docker VM in VirtualBox, and the disk partitioning ISO +should start up. Using GParted, choose the **GParted Live (default settings)** +option. Choose the default keyboard, language, and XWindows settings, and the +GParted tool will start up and display the VDI volume you created. Right click +on the VDI and choose **Resize/Move**. + + + +Drag the slider representing the volume to the maximum available size, click +**Resize/Move**, and then **Apply**. + + + +Quit GParted and shut down the VM. Remove the GParted ISO from the IDE controller +for the Boot2Docker VM in VirtualBox. + +## 8. Start the Boot2Docker VM + +Fire up the Boot2Docker VM manually in VirtualBox. The VM should log in +automatically, but if it doesn't, the credentials are `docker/tcuser`. Using +the `df -h` command, verify that your changes took effect. + + + +You’re done! +