Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use a custom Vagrant box for direct-lvm support #249

Merged
merged 1 commit into from
Oct 27, 2014

Conversation

ironcladlou
Copy link
Contributor

This change is to improve the single-VM developer experience. Currently, the changes are only for the VirtualBox provider. A new base box hosted on mirrors.openshift.com is used.

Changes between the old and new base box:

  • A separate 20GB LVM volume group with a pair of direct-lvm logical volumes is configured for Docker use.
  • Git, Docker, and Go are pre-installed as essential tools.
  • The NAT adapter uses virt-io.
  • The vagrant user is properly configured for password-less sudo and no-tty access.

Developer experience improvements:

  • Time from zero to hacking improved (tested on a 2.5ghz i5 w/ 8GB RAM and SSD, assuming the box files are already downloaded and the VMs don't yet exist):

    Current:
     vagrant up:      6m
     build-images.sh: 5m47s (5min load avg: 0.86)
    
    New:
     vagrant up:      39s
     build-images.sh: 4m18s (5min load avg: 0.46)
    
  • Docker is pre-configured to use direct-lvm and xfs for storage, improving performance by eliminating filesystem and network overhead caused by the direct-loop approach (resulting in reduced IO waits).

  • Separate logical volume enables further experimentation with other storage approaches (e.g. btrfs) - just replace the volumes in the docker storage group while the VM is online and reconfigure docker (this could be incorporated into provisioner options).

  • GOPATH is pre-created with /home/vagrant/go/{bin,src,pkg} which solves the Vagrant mount/provisioner chicken-and-egg problem when mounting a host GOPATH/src into the guest (previously, GOPATH was root-owned, preventing standard go usage within the VM).

@ironcladlou ironcladlou force-pushed the vagrant-direct-lvm branch 6 times, most recently from fa85f8e to cacbe9e Compare October 23, 2014 14:55
Use a home-grown base box for development which brings improved performance,
flexibility, and initial developer experience.
@ironcladlou
Copy link
Contributor Author

@smarterclayton independent tests performed by @pweil- and @jcantrill to verify it can come up from scratch (tested on OSX and fc20). Advice on any other testing that could be done?

@smarterclayton
Copy link
Contributor

I'll give it a try as well, thanks for doing this.

@ironcladlou
Copy link
Contributor Author

@bparees would you also be willing to try this, perhaps w/ the e2e tests?

@mfojtik
Copy link
Contributor

mfojtik commented Oct 24, 2014

LGTM, this improves the download speed for Vagrant image greatly and the Docker works noticeably faster. My build-images.sh is 3m41.854s. Great job!

@bparees
Copy link
Contributor

bparees commented Oct 24, 2014

worked for me as well (no performance data points collected)

@VojtechVitek
Copy link
Contributor

LGTM and works for me. Thanks!

@smarterclayton
Copy link
Contributor

Will merge on Monday if no one else hits issues

On Oct 24, 2014, at 8:15 PM, Vojtech Vitek notifications@github.com wrote:

LGTM and works for me. Thanks!


Reply to this email directly or view it on GitHub.

@smarterclayton
Copy link
Contributor

LGTM [merge]

@openshift-bot
Copy link
Contributor

Origin Merge Results: SUCCESS (https://ci.openshift.redhat.com/jenkins/job/merge_pull_requests_openshift3/254/) (Image: devenv-fedora_279)

@openshift-bot
Copy link
Contributor

Evaluated for origin up to bf1f587

openshift-bot pushed a commit that referenced this pull request Oct 27, 2014
@openshift-bot openshift-bot merged commit b16d81e into openshift:master Oct 27, 2014
@ironcladlou ironcladlou deleted the vagrant-direct-lvm branch October 27, 2014 16:38
marun pushed a commit to marun/origin that referenced this pull request Jun 1, 2016
danwinship pushed a commit to danwinship/origin that referenced this pull request Jun 24, 2016
SDN setup check fix and V(5) logging
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants