As long as you are restoring to the same PS3 (new HDD is okay), the built-in Backup Utility will make a full backup of your entire PS3 game system (including copy-protected game data and media). The only exception to this is if you have Linux installed. Linux is a separate OS and it needs to be backed up and restored from within Linux. The backup utility is located in the XMB menu under Settings > System Settings > Backup Utility.
I can also confirm that virtual memory cards from both PS1 and PS2 backed up flawlessly.
You can find out how much space you're currently using by going to Settings -> System Settings -> System Information
The backup software will not backup the local Trophy data and copyright protected Videos (not sure about PS1/2 virtual memory cards). It will backup everything else; DRM free Videos, Music, Pics, PSN Games, Game Install's, Game Data, Partial Downloads, Copy Protect PS3 Saves, etc...
To perform a backup you just need a FAT32 partitioned drive/mem card with enough space to hold everything.