“I knew every chip in Bobby s simulator by heart; it looked like your workaday Ono-Sendai VII, the Cyberspace Seven, but I d rebuilt it so many times that you d have had a hard time finding a square millimeter of factory circuitry in all that silicon.”–William Gibson, “Burning Chrome”

I sometimes joke that a computer really isn’t mine until I open up its guts and change out parts. In the past month, I did that twice to my two-year-old HP Omen laptop, Kingswood.


The first was a more urgent matter. The battery had started to bubble, literally pushing up they keyboard. Aside from making typing a bit difficult, it also was a dangerous situation–the battery could literally explode. All advice on the internet was to stop using the laptop now. Do not pass “Go.” Do not collect $200.

With the Maintenance and Service Guide and a battery from Amazon, this was not too difficult a task. Not only is my keyboard flat again, but my battery life went from half an hour to more on the order of 3-4. It’s like a new laptop.

Hard Drive

The other task was more optional, but I knew, long term, would make my life easier. The laptop came with a 128 GB SDD hard drive as its boot drive, loaded with Windows 10. I resized it, cutting it in half, with the other partition booting to Ubuntu. Most of the time, I’m using Linux, but there are a few applications, such as The Sufferfest and Zwift, that only work in either Windows or OS X.

What I discovered was that, while the base Windows OS fit, and applications would fit in that fifty-ish gigabytes, and I could put applications on the secondary spinning disk, I kept running out of space on the main drive. It looks like temp files or something kept getting written there, and the much-needed OS updates kept eating space as well. I might have been able to figure out a way to tune the OS and make it work, but, frankly, I didn’t have the patience for an OS I only occasionally used, and I was concerned I was attacking a symptom rather than a root cause.

I decided to replace the SSD. Prices were coming down, so it seemed like an easy choice. I wanted to wait until I could put a full terabyte in there–with hard drives, physically replacing the device is easy (even in a laptop); transferring data around is the hard part. It make sense to do it as infrequently as possible.

I half-expected to have to reload each OS, patch it up to date, transfer my data, and dial in the configuration. This was an hours-to-days sort of deal, much of it non-interactive. You kick off something, walk away, then come back in a few hours. I had some PTO I needed to burn, so I figured it would be a good project to have simmering in the background.

However, there were plenty of tools that were there to help me make this work. The process actually proved to be accomplished, end-to-end, in one evening while making some bread.

Replacing the SSD and Copy the Data

  1. Procure the materials. Since the hard drive (HDD) I wanted to replace was in the new M.2 form factor and hyad a SATA interface, I went with a Crucial MX500 series drive, purchased from MicroCenter. While I was there, for $16, I picked up an M.2 SATA USB enclosure. this would let me attach the drive as a USB drive. My intent was to use the old drive as an external disk for backups or whatever, but it proved to be quite labor saving.
  2. I put the new drive in the enclosure, and verified my laptop could see the drive OK. I just wanted to make sure everything worked.
  3. On a random thumb drive I had sitting around my desk, I created a live Clonezilla image. Clonezilla is a disk cloning application, similar to Norton Ghost I used back in the day. It took a bit of tinkering to get it to work–I had to make sure the thumb drive had a partition (so it could be /dev/sdc1), and had a master boot record (i.e. make sure it was bootable).
  4. Boot to the Clonezilla image, and plug in the new M.2 drive. You will do a disk-to-disk clone, which meant the disk was being copied at a block level directly between the two drives. This took about 30-40 minutes.
  5. I test-booted to the new drive as a USB drive once or twice. It took a bit of playing with the boot menu, but I was able to confirm everything appeared to be copied.
  6. Crack open the case and swap the drive out. I put the old drive in the USB enclosure, but I did not reformat it.
  7. Boot into each OS, and verify it was coming up.

Resize the Partitions

The next hurdle was resizing the partitions. In the original configuration, the Windows OS was right next to the Ubuntu one, so I couldn’t just extend the partition. On the new drive, everything was right up next to each other.

A tool called GParted would do the job for me. It can move and resize partitions for a variety of file systems. However, I did read that occasionally it would mess up a Windows partition–not so bad data was lost, but that some recovery was needed. However, I figured out a way to manage that.

At the same time, the Windows disk administration program would only extend the OS (“C:”) partition to adjacent empty space. I had none at this point.

  1. Create a GParted thumb drive, similar to the Clonezilla one above.
    • I used the same thumb drive for this, reformatting it. If I had to do it again, I would have made a separate thumb drive for each application. So long as I didn’t mess with the old drive, I could always start over. Not having to create a new Clonezilla drive would have made that easier, but things worked out, and it wasn’t necessary.
    • It would have been nice to have Clonezilla and GParted on the same live image.
  2. Boot to the GParted image. This is necessary, and none of the partitions on the target drive can be mounted while doing this work.
  3. Move the Ubuntu partitions towards the end of the drive (to the “right” on the GParted GUI). Apply the changes–it took about 45-60 minutes, and, for about half of that time, didn’t look like it was doing anything. Don’t Panic!
    • I had to move a swap partition and the main partition.
    • The key thing was to make sure there is free space right next to the Windows partition.
    • This is also where I resized the Ubuntu partition, making it ten-fold bigger.
  4. Once done, boot to Ubuntu, and make sure everything works.
  5. Boot to Windows. Launch disk administrator and extend the Widows partition to use the empty space left between it and the Ubuntu partition.
  6. Reboot into Ubuntu to make sure everything still works OK.

My thinking was that the native disk administrator would not impact Windows, as it was performing a standard task. Moving Ubuntu with another app was OK. This proved to be the way to go.

Once I’m confident the new drive is 100% (which may not be until after a few Sufferfest sessions), I’ll wipe the old drive, and use it for extra offline storage.

How Much Drive Space Should a Laptop Have?

When I first started in my current company, most servers had less than 36-54 GB of raw storage (less, once RAID was activated). I don’t remember for certain,but laptops typically had 10-20 GB–my first personal laptop was purchased eight years later, and came with a 60 GB HDD (and options maxed out at twice that).

In our data center then, 1998, we had an EMC Symmetrix, and enterprise storage system. Multiple servers could be assigned disk space on it. It was designed to be highly available, and had some other features (on-the-fly copies of volumes, etc.). I was told it was a 1 TB system, and was mirrored (so it effectively had 2 TB inside of it). It basically had shelf after shelf of disk, in a unit the size of a tall refrigerator. Having 2 TB in a laptop amazes me.

The question I’ve been mulling is, how much storage should I have local to my laptop. Disk is cheap enough that I can off-load much of it to disks I can keep at home, and cloud storage is common enough and connectivity ubiquitous enough that data can be accessed remotely.

At the same time, a laptop, being a portable device, is more subject to being bumped around, stolen, or other situations that may result in the drives being unavailable to me. The sorts of data I keep–pictures, important documents, etc.–are not the type I want to keep in one place or on one drive that may fail. I don’t want to keep all my eggs in that particular basket.

I don’t want to say “never”–60 GB seemed like a lot in 2006–but I can’t see adding more disk to this laptop, or seeking out more than 2 TB on some future laptop, for the simple desire for space (as opposed to break/fix or “that’s just what it comes with). I’m more likely to enhance my storage that isn’t local to the laptop, either in the Cloud or on some personal NAS device. I would want to get some of my key data files in to more resilient storage.

This was orignally on the WordPress version of this blog. As I had the Markdown file it’s based on, I figured I could put it on this site as well. Enjoy!