Backup, Upgrade, Add, or Replace TiVo drive using MFSTools

From DVRpedia

Jump to: navigation, search

Contents

Overview

This page describes how to use MFSTools to backup the hard drive of your TiVo (which saves a complete backup of the TiVo software and all of your season passes). Additionally, this page describes how to replace your existing drive with a larger hard drive, how to replace your existing drive with two larger hard drives, and how to expand your existing drive to add a second drive.

Previous Steps that Must Be Completed

  • Create TiVo Linux Boot CD
  • Acquire a Drive Bracket, IDE cable, and power cable splitter (only if you are adding an additional drive to a Series 2 TiVo)
  • Remove Drive(s) from TiVo
  • Install TiVo drive(s) and a spare FAT32 backup drive in your PC

Getting Ready to Boot to the Linux Boot CD

  • Make sure your main Windows drive is disconnected from your computer (see warnings elsewhere on this site)
  • Place the Linux Boot CD in the CD Drive
  • Turn on the computer
  • Check to make sure all of the drives show-up on the initial BIOS boot screen
    • To see more drive details, hit the key required to enter BIOS setup to see more information (usually Del, F1, or F10; it will say on the screen)
    • If you see a full-screen logo during boot and there are no details, either hit the required key to enter setup or try hitting ESC to show BIOS boot info.
    • If this does not work, you can check drive connections after the computer boots to the Linux CD (described in the next section)
  • The computer should boot to the Linux CD but if it does not:
    • If it does not boot to the Linux CD, you will need to enter the BIOS setup screen and change the boot device priority. The BIOS setup screen is the screen that first displays when your computer boots.
    • Find the "Boot Device Priority" setting; move the CD-ROM device to the top of the list.

Using the Linux Boot CD

After your PC has booted to the Linux boot CD, you are ready to begin the backup and upgrade process. Check that the drives were detected properly by hitting Shift+Page Up about 6 times. You will see info for hda, hdb, etc. If everything looks OK and all of the drives are showing up as expected, hit the Enter key at the boot: prompt. You are now ready to run one of the procedures listed below.

Backup

Create a TiVo drive Backup Image and save it to a FAT32 drive (does not keep recordings)

Mount the FAT / FAT32 drive that will hold the backup image. This command allows Linux to read from and write to the FAT/FAT32 hard drive on which the backup will be stored:

mkdir /mnt/dos
mount /dev/hdc1 /mnt/dos

This assumes that your FAT or FAT32 drive is installed as /dev/hdc (Secondary Master) and the partition 1 on that drive (/dev/hdc1) is the FAT or FAT32 partition.

Now that the drive is mounted, perform the backup from the TiVo drive to the FAT/FAT32 drive:

mfsbackup  -f 9999  -6so  /mnt/dos/tivo.bak  /dev/hda

The backup images will be require about 1.5GB of free space.

Once this command is complete, you are finished with the backup. You can now shut down the computer if you are finished.

Restoring a Backup image, Expanding a backup to multiple drives

Restore a Backup image to a Single Drive TiVo

Mount the FAT/FAT32 hard drive that contains the TiVo image:

mkdir /mnt/dos
mount /dev/hdc1 /mnt/dos

Use the following command to restore the backup to the single drive. Note, everything on the target drive will be erased!

mfsrestore  -s 127 -r 4 -xzpi  /mnt/dos/tivo.bak  /dev/hdc

Restore a Backup image to a Dual-Drive TiVo

Mount the FAT/FAT32 hard drive that contains the TiVo image:

mkdir /mnt/dos
mount /dev/hdc1 /mnt/dos

Use the following command to restore the backup to the single drive. Note, everything on the target drives will be erased!

mfsrestore  -s 127 -r 4 -xzpi  /mnt/dos/tivo.bak  /dev/hdc /dev/hdb

Copy TiVo software and All Recordings to New Drive(s)

Copy from Original to New Drive - Keeping Recordings

It is recommended that you create a backup before performing this action. This procedure does not require that a FAT/FAT32 drive be installed on the PC. It backups up directly from the original TiVo drive to a new replacement drive. It will take several hours to copy all recordings to a new drive (depends on computer speed as well as the number of recordings on the existing drive.) Note: the new drive must be at least as large or larger than the original drive.

mfsbackup  -Tao  -  /dev/hda | mfsrestore  -s 127 -r 4 -xzpi - /dev/hdc

This assumes that the original TiVo drive is connected to /dev/hda and that the new drive is connected to /dev/hdc.

Copy from Original to 2 New Drives - Keeping Recordings

It is recommended that you create a backup before performing this action. This procedure does not require that a FAT/FAT32 drive be installed on the PC. It backups up directly from the original TiVo drive to a new replacement drive. Note: the new drive must be at least as large or larger than the original drive.

