You can back up the hard drive into an external drive by two ways:
1. Use Time Machine to back up the external disk > http://support.apple.com/kb/HT1427
2. Clone the disk using Carbon Copy Cloner or SuperDuper.
If you can, make both backups on one or two external disks to get the advantages of Time Machine and the clone. Also, if you only want to back up some files, you can copy them to an external disk and restore them after reinstalling Mac OS X