Vagrant, Time Machine, and waiting forever for a backup

For some reason, moving to the new MacBook Air hasn’t been very successful. My Alfred spotlight is broken, Apple Mail slows to a crawl for no good reason even though everything is in the cloud, and I have a \<50% success rate of backing up my Time Machine during my workday. Basically if it doesn’t complete before lunch, it isn’t going to finish at all.

That last one seems to be well within the realm of what’s feasible. I mean why is it backing up 15GB of new files each day and why is it when I really get working the last 2GB never seems to complete? Not to mention that this 5TB drive I purchased four years ago to back up what is only a 500GB SSD (was smaller in years back) is now starting to appear full.

Well I think I figured it out. I’ve been using Vagrant for the last 5 years to build out virtual machines for development and each of them is a single (very large) virtualbox file that needs to be re-imaged every time and is constantly changing if the machine is up during the backup process.

After some research here are some suggestions on what to exclude from your time machine backups

Working scratch folders:

Things like ~/.Trash and ~/Library/Caches should automatically be excluded by Time Machine in general, but for me, I use ~/Downloads as scratch space for stuff that I don’t care if I lose. If it’s important, I usually drag that to desktop, so I added that. You can add something similar

Cloud files

I added ~/Dropbox because that stuff will be built from Dropbox, and Time Machine or migration restores will just confuse the backup system. If I used Google Drive, I’d probably add that too.

Virtual machines and other dev related environments

For me that’s ~/.vagrant.d and ~/VirtualBox VMs where vagrant downloads the boxes and where, by default, it puts the VirtualBox VMs. The actual boxes that I might image to do Windows/IE development are manually created and imaged in ~/Documents so there is no need to exclude those. If you want to keep your plugins then save ~/.vagrant.d/boxes only.

I also added ~/Library/Containers/com.docker.docker because sometimes I did Docker development and that’s where those instances are.

Also if you have a standard place where you put Python virtual environments with virtualenv you should probably add that too. I don’t develop on localhost anymore so that isn’t the case for me.

Local software caches

I added ~/.gem for Ruby and ~/.npm for NodeJS. I’d probably look into what I can torch from rbenv and rvm but I no longer do local Ruby development, but if you do, add those to your checklist.

Games

I don’t have this on my work computer, but on my home one, I added ~/Library/Application Support Steam/steamapps because those are big files that are downloaded from the internet anyway. When I get home, I’ll have to make sure that sort of thing wasn’t moved into /Users/Shared.

Unknown unknowns

I probably should figure out where Ulysses puts its files because every time I do Migration Assistant I have unresolved conflicts which take forever to clean up. It’s not a big deal though since almost all copies are actually the same file.

Know of any other things I need to add?

Thoughts on “Thoughts”

Now that this site has been down for a month (Thank you, SARSxSW), I tried to see restart this blog with a deep thought.

I couldn’t come up with anything.

So instead, I’ll talk about the tech news. Recently a lot has been going on about Steve Jobs latest missive: “Thoughts on Flash” to which, Adobe’s CEO quickly responded to in the Wall Street Journal.

Instead of rushing to Apple’s defense here, I thought I’d provide some thoughts on these “thoughts.”

Continue reading about three thoughts after the jump.

Join Kiva for a Developer Drink-up

Image:Kiva.org logo.svg

Halle is interning at Kiva, which, given her personality, I figure is her dream internship.

Kiva is a microfinance site for the poor that allows anyone to give flat-rate microloans via PayPal. As a coincidence of the “I seem to have a lot of cash” and my New Year’s resolution to be a more responsible person, I’ve recently started to put a tiny fraction of my income into Kiva. You can view my lender page here to see that I currently participate in 17 microloans.

I mention all this because Kiva will be sponsoring a Developers Happy Hour this Thursday at their headquarters in San Francisco. Considering I give 5% of my money lent back to Kiva, I’m going for the drinks. 🙂

(Find out more about the concept from Muhammad Yunus’s Nobel lecture, the FrontLine program on social entrepreurship, conservative columnist Nicholas Kristof’s editorial in the New York Times, and the books Banker To the Poor, and Creating a World Without Poverty.)

Continue reading about Moneywatch.com after the jump