GNU dd_rescue is a program that can be used to recover data from a disk with errors. For example a hard disk with some bad sectors. It is a modified version of dd with 2 features that make it great for rescuing data from a failing hard drive. The first is you can tell dd_rescue to start from the end of a file (disk) and move backwards. Second, it uses two block sizes, a large (soft) block size and a small (hard) block size. In case of errors, the size falls back to the small one and is promoted again after a while without errors.
A simple example of what a rescue might look like with dd_rescue is below. Be sure to read the read me file and man page for more info.
Installing on Ubunutu is as easy as "sudo apt-get install gddrescue".
dd_rescue /dev/hda1 /home/pantz/brokedrive_hda1.img
2. Wait a long ass time.
3. Setup image as a device.
losetup /dev/loop1 /home/pantz/brokedrive_hda1.img
4. Mount it (you have to know your filesystem).
mount -t ext3 /dev/loop1 /media/cdrom
5. Change to the dir where the rescue image is mounted.
6. Look all all your files hopefully.
Other free disk recovery software that you might check out is PhotoRec or TestDisk.