Are you asking how to backup your hard drive before it's replaced? If so:
Clone Lion using Restore Option of Disk Utility
Boot to the Recovery HD:
Restart the computer and after the chime press and hold down the COMMAND and R keys until the menu screen appears. Alternatively, restart the computer and after the chime press and hold down the OPTION key until the boot manager screen appears. Select the Recovery HD and click on the downward pointing arrow button.
1. Select Disk Utility from the main menu then press the Continue
2. Select the destination volume from the left side list.
3. Click on the Restore tab in the DU main window.
4. Check the box labeled Erase destination.
5. Select the destination volume from the left side list and drag it
to the Destination entry field.
6. Select the source volume from the left side list and drag it to
the Source entry field.
7. Double-check you got it right, then click on the Restore button.
Destination means the external backup drive. Source means the internal startup drive.