SSDs and You: My Dual-Drive Setup
I’ve been running a dual-drive setup on my new MacBook Pro for the past two months. Here’s a bit of info about how I’ve got it set up, and how it’s working for me
A quick introduction to SSDs
The vast majority of a HD’s time is spent traveling from bit
A to bit
B: reading or writing small amounts of data is fast, but getting the read/write heads to where it needs to be takes forever, in computing terms.1 Sets of bits that are farther apart on the platter take longer to reach: for example, duplicating a file on one disk takes much longer than copying it to another disk, because the heads have to move to where the file is, read some bits, move to where there’s free space, write some bits, and repeat hundreds of times.
SSDs have a constant access time, regardless of what bits you ask it to read or write: reading two physically adjacent blocks of a song is just as fast as reading a block of data for an application followed by a block of data for a download.
Only big media files, like pictures, music, and videos, can typically be sequentially read and written.2 The rest of the system, from OS libraries to application bundles and preferences, are scattered across the disk. When you launch an app, OS X tries in a very short amount of time to read the app’s binary, open any libraries the app needs to run, load any additional app resources it needs, and read its preferences and other application data. None of those bits sit near each other on the drive, so it takes a lot of back-and-forth hard drive seeking to get everything read in and ready to go. SSDs don’t have to pay any time penalty for randomly choosing two bits to read, so app launches are lightning fast.
The setup nitty gritty
I did this to my mid-2009 15″ MacBook Pro. I upgraded the built-in HD to a 500 GB, 7200 RPM Seagate drive. I bought an Optibay3 and an 80 GB Intel X25-M and installed them myself. The install was easy: take 10 screws out of the bottom case to expose the guts of the laptop, and remove three more inside to swap out the optical drive for the SSD carrier. Close it back up, format the drive, and you’re ready to go.
Why two drives?
I wanted an SSD for the ludicrous speed increases, but I have a few hundred gigabytes of pictures, videos, and music, and no one manufactures (affordable) 500 GB SSDs just yet. Instead of moving lots of that media off the machine and onto an external drive, I’ve split my filesystem setup between the two drives. I moved as many of the more-randomly-read bits onto the SSD as possible (the base OS,
/Applications, and especially
~/Library), and kept my user’s Music, Movies, Pictures, Desktop, and Downloads on the spinning platter drive, where bit storage is cheap and longer seek times don’t matter. By keeping the entire OS and the vast majority of my user’s home directory on the SSD, boot times, login times, and app launch times are all largely the same as an SSD-only system, but I still have plenty of capacity for large downloads of videos, pictures, or music, and can still work and use all my media while on the go. It’s the best of both worlds.
Getting an already-installed OS properly copied to the SSD was tricky: I hacked a SuperDuper script to copy over my 500 GB boot volume, minus the above paths and a few others, and symlink over what I didn’t copy. It was tricky, and this is a good time to make sure you’ve got an up-to-date SuperDuper backup of your boot volume somewhere: I had to restore the 500 GB drive from backup once when I typo’d a path and it thought I meant
/Music and not
A special note for anyone wondering about how OS X installs handle a dual-drive setup: I haven’t tried a Leopard Archive and Install on this machine, but I can’t think of any reason it wouldn’t work, as long as you check the box to preserve Users. On Snow Leopard, I’ve done several OS upgrade installs since setting this up, and have had zero problems.
Results! I demand results!
I initially didn’t copy my user over at all, but the system wasn’t much more responsive than a spinning-platter setup: though apps and the base OS were on the SSD, there was still lots of drive thrashing when loading preferences and application data. The biggest speedup in login and app launch time came from putting
~/Library on the SSD:
~/Library/Application Support and
~/Library/Preferences are hit heavily by apps on launch. I also moved over all of
~/Music except for the actual iTunes Music folder: having the iTunes Library file on the SSD greatly improved iTunes launch times and song metadata updates.4
Right now, only a few specific applications access the 500 GB drive: iTunes (and only when playing songs), Aperture, and any copy operations to/from
Since most of the files used by my system are on the SSD,
sudo pmset -b disksleep 1 is my new best friend. This Terminal command sets the disk sleep timeout while on battery to 1 minute: most of my time on battery is spent with the SSD powered and the Seagate drive spun down. I’ve seen a big improvement in battery life the past weeks as a result.5
Was it good for you too?
This configuration was a bit tricky to get set up, but it was very much worth it. OS boot, login, app launches…almost every daily operation on the machine is lightning fast,6 and I didn’t have to make any compromises with what music or photos I keep on the machine. From now on, I’ll be making sure that any machine I use day-to-day as my primary system is running on an SSD.
- HD seek and rotational latency times are usually measured in milliseconds: a ten millisecond seek time burns 20 million CPU cycles on a 2 GHz processor. Entire empires can rise and fall in the time it takes those platters to spin and the read/write heads to move [↩]
- assuming no file fragmentation on the drive [↩]
- Fraser Speirs got a MaxConnect kit for his setup [↩]
- the computer seems to write changes to the library file at the same time as the actual media files. Having them on separate drives eliminated the typical disk thrashing this causes [↩]
- If you install the Developer Tools, check out Spindown HD in
/Developer/Applications/Performance Tools/CHUD/Hardware Tools/for an easy way to know if the drive is asleep or spinning. [↩]
- even OS reinstalls! [↩]