We recommend storing your repository data on a separate block device to make backups and future expansions easier. You can also reduce I/O overhead by keeping this block device physically separate from your root partition.

Once you have added a new block device, your GitHub Enterprise instance will

  1. detect the block device;
  2. format the device if it is unformatted;
  3. copy the content of /data/repositories from the VM's root partition to the block device; and
  4. mount the block device at /data/repositories.

Note that any existing data on the block device will be preserved.

Edit your VM settings

  1. Make sure that you have shut down your virtual machine.

  2. Select your VM in VirtualBox and then click the Settings button: VM powered off

  3. Select the Storage tab and then click the Add Attachment button: Storage tab

  4. Select Add Hard Disk: Add Hard Disk

  5. When asked whether you would like to create a new file or select an existing one, choose Create new disk: Create new disk

  6. When asked for a file type, choose VMDK (Virtual Machine Disk): Choose VMDK

  7. When asked whether the new virtual hard drive should be allocated dynamically or at a fixed size, choose Fixed size: Choose Fixed size

  8. Choose a name and size for the new virtual hard drive: Name the virtual disk

You'll see a progress bar as the disk is created. Once it's done, the new disk will show up in the list under your SCSI controller: Storage tree

Configure GitHub Enterprise to use the device

Once you've completed the steps above, start up your VM and go to the Management Console. In the Repository storage section, the Block device option should now appear with the label "recommended" instead of "no device detected".

Select block device

Choose the Block device option. A dropdown menu will appear, showing any detected block devices. If you have only added one disk, it should be the only one in the list.

Block device list

Danger: Once you have configured a GitHub Enterprise instance to use a new block device, do not re-configure it to use the root filesystem. Any attempts to do so will make your instance fail to boot properly.

Choose the correct disk and then click Save settings at the bottom of the page.

You'll be taken to the configuration page. It should take less than 20 minutes to configure the drive, but it could take longer if you've added a very large drive.

Saving configuration

If the process takes longer than 20 minutes, check http(s)://[hostname]/setup/config.log?chef=1 to see whether there was an error formatting your disk. If there was, please contact support.