mfsbackup -Tao - /dev/hda | mfsrestore -s 127 -r 4 -xzpi - /dev/hdc /dev/hdb

This assumes that the original TiVo drive is connected to /dev/hda and that the new primary drive (TiVo A drive) is connected to /dev/hdc and the new secondary drive (TiVo B drive) is connected /dev/hdb

Copy from Original to New Drive – Do Not Keep Recordings

It is recommended that you create a backup before performing this action. This procedure does not require that a FAT/FAT32 drive be installed on the PC. It backups up directly from the original drive installed in the TiVo to a new replacement drive. Since recordings are not copied, this will complete in a matter of minutes. Note: the new drive must be at least as large or larger than the original drive.

mfsbackup -6so - /dev/hda | mfsrestore  -s 127 -r 4 -xzpi  -  /dev/hdc

This assumes that the original TiVo drive is connected to /dev/hda and that the new primary drive (TiVo A drive) is connected to /dev/hdc .

Copy from 2 Original Drives to 2 New Drives - Keeping Recordings

This is a more complicated process, because it involves 4 hard drives and 1 CD-ROM and most computers have only 4 IDE channels. However, it is possible to perform this upgrade assuming that your TiVo can handle adding 2 additional partitions (the max is 17??? partitions.) This multip-part process involves using the linux DD command to

  1. Connect the CD-ROM drive, the old TiVo A drive and new TiVo A drive to the PC
  2. Use the DD command on a linux boot CD to copy the original TiVo A drive to the new TiVo A drive.
  3. Shutdown
  4. Connect the CD-ROM drive, the old TiVo B drive and new TiVo B drive to the PC
  5. Use the DD command on a linux boot CD to copy the original TiVo B drive to the new TiVo B drive.
  6. Shutdown
  7. Optional: Install the new A and B drives in the TiVo to make sure they work. You should show the same recording capacity as before.
  8. Connect the CD-ROM drive, the new TiVo A drive and new TiVo B drive to the PC
  9. Use mfs-add to expand both the New A and B drives (see details below)
  10. Reinstall in your TiVo, you should see the new, larger capacity.

Expand to Fill a New Drive/Add New Drives

It is recommended that you create a backup before performing this action. If you have a single TiVo drive and want to add a second drive to it, run the following command. It will expand the existing image on the TiVo drive to fill 100% of the space available on both of the drives.

mfsadd  -x  -r 4 /dev/hdc  /dev/hdb

This assumes that /dev/hdc is the existing TiVo A drive and that /dev/hdb will be the new TiVo B drive.

Troubleshooting Problems with Multiple Large Drives (larger than 130 GB)

Some computers have problems when drives larger than 130 GB are both installed on the same IDE channel (for example a 400GB drives installed on both /dev/hdc and /dev/hdd.) For this reason, the instructions above show new TiVo A drives installed on /dev/hdc (secondary IDE channel) and new TiVo B drives installed on /dev/hdb (primary IDE channel).

If you are copying software and recordings from a large TiVo drive (130GB+) to two other Large drives, it may be necessary to do this in the following sequence:

  1. Copy from original TiVo drive to one large drive
  2. Shutdown, disconnect original TiVo drive from /dev/hda and connect new TiVo B drive to /dev/hdb
  3. Boot up and expand the new TiVo A Drive (/dev/hdc) to occupy both /dev/hdc and /dev/hdb

How to Shut down the PC

Type the following commands to unmount all drives and reboot.

umount -f -a -r

Then press CTRL+ALT+DEL to begin the shutdown process. Turn off the computer as soon as it is finished shutting down and starts to reboot.

Special Procedures

Speeding-up Transfers Between Drives using DMA

DMA (Direct Memory Access) mode allows for higher speed transfers between IDE drives. It can cause problems in some situations but generally it works without incident. It is especially useful when performing a backup/restore and keeping all recordings.

DMA is not enabled by default. Use the following command to enable it. Note: it should be enabled for both the source drive(s) and the target(s); otherwise there will be no significant speed increase.

hdparm -d1 /dev/hda
hdparm -d1 /dev/hdc 
hdparm -d1 /dev/hdd


Backing-up an Entire Hard Drive using the Linux DD command

dd is a common Linux/UNIX program with the primary purpose being low-level copying of data. dd is commonly used to copy regions of raw device files, e.g. backing up the boot sector of a hard disk. Because dd can copy entire partitions or disks (this is more due to Unix providing access to these devices than the functionality of dd per se), it is used in computer forensics when the contents of a partition need to be preserved in a byte-exact copy. Using cp would not be enough, since data from deleted files that may still be present on a disk are not visible through the file system interface.

Warning: It is jokingly said to stand for "destroy disk" or "delete data", since, being used for low-level operations on hard disks, a small mistake, such as reversing the if and of parameters, may accidentally render the entire disk unusable.

