The dd command works fine if you don't encounter any bad blocks. If you do have any bad blocks, dd will stop and hang when it encounters them. Since you say your hard drive may be failing, dd might not work. For those situations you are better off using the ddrescue command:
ddrescue - Gentoo Wiki
You can find most, if not all of the utilities mentioned in this thread(dd, ddrescue, partimage, clonezilla) on a linux livecd/liveusb called Parted Magic:
programs ? Parted Magic
Both partimage and clonezilla use the dd command under the hood to do their work IIRC, so once again, you might get aborts or system hangs if they encounter bad blocks. Clonezilla is the most widely used application for cloning an entire hard drive. I'd try that first and if you run into problems, go to ddrescue.