If you’re like most people, you probably have at least one old CD lying around. Maybe it’s from when you were a kid and your parents would give you a few CDs to play at home. Maybe you’ve had it since the early 2000s and it’s just gathering dust on your shelf. In any case, if you have an old CD that’s been damaged or just doesn’t work anymore, there are a few ways to try to fix it without having to go through the hassle of buying a new one. Here are three tips:
- Use an Ubuntu Live CD as a rescue disk: If your CD is older than six months, chances are good that Ubuntu can help you fix it up. Just insert the Ubuntu Live CD into your computer and start typing in commands to fix things like permissions and startup files. You can also search for specific problems on the Ubuntu website or in the Ubuntu community forums if you don’t know where to start.
- Use an online service: If all else fails, there are online services that can help you fix CDs for free. For example, Cdfix offers a simple but effective solution that works with most computers. You simply type in the name of the CD or DVD problem and they’ll find and repair any issues with it for you. They also offer support through their website and forum communities so there’s always someone available to help out if something goes wrong.
- Use an external drive: If all else fails, consider using an external drive as a rescue disk instead of your computer’s internal storage space. This way, if something goes wrong with your computer while trying to use the rescue disk (like your hard drive crashes), you can still access all of your data even though some of it may be on the rescue disk!
The tool we’re going to use to do this is called ddrescue, which can be easily accessed from the Live CD environment. ddrescue can make .iso files out of your CDs, which can then either be burned to a more reliable CD, or can be mounted and accessed in all modern operating systems.
Boot into the Ubuntu Live CD environment using a burnt CD or a prepared flash drive.
First, we’ll install ddrescue. Open up the Synaptic Package Manager (System > Administration > Synaptic Package Manager).
In the Synaptic Package Manager window, click on Settings > Repositories.
Add a check in the box whose label ends with “universe” to enable Ubuntu’s universe repository. Click Close.
Back in the main Synaptic window, click the Reload button to reload the list of available packages.
Once the search index has been rebuilt, enter “ddrescue” in the Quick search text field. Two different packages will come up; make sure that you choose “gddrescue” and not “ddrescue,” which operates slightly differently.
Right click on “gddrescue” and select Mark for Installation. Click the Apply button, and follow the prompts to install ddrescue.
Next, we need to select a location to save the .iso file that will be produced by ddrescue. In our case, we’ll use an internal NTFS hard drive. To mount it, we’ll click on Places and then select the hard drive we want to use.
The rest of this guide will be done in a terminal window, so open one through Applications > Accessories > Terminal.
Navigate to the location in which you will save the .iso file. In our case, it’s a newly mounted hard drive, so we’ll first change to the /media directory, and then use tab completion to change to the directory that represents our hard drive.
Once you’re in the right directory, you’re ready to run ddrescue! ddrescue is neat because you can try to pull data off of a CD multiple times, and each time it will add to the same image file whatever new data is manages to recover.
Because of that, for the first pass, it’s best to start with recovering the easy parts first, and then drilling down into problem areas later.
For the first pass, the terminal command is:
In our case, the CD we’re trying to recover is a 13 year old CD with Red Hat Linux 4.2 on it, so we’re going to call the image RedHat.iso, and the log file RedHat.log.
The “-n” flag ensures that this first pass won’t take too long, but will still recover the easy-to-read parts of the CD. The “-b” flag is important because CDs have block sizes of 2048 bytes.
Eventually ddrescue will finish, possibly with some errors.
In our case, there were around 80 MB of data that were not recovered due to errors. Let’s try a second, more in-depth run to try to recover as much data as possible.
The terminal command for this second run is very similar to the first, except that instead of using the “-n” flag we will use the “-d” flag to tell ddrescue to go into direct mode and read as much data from the CD as possible. For more information about command line parameters ddrescue recognizes, see its manual.
Make sure that the .iso and .log files are the same as you used in the first step.
We let ddrescue run overnight, and in the morning…
we had recovered over 55 MB of the data we hadn’t recovered before! If we left it longer, we may have been able to recover even more.
It’s a good idea to try to save your CDs now, before they degrade any further. Hard drive space is cheap; buying an external drive is small investment if it means you can save your old CDs (and then you can throw them away to save some space on your shelves).
And while ddrescue is a great tool for doing this, it can also be used to pull data from other devices like hard drives and floppy disks. If you tried to make a drive image with dd and it gave you errors, then give ddrescue a try instead!