A backup using DD is very time consuming, taking up to 2 days to complete for 750 GB drives. It does not create a small backup file but rather makes a sector-by-sector copy of the original hard drive. Please note, the destination drive must be at least as large as the source drive. A backup using MFS Tools is recommended but this is an alternative method that can used if MFS Tools does not work or if the user requires an exact partition by partition duplicate (which MFS Tools does not provide.)

Before using DD to copy from one drive to another, it is recommended that you use MFS Tools to create a small backup image of the original TiVo drive. Store this image on a different drive so that it can be used for restoration in case you mess-up the DD command.

To backup a drive using DD:

  • Install the original and new drives in your PC
    • This example assumes the Original TiVo drive is connected to Secondary Master (/dev/hdc)
    • This example assumes the new drive is connected to Primary Slave (/dev/hdb)
  • Boot to the Linux boot CD
  • Enter the following commands (if you connected the drives to different IDE channels, alter the commands accordingly)
dd  if=/dev/hdc  of=/dev/hdb  bs=1024k
  • If the command above gives an error, and only if, try using the following command instead:
dd  conv=noerror,sync  if=/dev/hdc  of=/dev/hdb  bs=1024k

More details about the commands above:

  • if= specifies the Input File
  • of= specifies the Output File
  • bs= specifies the Block Size for each read/write operation
  • conv noerror specifies to ignore reading errors and continue
  • conv sync specifies to pad every input block with null bytes if it is shorter than the size specified

Some users have experienced significant speed increases (10x) by using raw devices when backing-up a drive. Below is an example of a backup command using dd and raw device locations within Linux to copy a drive. Be sure you know which hard drive is connected to each raw device location. This isn't a thoroughly tested as the method above; use it at your own risk.

dd if=/dev/rdisk2 of=/dev/rdisk3 bs=1024k

Creating a Larger Swap Partition

Some people believe that swap partitions larger than 127MB is necessary if total drive capacity exceeds 250GB. In general, this has been proven to be unnecessary. However, if you want to create a lager swap partition, these are the step you'll need to follow.

The -s switch used in the mfsrestore program determines the size of the swap. However, the partition table has to be modified if a swap size greater than 127MB is specified. So this is a two step operation. People that use larger swap partitions generally follow the rule-of-thumb that 1MB of swap is needed for every 2GB of total drive storage space. So, for a TiVo with 500GB total drive space, the swap size would be 250MB.

Step 1: Perform MFS restore with a Larger Swap Setting For a 500GB TiVo, you'll create a larger swap partition by using a different value for -s. So, if the instructions above say to use this command:

mfsbackup  -Tao  -  /dev/hda | mfsrestore  -s 127 -r 4 -xzpi - /dev/hdc

You would instead use this command:

mfsbackup  -Tao  -  /dev/hda | mfsrestore  -s 450 -r 4 -xzpi - /dev/hdc

Step 2: Use TPIP to Fix the Partition Now use the tpip program on the Linux Boot CD to fix the new swap partition. The exact command depends on the version of tpip being used. Type the following command:

tpip --version

Based on the version reported above, run one of the following commands: tpip V1.1:

tpip --swapped -s /dev/hdc

where /dev/hdc is the location of the drive to which the image was just restored.

tpip V1.2:

tpip -1 -s /dev/hdc

where /dev/hdc is the location of the drive to which the image was just restored.

TiVo Drive is Locked

On some very early Series 1 TiVo models, the Quantum branded hard drive was locked. You must run the qunlock program to unlock it. The qunlock utility is included must be copied to a bootable DOS floppy disk drive. A bootable DOS floppy is created by placing a floppy in your PC, right-clicking it, selecting "format", and specifying the "make bootable / copy system files" option. The downlowd and copy the qunlock.exe program to the floppy. Next, turn-off the PC, disconnect your Windows drive, install the TiVo drive, turn on the PC (it will automatically boot the floppy drive), and type "qunlock.exe" at the command prompt. You will see some output telling you how to run qunlock based on how the TiVo drive is connected to your PC (for example, you will type something like 'qunlock 2' if the drive is connected to IDE secondary master.) Turn-off your PC. The drive should now be unlocked.

Make the Hard Drive Quieter

Some hard drive allow changing the AAM (Automatic Acoustic Management) setting. This setting will decrease or completely eliminate the "ticking" sound that is audible when the drive is performing random seeks (i.e. is under heavy load and preforming multiple tasks). This will not change the constant hum/whine sound that some hard drives make.

See this page to download a ISO file for creating a boot CD for the IBM/Hitachi Feature Tool. To use the tool, burn it to CD in ISO mode, boot to the CD in a PC with the TiVo Drive attached, select the TiVo hard drive from the list, and then go to the Features menu and select Acoustic Level (Alt+A). Set the acoustic level to the quietest setting (128). This will decrease drive performance slightly but not enough to be noticeable when installed in a TiVo.

Personal tools