This article discusses how to clone a failing TiVo hard drive. It doesn’t cover how to upgrade a TiVo drive to a larger drive. It’s meant for people who have a TiVo with a failing hard drive who want to try to save the contents of their TiVo.
(Edit: This known to work for PC computers. According to Colin’s feedback in the comments section, these steps are confirmed to work for Mac Pro computers too — see Colin’s comment for more info.)
Before proceeding, I recommend that you have some basic familiarity with computers, configuring CMOS, and working with the command line before you try these steps. It’s not rocket science, but if you accidentally bork your hard drive, well, it’s not my fault.
Furthermore I assume that you’re already familiar with how to remove a TiVo drive and reinstall it, as well as how to install/remove hard drives in your PC, so I don’t cover that in this article. And always remember never boot Windows with TiVo drives attached — be sure you don’t accidentally boot into Windows after you’re finished with Linux.
When Good Drives Go Bad
About three months ago I upgraded my TiVo Premiere XL drive from 1TB to 2TB using a Western Digital WD20EARX drive. Unfortunately, in the past couple of weeks my WD20EARX upgrade drive started to fail the S.M.A.R.T. tests and began experiencing drive errors (e.g., glitches in recorded shows, spontaneous reboots, and other nasty stuff). I needed to clone it to a new drive before it failed altogether, and ideally preserve its contents and recover any errors along the way.
Someone in the TiVo Community forums said that the best “affordable” upgrade drive for a TiVo Premiere is the WD20EURS. It’s about 10% more expensive than the more common WD20EARX at Amazon, but the EURS is an “AV” drive optimized for best performance with audio/video applications. So I bought a EURS with the intention sending the failing EARX to Western Digital for warranty service (and using the replacement in a computer) after all the TiVo data is cloned.
However, that raised a question… How the heck do I clone my TiVo drive? Will it preserve my TiVo shows and settings? Is there any way to attempt error recovery while cloning?
Fortunately, the answer to the above questions is “yes”!
The Road To Recovery
After some Googling around I found that some folks in the TiVo Community forums had used a program called dd_rescue to clone their failing TiVo drives onto new drives. They did it by creating a Linux boot CD and then putting the dd_rescue software on a floppy drive, then running that.
Since I haven’t owned a floppy drive in about 10 years, I had to find another way.
After more searching I found out two things. First, there’s a newer program called ddrescue (note: no underscore) from GNU that does what dd_rescue does, and (supposedly) does it better. According to the Linux gurus out there, GNU ddrescue is a more efficient alternative to dd_rescue/dd_rhelp. Second, ddrescue is included as part of the free “Ubuntu Rescue Remix” software, which you can download for free and burn to a bootable CD.
To use ddrescue you need to have two identically sized disks, that is, your new drive should be the same size as your failing TiVo drive (or larger). In my case I had two identically sized WD drives, a failing 2TB EARX (source) and a new 2TB EURS (destination). Your destination drive doesn’t have to be blank or even formatted, BTW, since the ddrescue process will overwrite its contents with a byte-by-byte copy of your failing TiVo drive, and it will attempt to recover any errors along the way. The byte-for-byte copy means that when you eventually put the new drive in your TiVo you will have all your shows, season passes, etc. intact.
GNU and Linux To The Rescue
Here are the steps I followed…
Burn a bootable Ubuntu rescue CD on your PC
This bootable CD contains the ddrescue program we’ll use to clone the failing drive. The Ubuntu Rescue Remix download page is here. I used release 12.04. When you burn the ISO onto a CD-ROM disc, be sure to burn it as an ISO and not as a plain file onto the CD. In other words, if you haven’t burned an ISO before, simply follow these steps to burn the ISO onto your CD.
Shut down, then disconnect ALL Windows or Mac OS hard drives from your system
You don’t want to accidentally boot Windows with a TiVo drive attached.
Hook up the TiVo source and destination drives
- The “source drive” should be connected to the first SATA connector (when you boot Linux it will show up as /dev/sda in Linux) — this is the failing drive with TiVo software on it that you want to clone
- The “destination drive” should be connected to the second SATA connector (shows up as /dev/sdb) — this is the new, blank drive
- The only devices that should be connected are your CD-ROM drive, your failing TiVo source drive, and your destination TiVo drive
Restart, then configure your PC’s BIOS
- Set the boot order so that your CD-ROM is your first boot device
- Set the drive type to AHCI for best speed (i.e., SATA drives will be used as SATA, not as legacy/IDE)
- Save the CMOS settings when done
Put the Ubuntu CD in the CD-ROM, then reboot. When Linux begins to boot you’ll see a “boot:” prompt. Simply hit <Enter> at the boot: prompt. The system slowly boots and leaves you at a Linux shell prompt (i.e., the Unix command line). Note: Depending on the hardware in your system, you may get some warnings during the boot, but as long as you don’t get an error you should be fine.
Switch to the root user
At the shell prompt, type:
The prompt on your command line may change, this is normal. Now you have Unix super powers, so be careful.
Double check your source and destination drives
Assuming that the two drives are different models and/or sizes, type this at the shell prompt to confirm that the source disk (/dev/sda) is in fact your SOURCE drive:
hdparm -i /dev/sda
and for the DESTINATION drive:
hdparm -i /dev/sdb
Confirm the drive types and sizes match your expectations for the types for your source and destination drives. If /dev/sda is not your source drive and /dev/sdb not your destination, then power off, swap the SATA cables between drives, reboot, and try this step again.
Start the cloning process
You invoke the ddrescue program by typing this EXACTLY AS SHOWN:
ddrescue -f -n /dev/sda /dev/sdb tivo-rescue.log
Remember in Linux that lower case matters. Be sure to use that “-n” option or the recovery can literally take weeks to complete if you have a lot of errors (it gets stuck in “splitting failed blocks”). Depending on the size of your drives and the number of errors the ddrescue process can take a VERY LONG TIME to run, anywhere from 5 hours to 24 hours is not uncommon. Do not power down or otherwise disturb your computer during the cloning process.
Send In The Clones
After the clone operation completes, switch off the computer and install the destination drive into your TiVo. Hook the TiVo up to your TV as normal. We’re almost done.
When you first start your TiVo, IMMEDIATELY do a Kickstart 57 (i.e., MFS disk check/repair). This will fix any disk errors that resulted due to any missing data from the source drive. Remember kickstarting only works with a regular TiVo IR Remote, NOT the TiVo Bluetooth Slide Remote.
Here are the steps for the kickstart:
- Power on the TiVo and wait for the green light to come on.
- When the yellow/amber lights flash irregularly, hold the PAUSE button on the remote. You will have approximately 10 seconds to do this.
- Release the PAUSE button when the yellow/amber and red lights come on.
- You will have approximately ten seconds to press 57 on the remote control.
- If you were successful, the blue light will come on and the TiVo will reboot. Do not stop the TiVo rebooting. This is normal.
If you were successful with the kickstart, when the TiVo reboots you’ll see a green screen that says “TiVo has detected a serious problem and is attempting to fix it”. The screen says it may take up to 3 hours, but in my experience always seems to take less than a half hour. It probably depends on how many errors it finds on your drive. Once the TiVo is done it will automatically reboot itself again.
Once that’s done you should be all set to enjoy your newly repaired TiVo.
I hope you found this guide useful.
If you need more help with ddrescue, you can find the ddrescue manual online here:
You should be able to do all the above on a Mac Pro or iMac too, although I haven’t tested it. On a Mac, you don’t need to configure your BIOS, so the steps are the same except for skipping the BIOS configuration. When it comes to booting from the CD-ROM drive, just hold down the ‘C’ key when you hear the Mac boot chime to make the Mac boot from the Ubuntu CD. Like I said, I haven’t tested this, but it should work — please drop me a line if it works for you with a Mac.